watcher-ts/packages/solidity-mapper
nikugogoi ce182bce85
Clear cache of latest entities on event processing error (#201)
* Clear cache of latest entities on event processing error

* Remove lighthouse-watcher and update ethersjs version

* Handle GraphDecimal type in state entity

* Add option for comparing all entities using paginate

* Clear pruned cached entities at intervals

* Move ipld-demo to graph-node package and remove reset-dbs script

* Implement changes in all watchers and codegen
2022-10-19 14:26:10 +05:30
..
src Clear cache of latest entities on event processing error (#201) 2022-10-19 14:26:10 +05:30
test Parse batched transactions for mobymask-watcher events (#141) 2022-07-11 11:29:33 +05:30
.env.example Test decoder using hardhat RPC, geth-statediff RPC and ipld-eth-server GQL endpoints for fetching storage slots (#77) 2021-06-18 18:09:50 +05:30
.eslintignore Get slot for ERC20 variable from storage layout (#13) 2021-05-31 14:50:05 +05:30
.eslintrc.json Get slot for ERC20 variable from storage layout (#13) 2021-05-31 14:50:05 +05:30
.gitignore Test decoder using hardhat RPC, geth-statediff RPC and ipld-eth-server GQL endpoints for fetching storage slots (#77) 2021-06-18 18:09:50 +05:30
.npmignore Changes to use packages in uniswap-watcher (#196) 2022-10-11 13:41:26 +05:30
hardhat.config.ts Test decoder using hardhat RPC, geth-statediff RPC and ipld-eth-server GQL endpoints for fetching storage slots (#77) 2021-06-18 18:09:50 +05:30
package.json v0.2.13 (#197) 2022-10-11 16:12:06 +05:30
README.md Test decoder using hardhat RPC, geth-statediff RPC and ipld-eth-server GQL endpoints for fetching storage slots (#77) 2021-06-18 18:09:50 +05:30
tsconfig.json Enable source maps for transpiled files (#242) 2021-09-07 16:01:15 +05:30

solidity-mapper

Get value of state variable from storage for a solidity contract.

Pre-requisites

Instructions

  • Create environment variable file

    $ cp .env.example .env
    
  • Run the tests using the following command

    $ yarn test
    
    # For testing on private network using RPC getStorageAt.
    # Set ETH_RPC_URL in .env
    $ yarn test:geth-rpc
    
    # For testing on private network using ipld-eth-client getStorageAt.
    # Set GQL_ENDPOINT in .env
    $ yarn test:ipld-gql
    

Different Types

  • Value Types
    • Booleans
    • Integers
    • Fixed Point Numbers
    • Address
    • Contract Types
    • Fixed-size byte arrays
    • Enums
    • Function Types
  • Reference Types
    • Arrays
      • Get all elements in array
      • Get element in array by index
      • Fixed size arrays
        • Integer Type
        • Boolean Type
        • Address Type
        • Fixed-size byte arrays
        • Enum type
        • Dynamically-sized byte array
        • Struct Type
        • Mapping Type
      • Dynamically-sized arrays
        • Integer Type
        • Boolean Type
        • Address Type
        • Fixed-size byte arrays
        • Enum Type
        • Dynamically-sized byte array
        • Struct Type
        • Mapping Type
      • Nested Arrays
        • Fixed size arrays
        • Dynamically-sized arrays
    • Dynamically-sized byte array
      • Bytes
      • String
    • Structs
      • Get struct value with all members
      • Value Types
      • Get value of a single member in struct
      • Reference Types
        • Struct type members (nested)
        • Fixed size Array members
        • Dynamically sized Array members
        • Bytes and string type members
        • Mapping type members
    • Mapping Types
      • Value Type keys
      • Fixed-size byte array keys
      • Dynamically-sized byte array keys
      • Reference Type Mapping values
        • Struct type values
        • Array type values
        • Dynamically sized Bytes and string type values
      • Nested Mapping

Observations