lotus/api
Phi-rjan 9dc29bf3f7
chore:: backport #11609 to the feat/nv22 branch (#11644)
* feat: api: improve the correctness of Eth's trace_block (#11609)

* Improve the correctness of Eth's trace_block

- Improve encoding/decoding of parameters and return values:
  - Encode "native" parameters and return values with Solidity ABI.
  - Correctly decode parameters to "create" calls.
  - Use the correct (ish) output for "create" calls.
  - Handle all forms of "create".
- Make robust with respect to reverts:
  - Use the actor ID/address from the trace instead of looking it up in
    the state-tree (may not exist in the state-tree due to a revert).
  - Gracefully handle failed actor/contract creation.
- Improve performance:
  - We avoid looking anything up in the state-tree when translating the
    trace, which should significantly improve performance.
- Improve code readability:
  - Remove all "backtracking" logic.
  - Use an "environment" struct to store temporary state instead of
    attaching it to the trace.
- Fix random bugs:
  - Fix an allocation bug in the "address" logic (need to set the
    capacity before modifying the slice).
  - Improved error checking/handling.
- Use correct types for `trace_block` action/results (create, call, etc.).
  - And use the correct types for Result/Action structs instead of reusing the same "Call" action every time.
- Improve error messages.

* Make gen

Make gen

---------

Co-authored-by: Steven Allen <steven@stebalien.com>
2024-02-27 07:50:07 -08:00
..
client
docgen feat: fvm: update the FVM/FFI to v4.1 (#11608) (#11612) 2024-02-07 14:22:23 -08:00
docgen-openrpc
mocks
types
v0api
v1api
api_common.go
api_errors.go
api_full.go chore:: backport #11609 to the feat/nv22 branch (#11644) 2024-02-27 07:50:07 -08:00
api_gateway.go Make block param to EthEstimateGas optional 2023-11-29 10:26:22 +00:00
api_lp.go
api_net.go
api_storage.go
api_test.go
api_wallet.go
api_worker.go
cbor_gen.go
checkstatuscode_string.go
eth_aliases.go
miner_subsystems.go
permissioned.go
proxy_gen.go
proxy_util_test.go
proxy_util.go
README.md
types.go
utils.go
version.go
wrap.go

Lotus API

This package contains all lotus API definitions. Interfaces defined here are exposed as JsonRPC 2.0 endpoints by lotus programs.

Versions

File Alias File Interface Exposed by Version HTTP Endpoint Status Docs
api_common.go v0api/latest.go Common lotus; lotus-miner v0 /rpc/v0 Latest, Stable Methods
api_full.go v1api/latest.go FullNode lotus v1 /rpc/v1 Latest, Work in progress Methods
api_storage.go v0api/latest.go StorageMiner lotus-miner v0 /rpc/v0 Latest, Stable Methods
api_worker.go v0api/latest.go Worker lotus-worker v0 /rpc/v0 Latest, Stable Methods
v0api/full.go FullNode lotus v0 /rpc/v0 Stable Methods