polkadot-evm / frontier Goto Github PK
View Code? Open in Web Editor NEWEthereum compatibility layer for Substrate.
License: Apache License 2.0
Ethereum compatibility layer for Substrate.
License: Apache License 2.0
Currently the block returned has a gasLimit of 0.
@sorpaas Should we also include the calc_gas_limit
to compute the block gas limit?
(Ex of implementation: https://github.com/ethereum/go-ethereum/blob/1591b63306cababdb37d244432653bbd71c346df/core/block_validator.go#L108)
Test failing:
test-gas.ts
=> block gas limit over 5M
Was running a local @moonbeam node, tried to deploy a std ERC-20 (which worked before), got this ...
$ ./target/release/node-moonbeam --dev -lerror
====================
Version: 0.1.0-e53269f-x86_64-linux-gnu
0: sp_panic_handler::set::{{closure}}
1: std::panicking::rust_panic_with_hook
at /rustc/663d2f5cd3163f17eddb74ee1e028d542255f21a/library/std/src/panicking.rs:573
2: std::panicking::begin_panic_handler::{{closure}}
at /rustc/663d2f5cd3163f17eddb74ee1e028d542255f21a/library/std/src/panicking.rs:476
3: std::sys_common::backtrace::__rust_end_short_backtrace
at /rustc/663d2f5cd3163f17eddb74ee1e028d542255f21a/library/std/src/sys_common/backtrace.rs:153
4: rust_begin_unwind
at /rustc/663d2f5cd3163f17eddb74ee1e028d542255f21a/library/std/src/panicking.rs:475
5: core::panicking::panic_fmt
at /rustc/663d2f5cd3163f17eddb74ee1e028d542255f21a/library/core/src/panicking.rs:85
6: core::option::expect_none_failed
at /rustc/663d2f5cd3163f17eddb74ee1e028d542255f21a/library/core/src/option.rs:1221
7: <pallet_ethereum::Call<T> as frame_support::traits::UnfilteredDispatchable>::dispatch_bypass_filter
8: <moonbeam_runtime::Call as frame_support::traits::UnfilteredDispatchable>::dispatch_bypass_filter
9: <moonbeam_runtime::Call as sp_runtime::traits::Dispatchable>::dispatch
10: <sp_runtime::generic::checked_extrinsic::CheckedExtrinsic<AccountId,Call,Extra> as sp_runtime::traits::Applyable>::apply
11: frame_executive::Executive<System,Block,Context,UnsignedValidator,AllModules,COnRuntimeUpgrade>::apply_extrinsic_with_len
12: <moonbeam_runtime::Runtime as sp_block_builder::runtime_decl_for_BlockBuilder::BlockBuilder<sp_runtime::generic::block::Block<sp_runtime::generic::header::Header<u32,sp_runtime::traits::BlakeTwo256>,sp_runtime::generic::unchecked_extrinsic::UncheckedExtrinsic<<<sp_runtime::MultiSignature as sp_runtime::traits::Verify>::Signer as sp_runtime::traits::IdentifyAccount>::AccountId,moonbeam_runtime::Call,sp_runtime::MultiSignature,(frame_system::CheckSpecVersion<moonbeam_runtime::Runtime>,frame_system::CheckTxVersion<moonbeam_runtime::Runtime>,frame_system::CheckGenesis<moonbeam_runtime::Runtime>,frame_system::CheckEra<moonbeam_runtime::Runtime>,frame_system::CheckNonce<moonbeam_runtime::Runtime>,frame_system::CheckWeight<moonbeam_runtime::Runtime>,pallet_transaction_payment::ChargeTransactionPayment<moonbeam_runtime::Runtime>)>>>>::apply_extrinsic
13: sp_block_builder::runtime_decl_for_BlockBuilder::apply_extrinsic_native_call_generator::{{closure}}
14: std::thread::local::LocalKey<T>::with
15: sc_executor::native_executor::WasmExecutor::with_instance::{{closure}}
16: sc_executor::wasm_runtime::RuntimeCache::with_instance
17: <sc_executor::native_executor::NativeExecutor<D> as sp_core::traits::CodeExecutor>::call
18: sp_state_machine::StateMachine<B,H,N,Exec>::execute_aux
19: sp_state_machine::StateMachine<B,H,N,Exec>::execute_using_consensus_failure_handler
20: <sc_service::client::call_executor::LocalCallExecutor<B,E> as sc_client_api::call_executor::CallExecutor<Block>>::contextual_call
21: <sc_service::client::client::Client<B,E,Block,RA> as sp_api::CallApiAt<Block>>::call_api_at
22: sp_block_builder::runtime_decl_for_BlockBuilder::apply_extrinsic_call_api_at
23: <moonbeam_runtime::RuntimeApiImpl<__SR_API_BLOCK__,RuntimeApiImplCall> as sp_block_builder::BlockBuilder<__SR_API_BLOCK__>>::BlockBuilder_apply_extrinsic_runtime_api_impl
24: <moonbeam_runtime::RuntimeApiImpl<Block,C> as sp_api::ApiExt<Block>>::map_api_result
25: sc_basic_authorship::basic_authorship::Proposer<B,Block,C,A>::propose_with
26: core::ops::function::FnOnce::call_once{{vtable.shim}}
27: std::sys_common::backtrace::__rust_begin_short_backtrace
28: core::ops::function::FnOnce::call_once{{vtable.shim}}
29: <alloc::boxed::Box<F> as core::ops::function::FnOnce<A>>::call_once
at /rustc/663d2f5cd3163f17eddb74ee1e028d542255f21a/library/alloc/src/boxed.rs:1042
<alloc::boxed::Box<F> as core::ops::function::FnOnce<A>>::call_once
at /rustc/663d2f5cd3163f17eddb74ee1e028d542255f21a/library/alloc/src/boxed.rs:1042
std::sys::unix::thread::Thread::new::thread_start
at /rustc/663d2f5cd3163f17eddb74ee1e028d542255f21a/library/std/src/sys/unix/thread.rs:87
30: start_thread
31: __clone
Thread 'tokio-blocking-driver' panicked at 'called `Result::unwrap()` on an `Err` value: InvalidNonce', /home/sum/DEV/moonbeam/vendor/frontier/frame/ethereum/src/lib.rs:379
Topic type holds a single or multiple H256 value:
pub type Topic = VariadicValue<H256>;
but we should support topic wildcards for filtering i.e. [null, 0x000..., null, null]
:
pub type Topic = VariadicValue<Option<H256>>;
EthApi::protocol_version
EthApi::syncing
EthApi::hashrate
EthApi::author
EthApi::is_mining
EthApi::chain_id
EthApi::gas_price
EthApi::accounts
EthApi::block_number
EthApi::balance
EthApi::proof
EthApi::storage_at
EthApi::block_by_hash
EthApi::block_by_number
EthApi::transaction_count
EthApi::block_transaction_count_by_hash
EthApi::block_transaction_count_by_number
EthApi::block_uncles_count_by_hash
EthApi::block_uncles_count_by_number
EthApi::code_at
EthApi::send_raw_transaction
EthApi::submit_transaction
EthApi::call
EthApi::estimate_gas
EthApi::transaction_by_hash
EthApi::transaction_by_block_hash_and_index
EthApi::transaction_by_block_number_and_index
EthApi::transaction_receipt
EthApi::uncle_by_block_hash_and_index
EthApi::uncle_by_block_number_and_index
EthApi::compilers
EthApi::compile_lll
EthApi::compile_solidity
EthApi::compile_serpent
EthApi::logs
EthApi::work
EthApi::submit_work
EthApi::submit_hashrate
When attempting to deploy contracts via truffle, using the "PrivateKeyProvider" from the moonbeam repo, the truffle deploy script hangs at the final "Saving migration to chain" step (you can test with this repo but I have experienced the same behavior using other truffle migrations).
My chain prints the following EVM debug logs at time of hang:
2020-09-04 14:09:30.014 tokio-blocking-driver DEBUG evm Execution Succeed(Returned) [source: 0x6be02d1d3665660d22ff9624b7be0551ee1ac91b, value: 0, gas_limit: 50000000, used_gas: 4118262, actual_fee: 82365240000000000]
2020-09-04 14:09:30.014 tokio-blocking-driver DEBUG evm Inserting code (18864 bytes) at 0xe573bca813c741229ffb2488f7856c6caa841041
2020-09-04 14:09:30.014 tokio-blocking-driver DEBUG evm Removing storage for 0xe573bca813c741229ffb2488f7856c6caa841041 [index: 0x0000000000000000000000000000000000000000000000000000000000000001]
The final line is interesting, because prior deployments don't have a "Removing storage" -- the execution succeeds, the code is inserted, and that's it.
Wondering if you have any idea why this might be happening. Thanks!
It skips the min_gas_price
judgment.
Is it a bug or a feature?
Should have SignedExtension to validate ethereum transactions to check for signature, nonce, gas, etc.
I am using Polkadot UI to create the example erc20 contract with Alice account. And my call of Extrinsic is like below:
I double checked the balance of Alice and it's still around 900 units. Are there something wrong that I did in this example to encounter this error?
Also, for the source: H160 field, I tried both the account id (like above) and the EVM account ID 0x57d213d0927ccc7596044c6ba013dd05522aacba, I am not sure which one is correct. The latter one I tried is always returning an error of BadOrigin, therefore I guess it's kind of wrong encoding for here. Any ideas?
Web3 Providers are usually using the Web3 Engine which by default sends skipCache: true
as parameter of the jsonrpc.
Ex:
{"jsonrpc":"2.0","id":1,"method":"eth_blockNumber","params":[],"skipCache":true}
This is not supported by substrate and returns {"jsonrpc":"2.0","error":{"code":-32600,"message":"Invalid request"},"id":1}
The web3 api has event functionality, is this currently planned in the scope of moonbeam's grant?
require()
calls in solidity allow the contract author to provide a reason for the code reversion. This is a useful feature for debugging contracts. However, currently frontier does not capture these.
What would it take to fetch the revert reason and print it out as a debug log?
I keep getting OutOfGas errors when I try to send transactions.
First, I tried passing in 2,000,000 gas, and I got the following error message.
2020-08-27 13:06:30.027 tokio-blocking-driver DEBUG evm Execution Error(OutOfGas) [source: 0x6be02d1d3665660d22ff9624b7be0551ee1ac91b, value: 0, gas_limit: 2000000, used_gas: 2000000, actual_fee: 4000000000000000]
Then, I made the same call again using the amount of gas specified in "actual_fee", and this was the error I got:
2020-08-27 13:07:00.005 tokio-blocking-driver DEBUG evm Execution Error(OutOfGas) [source: 0x6be02d1d3665660d22ff9624b7be0551ee1ac91b, value: 0, gas_limit: 2467954688, used_gas: 2467954688, actual_fee: 4935909376000000000]
And when I try to pass in hex strings to pass in very large values instead of JS numbers, I get the following error:
2020-08-27 13:12:30.785 tokio-blocking-driver DEBUG evm Execution Error(OutOfGas) [source: 0x6be02d1d3665660d22ff9624b7be0551ee1ac91b, value: 0, gas_limit: 0, used_gas: 0, actual_fee: 0]
Any idea what's going on?
unused import: UniqueSaturatedInto
--> template/runtime/src/lib.rs:36:2
rel #25 (comment)
We need to decide the final implementation for this one - and its block_transaction_count_by_hash counterpart. Options are:
This is currently not implemented and used by many DApps.
hi,I want konw howthe interaction between runtime modules (pallets) and smart contracts (env), please~
When pallet ethereum executes Ethereum transactions submitted to its transact
extrinsic, the correct flow is as follows.
Execute the transaction against the EVM,
Insert the transaction hash along with its receipt and status in the Pending
item
On block finalization, include the transaction hash in the EndBlock digest
On block import write the transaction metadata to aux storage.
But when transactions revert, they are never inserted into the Pending
storage item, and the rest of the flow is skipped. From an end user perspective, this means I cannot query for transaction receipts for reverted transactions.
The problem is that the transact
function returns early when a revert happens thanks to the ?
on this line https://github.com/paritytech/frontier/blob/bb79f231ea5d3785d9f543aa9d9a4454cf5b59b1/frame/ethereum/src/lib.rs#L169-L177
As a concrete test case, I've been using this simple contract deploy which will always fail
pragma solidity >=0.4.22 <0.7.0;
contract WillFail {
constructor() public {
require(2 == 1);
}
}
@tgmichel Can you add documentation for EthereumRuntimeApi ?
In the code itself to describe quickly each function.
In the README to explain how to implement them
The Ethereum address can be obtained from the substrate address, but if I already know the private key of the substrate address, can I get the corresponding Ethereum private key?
Transactions returned inside a block should not be a full object but strings.
Ex:
{
"difficulty": "0",
"extraData": "0x",
"gasLimit": 6721975,
"gasUsed": 890864,
"hash": "0x59ad824245161d0df7ab563049f26aa879322e7858b3621249e2ea6b13c0d000",
"logsBloom": "0x00000000000000000000000000000000000000000000000000000000008000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000008000000000000800000000000000000000000000000000000020000000000000000000800000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800000000000000002000000000000000000000000000000000000000000000000000020000400000000000000000000000004000000000000000000000000000000000000",
"miner": "0x0000000000000000000000000000000000000000",
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"nonce": "0x0000000000000000",
"number": 1,
"parentHash": "0x1c90c2be1ab2b4df89aa9fc90e9d9f22767abfdbbdfbd9cdfcf264111b46325e",
"receiptsRoot": "0xa97263c775ab4abef12fb4f31365f1e093a0dc445ed47171ba41aeffc8bd9df4",
"sha3Uncles": "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
"size": 1000,
"stateRoot": "0x43578107c024572060ccc72f0164cc858dd933e0f125fc4c57e7f99670ace020",
"timestamp": 1594075956,
"totalDifficulty": "0",
"transactions": [
"0x935fa82a49a587ab4a8bb9415abf27fa29d8f67349d770072dadaa5dfe07cfb1"
],
"transactionsRoot": "0x4dbc6a032b4cb84d82a4bdf4a5b04d4419f0ae9ffc857ff3ca388e105f60c980"
}
Calling the eth_estimateGas
for a contract creation with
gas_limit: 4294967295
gas_price: 0
When f(&mut executor)
is executed, it returns Succeed(Stopped)
(I think it should be Succeed(Returned)
) and used_gas
is 85732
However when executing the sendRawTransaction with gas_limit: 85732
it fails with not enough gas.
Executing the same transaction with gas_limit: 4294967295
shows that it uses 890864
(It works fine for gas estimation of ABI functions)
Currently a mixed of GPL-3 and Apache 2.0 are used in Cargo.toml. Is this intentional?
https://github.com/paritytech/frontier/blob/c28889948362bf7b2ece8e9cf65a60415baa47d4/consensus/Cargo.toml#L7
https://github.com/paritytech/frontier/blob/c28889948362bf7b2ece8e9cf65a60415baa47d4/rpc/Cargo.toml#L7
https://github.com/paritytech/frontier/blob/c28889948362bf7b2ece8e9cf65a60415baa47d4/consensus/primitives/Cargo.toml#L7
Both pub trait ConvertTransaction
and pub struct TransactionStatus
could use some doc comments.
When I use the web3 rpc to transfer main assets from the source address to the destination address, I find that the balance of the target address will decrease, and the balance of the source address will increase.
Use metamask to generate two addresses, then calculate the hashed account id, and then transfer assets to these two accounts. Then use metamask to transfer assets from address 1 to address 2, you can see the wrong result.
Implement the Ethereum precompiles.
The pallet_ethereum::execute doesn't support returning an error when the EVM returns an ExitReason different from Success.
This causes the ethereum chain to include the transaction and third party tools to increase the nonce which breaks next transactions.
Description
I have run a node using Frontier from this repository: here
I can deploy and interact with smart contracts using Metamask and remix without any problem. But for some specif contract architectures, I am encountering unexpected behaviors. I have managed to isolate the bug in the contract bellow:
Test contract
pragma solidity ^0.7;
contract Child {
bytes32 public name;
address public consumer;
constructor(bytes32 _name, address _consumer){
name = _name;
consumer = _consumer;
}
}
contract Factory {
uint256 public childCount;
function create(bytes32 name, address consumer) public returns (address newChildAddress){
Child newChild = new Child(name, consumer);
newChildAddress = address(newChild);
childCount++;
}
}
contract Consumer {
address public factoryAddress;
constructor(address factory){
factoryAddress = factory;
}
function createNewChild(bytes32 name) public returns (address newChildAddress){
newChildAddress = Factory(factoryAddress).create(name, address(this));
}
}
Steps to Reproduce
./target/release/frontier-template-node --dev --tmp --rpc-port=9933
0x7465737400000000000000000000000000000000000000000000000000000000
Expected vs. Actual Behavior
This transaction completes without any problem on the Ethereum network, returning the address of the created child contract.
This transaction is expected to complete normally. Instead, it is dropped after a few minutes.
Logs, Errors or Screenshots
Factory contract created:
status | Status not available at the moment |
---|---|
transaction hash | 0x62d542faccf4f089a1a9eab29cb265130c0757405fb3aedc0b408dbc7f0a6e86 |
from | 0x37508A08F04ab9d3BC660E40789b131e7dd6Cd0C |
to | Factory.(constructor) |
gas | 224438 gas |
transaction cost | 224438 gas |
hash | 0x62d542faccf4f089a1a9eab29cb265130c0757405fb3aedc0b408dbc7f0a6e86 |
input | 0x608...00033 |
decoded input | {} |
decoded output | - |
logs | [] |
value | 0 wei |
Consumer contract created:
status | Status not available at the moment |
---|---|
transaction hash | 0x1dc905062b6ba6cb0d43cfa64c9d2d10ca0e81554a6e1a715bfa4274f7507366 |
from | 0x37508A08F04ab9d3BC660E40789b131e7dd6Cd0C |
to | Consumer.(constructor) |
gas | 185107 gas |
transaction cost | 185107 gas |
hash | 0x1dc905062b6ba6cb0d43cfa64c9d2d10ca0e81554a6e1a715bfa4274f7507366 |
input | 0x608...89efe |
decoded input | { "address factory": "0x25F96Ac4D65a5e111E5A19Ddd521C18bd5e89EFe" } |
decoded output | - |
logs | [] |
value | 0 wei |
Dropped tx:
{ "id": 8887169361036572, "time": 1604273225247, "status": "dropped", "metamaskNetworkId": "42", "loadingDefaults": false, "txParams": { "from": "0x37508a08f04ab9d3bc660e40789b131e7dd6cd0c", "to": "0x9b8aa70e3d51c0f236dbfb61ae8bc1c50e0cecd4", "nonce": "0xa", "value": "0x0", "data": "0x07ce2b0e7465737400000000000000000000000000000000000000000000000000000000", "gas": "0x28399", "gasPrice": "0x0" }, "type": "standard", "origin": "http://remix.ethereum.org", "transactionCategory": "contractInteraction", "history": [ { "id": 8887169361036572, "time": 1604273225247, "status": "unapproved", "metamaskNetworkId": "42", "loadingDefaults": true, "txParams": { "from": "0x37508a08f04ab9d3bc660e40789b131e7dd6cd0c", "to": "0x9b8aa70e3d51c0f236dbfb61ae8bc1c50e0cecd4", "value": "0x0", "data": "0x07ce2b0e7465737400000000000000000000000000000000000000000000000000000000", "gas": "0x28399", "gasPrice": "0x0" }, "type": "standard", "origin": "http://remix.ethereum.org", "transactionCategory": "contractInteraction" }, [ { "op": "replace", "path": "/loadingDefaults", "value": false, "note": "Added new unapproved transaction.", "timestamp": 1604273225257 } ], [ { "op": "replace", "path": "/status", "value": "approved", "note": "txStateManager: setting status to approved", "timestamp": 1604273226983 } ], [ { "op": "add", "path": "/txParams/nonce", "value": "0xa", "note": "transactions#approveTransaction", "timestamp": 1604273226985 }, { "op": "add", "path": "/nonceDetails", "value": { "params": { "highestLocallyConfirmed": 10, "highestSuggested": 10, "nextNetworkNonce": 10 }, "local": { "name": "local", "nonce": 10, "details": { "startPoint": 10, "highest": 10 } }, "network": { "name": "network", "nonce": 10, "details": { "blockNumber": "0xb5", "baseCount": 10 } } } } ], [ { "op": "add", "path": "/r", "value": "0x3456fef0dd9465d95bf1e8b7f6dc77f8d52972dafbbcc5f4a74f18beda308a3e", "note": "transactions#signTransaction: add r, s, v values", "timestamp": 1604273227027 }, { "op": "add", "path": "/s", "value": "0x4ca70aab0b8e8cf25a230bfc48aed974defe5f0bb946940d34fec2f548452a30" }, { "op": "add", "path": "/v", "value": "0x78" } ], [ { "op": "replace", "path": "/status", "value": "signed", "note": "txStateManager: setting status to signed", "timestamp": 1604273227028 } ], [ { "op": "add", "path": "/rawTx", "value": "0xf8840a8083028399949b8aa70e3d51c0f236dbfb61ae8bc1c50e0cecd480a407ce2b0e746573740000000000000000000000000000000000000000000000000000000078a03456fef0dd9465d95bf1e8b7f6dc77f8d52972dafbbcc5f4a74f18beda308a3ea04ca70aab0b8e8cf25a230bfc48aed974defe5f0bb946940d34fec2f548452a30", "note": "transactions#publishTransaction", "timestamp": 1604273227029 } ], [ { "op": "add", "path": "/hash", "value": "0x8ee748a177753dac49464ba9c579c15dc87a83ddde91d3401d23b1f76a0d81ef", "note": "transactions#setTxHash", "timestamp": 1604273227036 } ], [ { "op": "add", "path": "/submittedTime", "value": 1604273227036, "note": "txStateManager - add submitted time stamp", "timestamp": 1604273227037 } ], [ { "op": "replace", "path": "/status", "value": "submitted", "note": "txStateManager: setting status to submitted", "timestamp": 1604273227038 } ], [ { "op": "add", "path": "/firstRetryBlockNumber", "value": "0xb8", "note": "transactions/pending-tx-tracker#event: tx:block-update", "timestamp": 1604273240317 } ], [ { "op": "add", "path": "/warning", "value": { "error": "[ethjs-query] while formatting outputs from rpc '{\"value\":{\"code\":-32603,\"message\":\"internal json-rpc error.\",\"data\":{\"code\":-32603,\"message\":\"submit transaction to pool failed: pool(invalidtransaction(invalidtransaction::stale))\"},\"stack\":\"o@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:358924\\ns@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:361390\\ninternal@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:361794\\nl@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:35483\\n[715]</</t.exports/<@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:34640\\n\"}}'", "message": "There was an error when resubmitting this transaction." }, "note": "transactions/pending-tx-tracker#event: tx:warning", "timestamp": 1604273260319 } ], [ { "op": "replace", "path": "/warning/error", "value": "[ethjs-query] while formatting outputs from rpc '{\"value\":{\"code\":-32603,\"message\":\"internal json-rpc error.\",\"data\":{\"code\":-32603,\"message\":\"submit transaction to pool failed: pool(temporarilybanned)\"},\"stack\":\"o@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:358924\\ns@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:361390\\ninternal@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:361794\\nl@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:35483\\n[715]</</t.exports/<@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:34640\\n\"}}'", "note": "transactions/pending-tx-tracker#event: tx:warning", "timestamp": 1604273280329 } ], [ { "op": "replace", "path": "/status", "value": "dropped", "note": "txStateManager: setting status to dropped", "timestamp": 1604273300347 } ] ], "nonceDetails": { "params": { "highestLocallyConfirmed": 10, "highestSuggested": 10, "nextNetworkNonce": 10 }, "local": { "name": "local", "nonce": 10, "details": { "startPoint": 10, "highest": 10 } }, "network": { "name": "network", "nonce": 10, "details": { "blockNumber": "0xb5", "baseCount": 10 } } }, "r": "0x3456fef0dd9465d95bf1e8b7f6dc77f8d52972dafbbcc5f4a74f18beda308a3e", "s": "0x4ca70aab0b8e8cf25a230bfc48aed974defe5f0bb946940d34fec2f548452a30", "v": "0x78", "rawTx": "0xf8840a8083028399949b8aa70e3d51c0f236dbfb61ae8bc1c50e0cecd480a407ce2b0e746573740000000000000000000000000000000000000000000000000000000078a03456fef0dd9465d95bf1e8b7f6dc77f8d52972dafbbcc5f4a74f18beda308a3ea04ca70aab0b8e8cf25a230bfc48aed974defe5f0bb946940d34fec2f548452a30", "hash": "0x8ee748a177753dac49464ba9c579c15dc87a83ddde91d3401d23b1f76a0d81ef", "submittedTime": 1604273227036, "firstRetryBlockNumber": "0xb8", "warning": { "error": "[ethjs-query] while formatting outputs from rpc '{\"value\":{\"code\":-32603,\"message\":\"internal json-rpc error.\",\"data\":{\"code\":-32603,\"message\":\"submit transaction to pool failed: pool(temporarilybanned)\"},\"stack\":\"o@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:358924\\ns@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:361390\\ninternal@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:361794\\nl@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:35483\\n[715]</</t.exports/<@moz-extension://592af72d-e129-4795-9cd1-c699ae45a806/background.js:60:34640\\n\"}}'", "message": "There was an error when resubmitting this transaction." } }
Transaction reproduced in the Ropsten network:
Factory address: 0x46431F551d51C430728285891A2e893215065F70
Consumer address: 0x0538C4e5e562538e0C383E90A069BAaeF25ddC85
Successful transaction: https://ropsten.etherscan.io/tx/0xa8d3f2d387dbfc18675b2aba402ad596eb37671b75b217206a2f999401b3c25c
i.e. vendor/submodules section doesn't seem to be needed anymore
rel #15 (review)
Store all extra data to support ethereum RPC is costly.
We should allow CLI to enable ethereum index mode, which will store all the extra data in to aux store.
Similar to archive mode, the code should detect if we were previously not running in ethereum index mode, and report error when the CLI flag is been passed or vice versa.
The CLI flag part does not need to happen here, but frontier should support to detect and report index mode.
Hi, folks.
I am trying to put pallet-ethereum
and pallet-evm
into my node-template runtime. The compiler complained when I build runtime.
# Cargo.toml in runtime
ethereum = { version = "0.1.0", default-features = false, package = "pallet-ethereum", git = "https://github.com/paritytech/frontier.git"}
pallet-evm = { version = "2.0.0-dev", default-features = false, package = "pallet-evm", git = "https://github.com/paritytech/substrate.git", branch = "frontier" }
frontier-rpc-primitives = { default-features = false, git = "https://github.com/paritytech/frontier.git" }
[features]
default = ["std"]
std = [
"ethereum/std",
"pallet-evm/std",
"frontier-rpc-primitives/std",
]
The cargo check
output:
error[E0308]: try expression alternatives have incompatible types
--> /home/wpf/.cargo/git/checkouts/frontier-b4643f17507d3282/8f7f0f9/frame/ethereum/src/lib.rs:341:6
|
341 | pallet_evm::Module::<T>::execute_call(
| _____________________^
342 | | source,
343 | | target,
344 | | transaction.input.clone(),
... |
349 | | true,
350 | | )?
| |______________________^ expected a tuple with 3 elements, found one with 4 elements
|
= note: expected tuple `(ExitReason, _, ethereum_types::U256)`
found tuple `(ExitReason, std::vec::Vec<u8>, ethereum_types::U256, std::vec::Vec<pallet_evm::Log>)`
error[E0308]: try expression alternatives have incompatible types
--> /home/wpf/.cargo/git/checkouts/frontier-b4643f17507d3282/8f7f0f9/frame/ethereum/src/lib.rs:365:6
|
365 | pallet_evm::Module::<T>::execute_create(
| _____________________^
366 | | source,
367 | | transaction.input.clone(),
368 | | transaction.value,
... |
372 | | true,
373 | | )?
| |______________________^ expected a tuple with 3 elements, found one with 4 elements
|
= note: expected tuple `(ExitReason, _, ethereum_types::U256)`
found tuple `(ExitReason, H160, ethereum_types::U256, std::vec::Vec<pallet_evm::Log>)`
error: aborting due to 2 previous errors
For more information about this error, try `rustc --explain E0308`.
error: could not compile `pallet-ethereum`
I have no idea how to fix it and build it successfully.
It should return Result<(Vec<u8>, U256), DispatchError>
so we don't discard valuable information.
The current submodule setup requires us to use the Substrate from frontier repo and there is not way to override it. Not even with [patch.crates-io]
.
This makes this almost unusable to be integrated by other projects.
In a parachain, the runtime is embedded in a "Cumulus" runtime. What happens is the Block
in the embedded runtime is yet to be aware of the best_chain's BlockId
passed from the frontier::rpc
. Used this way throws arbitrary errors when calling client.runtime_api()
:
let header = self.select_chain.best_chain();
client.runtime_api().account_basic(&BlockId::Number(header.number()), address);
Results in:
UnknownBlock(
"Require header: BlockId::Number(XX)",
)
If I artificially add a sleep delay (i.e. 2 seconds) after the best_chain
call in frontier::rpc
and before the actual client.runtime_api
call, then it works fine:
let header = self.select_chain.best_chain();
thread::sleep(X);
client.runtime_api().account_basic(&BlockId::Number(header.number()), address);
We're deploying the Edgeware lockdrop contracts on Edgeware (haha) and we need to use the contract's nonce to recover lock contract addresses. However, when we call this RPC on the contract after submitting TXs to it, it always returns 0. Is it properly implemented?
Suggested behavior is to limit the gas to probably 10x the block gas limit
We are calculating transaction_root
as the Keccak256 hash of an rlp encoded list of transactions. Should be the Keccak256 hash of the root node of the transactions trie.
When doing a eth_getBlockByNumber
using 0 (and "earliest" too ?), it returns null.
I believe it should return the genesis block
Rustdocs for this project should be published. Here is an example GitHub Action we can look into using https://github.com/casbin/casbin-rs/blob/v2.0.3/.github/workflows/rustdoc.yml. As suggested by @JoshOrndorff.
The Frontier template test client has a dependency on the crate substrate-test-client
.
This crate is not published, and is intended to be used for testing the Substrate node internally. Nodes that build on Substrate should define an appropriate testing crate. (@gnunicorn can you please confirm my understanding?)
Taking this transaction
0xf9036b808504a817c80084ffffffff8080b90317608060405234801561001057600080fd5b50336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506102b7806100606000396000f3fe608060405234801561001057600080fd5b506004361061004c5760003560e01c80630900f01014610051578063445df0ac146100955780638da5cb5b146100b3578063fdacd576146100fd575b600080fd5b6100936004803603602081101561006757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061012b565b005b61009d6101f7565b6040518082815260200191505060405180910390f35b6100bb6101fd565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6101296004803603602081101561011357600080fd5b8101908080359060200190929190505050610222565b005b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614156101f45760008190508073ffffffffffffffffffffffffffffffffffffffff1663fdacd5766001546040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b1580156101da57600080fd5b505af11580156101ee573d6000803e3d6000fd5b50505050505b50565b60015481565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141561027f57806001819055505b5056fea265627a7a7231582094145ca1c18b86561a0dbdd7c29e2c149ef15108c3dc6213a2fa3349deda842e64736f6c634300051000321ca02a8c95973c749a53b01bca76405dc0517cc515cb3219e53bb90e8489a6a9cd2fa0568d5293a7823aeec627ffba0ed9ae0d720df3bceec5200fc88bdb8624f79e35
It should return address: 0x6Be02d1d3665660d22FF9624b7BE0551ee1Ac91b
(associated pub key: 0x624f720eae676a04111631c9ca338c11d0f5a80ee42210c6be72983ceb620fbf645a96f951529fa2d70750432d11b7caba5270c4d677255be90b3871c8c58069
)
(verify there: https://flightwallet.github.io/decode-eth-tx/)
However when used by the pallet ethereum, it returns address: 0xb52abf542f710554a060f63f3308397d4dc61f58
(pubkey: 0x59af98b8c3f25506063333d347a5cc1f5d149571fbafb2bf88acb7e64651bfc67faf875f689da246762546486eaf45558da1b73bd8d0457186994f413f5fc72d
)
I verified the
r: 0x2a8c95973c749a53b01bca76405dc0517cc515cb3219e53bb90e8489a6a9cd2f
s: 0x568d5293a7823aeec627ffba0ed9ae0d720df3bceec5200fc88bdb8624f79e35
,
v: 1
(28)
(there https://github.com/paritytech/frontier/blob/master/frame/ethereum/src/lib.rs#L141)
which are correct too, so I kind see where it is failing to get the right source.
Using this test contract
pragma solidity >=0.4.22;
contract Test {
uint256 number;
constructor() public { number = 1; }
function big_loop(uint256 target) public returns (uint256) {
for (uint i = 0; i < target; i++) {
number += 1;
}
return number;
}
}
estimating the gas for big_loop(10) returns 43412
Sending the transaction big_loop(10) with 43412
gasLimit fails with
apply_extrinsic: Execution Error(OutOfGas) [source: 0x6be02d1d3665660d22ff9624b7be0551ee1ac91b, value: 0, gas_limit: 43412, used_gas: 43412, actual_fee: 43412]
Sending the same transaction big_loop(10) with 434120
gasLimit succeeds
apply_extrinsic: Execution Succeed(Returned) [source: 0x6be02d1d3665660d22ff9624b7be0551ee1ac91b, value: 0, gas_limit: 434120, used_gas: 43412, actual_fee: 43412]
I also tried with 43413
and it failed too.
There are extra fields which don't seem to be part of the specs:
Some other fields have also been seen in other implementation
@sorpaas What do you think?
Hi,
I am trying to run the frontier template example following the tutorial https://github.com/paritytech/frontier/tree/master/template
.
Some problems I encountered:
In docs:
In order to figure out the reason why the accounts balance is zero, I run a fresh chain from the substrate-node-template, the initial account balance is not zero. So, this issue comes up.
Another question, Did you team plan to update this template readme guide recently?
I've been trying to deploy the Uniswap contracts via truffle, from these two repos: core + periphery.
The contracts in core (specifically UniswapV2Factory) deploy OK, followed by OK deployment of the two ERC20 tokens in periphery, but when I attempt to deploy the UniswapV2Router02 contract at the end of the migration, I get the following:
2020-09-04 13:53:00.019 tokio-blocking-driver DEBUG evm Execution Error(CreateContractLimit) [source: 0x6be02d1d3665660d22ff9624b7be0551ee1ac91b, value: 0, gas_limit: 4294967295, used_gas: 4294967295, actual_fee: 85899345900000000000]
This is despite my setting of gas_limit
to "4294967295" in the ethereum frame (higher values make no difference -- I guess it gets sliced down to a u32 deeper in the code?).
Any idea what's going on? Also interesting to note that this error gets reported in truffle as follows:
Deploying 'UniswapV2Router02'
-----------------------------
> transaction hash: 0x0c2a8f87aa955a1166d98cc13a0ad392bcb26375ad4efe25c4a2dd11991e8235
MIGRATION_STATUS:{"status":"postAllMigrations","data":{"dryRun":false,"error":"Error: *** Deployment Failed ***\n\n\"UniswapV2Router02\" -- Web3ProviderEngine does not support synchronous requests..\n"}}
Error: *** Deployment Failed ***
"UniswapV2Router02" -- Web3ProviderEngine does not support synchronous requests..
Creating a contract result in a block that can't be displayed properly in PolkadotJS:
main.0007badc.js:33218 Unable to decode Vec on index 1 createType(ExtrinsicV4):: createType(Call):: Struct: failed on 'args':: Cannot construct unknown type Transaction
(anonymous) @ main.0007badc.js:33218
decodeVec @ main.0007badc.js:33214
Vec @ main.0007badc.js:33204
(anonymous) @ main.0007badc.js:33235
(anonymous) @ main.0007badc.js:32629
decodeStructFromObject @ main.0007badc.js:32611
decodeStruct @ main.0007badc.js:32675
Struct @ main.0007badc.js:32696
Block @ main.0007badc.js:39114
Type @ main.0007badc.js:34937
(anonymous) @ main.0007badc.js:32629
decodeStructFromObject @ main.0007badc.js:32611
decodeStruct @ main.0007badc.js:32675
Struct @ main.0007badc.js:32696
(anonymous) @ main.0007badc.js:32714
Type @ main.0007badc.js:34937
initType @ main.0007badc.js:34353
createTypeUnsafe @ main.0007badc.js:34372
_formatOutput @ main.0007badc.js:28126
(anonymous) @ main.0007badc.js:27985
push.../../node_modules/rxjs/_esm5/internal/operators/map.js.MapSubscriber._next @ main.0007badc.js:237912
push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.next @ main.0007badc.js:232868
push.../../node_modules/rxjs/_esm5/internal/operators/switchMap.js.SwitchMapSubscriber.notifyNext @ main.0007badc.js:240284
push.../../node_modules/rxjs/_esm5/internal/InnerSubscriber.js.InnerSubscriber._next @ main.0007badc.js:232081
push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.next @ main.0007badc.js:232868
push.../../node_modules/rxjs/_esm5/internal/observable/combineLatest.js.CombineLatestSubscriber.notifyNext @ main.0007badc.js:233830
push.../../node_modules/rxjs/_esm5/internal/InnerSubscriber.js.InnerSubscriber._next @ main.0007badc.js:232081
push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.next @ main.0007badc.js:232868
(anonymous) @ main.0007badc.js:243683
Promise.then (async)
(anonymous) @ main.0007badc.js:243681
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable._trySubscribe @ main.0007badc.js:232250
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232236
subscribeToResult @ main.0007badc.js:243721
push.../../node_modules/rxjs/_esm5/internal/observable/combineLatest.js.CombineLatestSubscriber._complete @ main.0007badc.js:233809
push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.complete @ main.0007badc.js:232880
(anonymous) @ main.0007badc.js:243580
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable._trySubscribe @ main.0007badc.js:232250
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232236
push.../../node_modules/rxjs/_esm5/internal/observable/combineLatest.js.CombineLatestOperator.call @ main.0007badc.js:233779
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
subscribeToResult @ main.0007badc.js:243721
push.../../node_modules/rxjs/_esm5/internal/operators/switchMap.js.SwitchMapSubscriber._innerSub @ main.0007badc.js:240260
push.../../node_modules/rxjs/_esm5/internal/operators/switchMap.js.SwitchMapSubscriber._next @ main.0007badc.js:240250
push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.next @ main.0007badc.js:232868
push.../../node_modules/rxjs/_esm5/internal/operators/map.js.MapSubscriber._next @ main.0007badc.js:237918
push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.next @ main.0007badc.js:232868
(anonymous) @ main.0007badc.js:243578
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable._trySubscribe @ main.0007badc.js:232250
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232236
push.../../node_modules/rxjs/_esm5/internal/operators/map.js.MapOperator.call @ main.0007badc.js:237895
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
push.../../node_modules/rxjs/_esm5/internal/operators/switchMap.js.SwitchMapOperator.call @ main.0007badc.js:240228
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
push.../../node_modules/rxjs/_esm5/internal/operators/map.js.MapOperator.call @ main.0007badc.js:237895
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
push.../../node_modules/rxjs/_esm5/internal/operators/catchError.js.CatchOperator.call @ main.0007badc.js:235917
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
push.../../node_modules/rxjs/_esm5/internal/observable/ConnectableObservable.js.ConnectableObservable.connect @ main.0007badc.js:233290
push.../../node_modules/rxjs/_esm5/internal/operators/refCount.js.RefCountOperator.call @ main.0007badc.js:238965
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
push.../../node_modules/rxjs/_esm5/internal/operators/catchError.js.CatchOperator.call @ main.0007badc.js:235917
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
push.../../node_modules/rxjs/_esm5/internal/operators/tap.js.DoOperator.call @ main.0007badc.js:240622
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
(anonymous) @ main.0007badc.js:21762
decorateSubscribe @ main.0007badc.js:21758
(anonymous) @ main.0007badc.js:21778
(anonymous) @ main.0007badc.js:350330
setTimeout (async)
subscribe @ main.0007badc.js:350322
(anonymous) @ main.0007badc.js:350370
commitHookEffectListMount @ main.0007badc.js:205289
commitPassiveHookEffects @ main.0007badc.js:205327
callCallback @ main.0007badc.js:185746
invokeGuardedCallbackDev @ main.0007badc.js:185795
invokeGuardedCallback @ main.0007badc.js:185850
flushPassiveEffectsImpl @ main.0007badc.js:208411
unstable_runWithPriority @ main.0007badc.js:245310
runWithPriority$1 @ main.0007badc.js:196597
flushPassiveEffects @ main.0007badc.js:208378
(anonymous) @ main.0007badc.js:208257
workLoop @ main.0007badc.js:245254
flushWork @ main.0007badc.js:245209
performWorkUntilDeadline @ main.0007badc.js:244821
Show 38 more frames
main.0007badc.js:58827 2020-07-11 12:49:38 RPC-CORE: getBlock(hash?: BlockHash): SignedBlock:: createType(SignedBlock):: Struct: failed on 'block':: Struct: failed on 'extrinsics':: createType(ExtrinsicV4):: createType(Call):: Struct: failed on 'args':: Cannot construct unknown type Transaction
apply @ main.0007badc.js:58827
error @ main.0007badc.js:58862
logErrorMessage @ main.0007badc.js:27860
(anonymous) @ main.0007badc.js:27986
push.../../node_modules/rxjs/_esm5/internal/operators/catchError.js.CatchSubscriber.error @ main.0007badc.js:235933
push.../../node_modules/rxjs/_esm5/internal/operators/map.js.MapSubscriber._next @ main.0007badc.js:237915
push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.next @ main.0007badc.js:232868
push.../../node_modules/rxjs/_esm5/internal/operators/switchMap.js.SwitchMapSubscriber.notifyNext @ main.0007badc.js:240284
push.../../node_modules/rxjs/_esm5/internal/InnerSubscriber.js.InnerSubscriber._next @ main.0007badc.js:232081
push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.next @ main.0007badc.js:232868
push.../../node_modules/rxjs/_esm5/internal/observable/combineLatest.js.CombineLatestSubscriber.notifyNext @ main.0007badc.js:233830
push.../../node_modules/rxjs/_esm5/internal/InnerSubscriber.js.InnerSubscriber._next @ main.0007badc.js:232081
push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.next @ main.0007badc.js:232868
(anonymous) @ main.0007badc.js:243683
Promise.then (async)
(anonymous) @ main.0007badc.js:243681
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable._trySubscribe @ main.0007badc.js:232250
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232236
subscribeToResult @ main.0007badc.js:243721
push.../../node_modules/rxjs/_esm5/internal/observable/combineLatest.js.CombineLatestSubscriber._complete @ main.0007badc.js:233809
push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.complete @ main.0007badc.js:232880
(anonymous) @ main.0007badc.js:243580
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable._trySubscribe @ main.0007badc.js:232250
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232236
push.../../node_modules/rxjs/_esm5/internal/observable/combineLatest.js.CombineLatestOperator.call @ main.0007badc.js:233779
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
subscribeToResult @ main.0007badc.js:243721
push.../../node_modules/rxjs/_esm5/internal/operators/switchMap.js.SwitchMapSubscriber._innerSub @ main.0007badc.js:240260
push.../../node_modules/rxjs/_esm5/internal/operators/switchMap.js.SwitchMapSubscriber._next @ main.0007badc.js:240250
push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.next @ main.0007badc.js:232868
push.../../node_modules/rxjs/_esm5/internal/operators/map.js.MapSubscriber._next @ main.0007badc.js:237918
push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.next @ main.0007badc.js:232868
(anonymous) @ main.0007badc.js:243578
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable._trySubscribe @ main.0007badc.js:232250
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232236
push.../../node_modules/rxjs/_esm5/internal/operators/map.js.MapOperator.call @ main.0007badc.js:237895
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
push.../../node_modules/rxjs/_esm5/internal/operators/switchMap.js.SwitchMapOperator.call @ main.0007badc.js:240228
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
push.../../node_modules/rxjs/_esm5/internal/operators/map.js.MapOperator.call @ main.0007badc.js:237895
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
push.../../node_modules/rxjs/_esm5/internal/operators/catchError.js.CatchOperator.call @ main.0007badc.js:235917
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
push.../../node_modules/rxjs/_esm5/internal/observable/ConnectableObservable.js.ConnectableObservable.connect @ main.0007badc.js:233290
push.../../node_modules/rxjs/_esm5/internal/operators/refCount.js.RefCountOperator.call @ main.0007badc.js:238965
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
push.../../node_modules/rxjs/_esm5/internal/operators/catchError.js.CatchOperator.call @ main.0007badc.js:235917
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
push.../../node_modules/rxjs/_esm5/internal/operators/tap.js.DoOperator.call @ main.0007badc.js:240622
push.../../node_modules/rxjs/_esm5/internal/Observable.js.Observable.subscribe @ main.0007badc.js:232231
(anonymous) @ main.0007badc.js:21762
decorateSubscribe @ main.0007badc.js:21758
(anonymous) @ main.0007badc.js:21778
(anonymous) @ main.0007badc.js:350330
setTimeout (async)
subscribe @ main.0007badc.js:350322
(anonymous) @ main.0007badc.js:350370
commitHookEffectListMount @ main.0007badc.js:205289
commitPassiveHookEffects @ main.0007badc.js:205327
callCallback @ main.0007badc.js:185746
invokeGuardedCallbackDev @ main.0007badc.js:185795
invokeGuardedCallback @ main.0007badc.js:185850
flushPassiveEffectsImpl @ main.0007badc.js:208411
unstable_runWithPriority @ main.0007badc.js:245310
runWithPriority$1 @ main.0007badc.js:196597
flushPassiveEffects @ main.0007badc.js:208378
(anonymous) @ main.0007badc.js:208257
workLoop @ main.0007badc.js:245254
flushWork @ main.0007badc.js:245209
performWorkUntilDeadline @ main.0007badc.js:244821
Show 23 more frames
main.0007badc.js:34374 Uncaught (in promise) Error: createType(SignedBlock):: Struct: failed on 'block':: Struct: failed on 'extrinsics':: createType(ExtrinsicV4):: createType(Call):: Struct: failed on 'args':: Cannot construct unknown type Transaction
at createTypeUnsafe (main.0007badc.js:34374)
at Rpc._formatOutput (main.0007badc.js:28126)
at MapSubscriber.project (main.0007badc.js:27985)
at MapSubscriber.push.../../node_modules/rxjs/_esm5/internal/operators/map.js.MapSubscriber._next (main.0007badc.js:237912)
at MapSubscriber.push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.next (main.0007badc.js:232868)
at SwitchMapSubscriber.push.../../node_modules/rxjs/_esm5/internal/operators/switchMap.js.SwitchMapSubscriber.notifyNext (main.0007badc.js:240284)
at InnerSubscriber.push.../../node_modules/rxjs/_esm5/internal/InnerSubscriber.js.InnerSubscriber._next (main.0007badc.js:232081)
at InnerSubscriber.push.../../node_modules/rxjs/_esm5/internal/Subscriber.js.Subscriber.next (main.0007badc.js:232868)
at CombineLatestSubscriber.push.../../node_modules/rxjs/_esm5/internal/observable/combineLatest.js.CombineLatestSubscriber.notifyNext (main.0007badc.js:233830)
at InnerSubscriber.push.../../node_modules/rxjs/_esm5/internal/InnerSubscriber.js.InnerSubscriber._next (main.0007badc.js:232081)
RPC tests need handle of client, transaction pool, select chain and a convert transaction handle. They probably need some mock structures.
Trying to deploy flow-protocol-ethereum makes the node to increase memory use and not responding to rpc calls or producing new blocks. It will run fine for a while then it's like it gets stuck into a loop.
cargo run -- build-spec --dev > specs.json
specs.json
to give 0xb393de29a6a341a32758735a160f3561b88fded0
some balance"frameEvm": {
"accounts": {
"0xb393de29a6a341a32758735a160f3561b88fded0": {
"nonce": "0x0",
"balance": "0xffffffffffffffffffffffffffffffff",
"storage": {},
"code": []
}
}
cargo run -- --chain=specs.json --execution=Native --validator --alice --force-authoring --rpc-port=8545 --tmp
flow-protocol-ethereum
git clone [email protected]:laminar-protocol/flow-protocol-ethereum.git
cd flow-protocol-ethereum
git checkout frontier
yarn install
yarn deploy:development
the deployment will go well for a while and after a few minutes the node will stop responding and producing blocks and memory usage will keep growing.
Currently if block_number
is passed as pending
it will return 0
. Should return current nonce + pending_transactions_to_be_sealed
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.