Add base config

This commit is contained in:
nolash
2021-07-17 08:22:02 +02:00
parent 388910a4ac
commit a6420eacfb
3 changed files with 43 additions and 7 deletions

View File

@@ -24,6 +24,16 @@ class EthAdapter(Adapter):
return tx
def dispatch(self, chain_spec, rpc, tx_hash, signed_tx, session=None):
o = raw(signed_tx)
r = self.backend.dispatch(chain_spec, rpc, tx_hash, o)
return r
def upcoming(self, chain_spec, session=None):
return self.backend.get(chain_spec, StatusBits.QUEUED, self.translate) # possible maldesign, up-stack should use our session?
def add(self, chain_spec, bytecode, session=None):
tx = self.translate(chain_spec, bytecode)
r = self.backend.create(chain_spec, tx['nonce'], tx['from'], tx['hash'], add_0x(bytecode.hex()), session=session)