debug_traceCall and debug_traceBlock #261

Open
i-norden wants to merge 16 commits from ian/tracing into v5
Member

Implement the debug_traceCall and debug_traceBlock methods using the direct state/storage access pattern supported by ipld-eth-statedb. For #260. Relies on cerc-io/ipld-eth-statedb#4.

In geth, it is possible to perform these traces on top of state which does not exist in the underlying DB by regenerating the state from the last known state below where the requested state exists. It does this by loading that state and then re-executing blocks until it regenerates the state expected for the trace. This feature makes sense in geth where the goal may be to operate without a complete archive.

I removed this capability here as it simplifies things and because I don't think this issue should ever be fixed this way. Our goal is to have a complete archive, if we are missing state in the database that is a problem that needs to be fixed at a different level. Rather than ephemerally regenerating the missing state to use in a single query/trace, which could be quite expensive, the effort should be spent on properly entering and indexing the missing data into the underlying database.

Implement the `debug_traceCall` and `debug_traceBlock` methods using the direct state/storage access pattern supported by ipld-eth-statedb. For https://git.vdb.to/cerc-io/ipld-eth-server/issues/260. Relies on https://git.vdb.to/cerc-io/ipld-eth-statedb/pulls/4. In geth, it is possible to perform these traces on top of state which does not exist in the underlying DB by regenerating the state from the last known state below where the requested state exists. It does this by loading that state and then re-executing blocks until it regenerates the state expected for the trace. This feature makes sense in geth where the goal may be to operate without a complete archive. I removed this capability here as it simplifies things and because I don't think this issue should ever be fixed this way. Our goal is to have a complete archive, if we are missing state in the database that is a problem that needs to be fixed at a different level. Rather than ephemerally regenerating the missing state to use in a single query/trace, which could be quite expensive, the effort should be spent on properly entering and indexing the missing data into the underlying database.
i-norden added 8 commits 2023-11-01 20:23:52 +00:00
i-norden added 1 commit 2023-11-01 21:09:04 +00:00
i-norden added 3 commits 2023-11-02 13:22:23 +00:00
Author
Member

Hmm I'm wondering where our CI testing went for this repo...

Hmm I'm wondering where our CI testing went for this repo...
i-norden force-pushed ian/tracing from 7e8b372a56 to 1d578b3bf9 2023-11-02 18:03:27 +00:00 Compare
i-norden added 1 commit 2023-11-06 13:27:07 +00:00
go mod
Some checks failed
Test the stack. / Run unit tests (pull_request) Failing after 9m59s
Test the stack. / Run integration tests (pull_request) Failing after 11m47s
0b53b52b3f
i-norden force-pushed ian/tracing from 0b53b52b3f to cae2a3e843 2023-11-06 13:47:54 +00:00 Compare
i-norden force-pushed ian/tracing from cae2a3e843 to 51747c01a4 2023-11-06 13:49:23 +00:00 Compare
i-norden force-pushed ian/tracing from 51747c01a4 to 8ff7b4077b 2023-11-06 13:57:58 +00:00 Compare
i-norden force-pushed ian/tracing from 8ff7b4077b to 8dfdfcc484 2023-11-06 14:10:28 +00:00 Compare
i-norden force-pushed ian/tracing from 8dfdfcc484 to 877b731340 2023-11-06 14:25:15 +00:00 Compare
i-norden added 1 commit 2023-11-08 14:19:40 +00:00
fix CI errors
Some checks failed
Test the stack. / Run unit tests (pull_request) Failing after 4m18s
Test the stack. / Run integration tests (pull_request) Failing after 9m18s
a2fe12334c
i-norden force-pushed ian/tracing from a2fe12334c to fbcc9664da 2023-11-08 14:44:47 +00:00 Compare
i-norden force-pushed ian/tracing from fbcc9664da to ec49318294 2023-11-08 14:54:41 +00:00 Compare
Author
Member

Hey @roysc @telackey curious if you have seen this error that is popping up when trying to use stack-orchestrator to run the testnet tests (it can't find ipld-eth-db v5.0.5-alpha)?

Hey @roysc @telackey curious if you have seen this error that is popping up when trying to use stack-orchestrator to run the testnet tests (it can't find ipld-eth-db v5.0.5-alpha)?
Owner

I'm not sure of the whole context, but that branch (or tag) doesn't exist in this repo: https://github.com/cerc-io/ipld-eth-db
Should it be pulling the Gitea hosted version of the repo? (but I don't see that branch there either). I'm actually not sure where
v5.0.5-alpha came from because in the log it said it was looking for branch v5.

I'm not sure of the whole context, but that branch (or tag) doesn't exist in this repo: https://github.com/cerc-io/ipld-eth-db Should it be pulling the Gitea hosted version of the repo? (but I don't see that branch there either). I'm actually not sure where v5.0.5-alpha came from because in the log it said it was looking for branch v5.
Author
Member

@dboreham none of the v5 tags appear to be in that repo any longer if you view the releases here https://github.com/cerc-io/ipld-eth-db/releases or tags here https://github.com/cerc-io/ipld-eth-db/tags, but you can still see the v5.0.5-alpha release here: https://github.com/cerc-io/ipld-eth-db/releases/tag/v5.0.5-alpha and v5.0.5-alpha is the version in use across most our repos currently. Something weird has happened to our tagged releases...

@dboreham none of the v5 tags appear to be in that repo any longer if you view the releases here https://github.com/cerc-io/ipld-eth-db/releases or tags here https://github.com/cerc-io/ipld-eth-db/tags, but you can still see the v5.0.5-alpha release here: https://github.com/cerc-io/ipld-eth-db/releases/tag/v5.0.5-alpha and v5.0.5-alpha is the version in use across most our repos currently. Something weird has happened to our tagged releases...
Author
Member

And it looks like all the v5 releases are gone in the gitea repo too: https://git.vdb.to/cerc-io/ipld-eth-db/tags

And it looks like all the v5 releases are gone in the gitea repo too: https://git.vdb.to/cerc-io/ipld-eth-db/tags
Owner

The relationship between releases and tags is odd, iirc.
Probably the thing to do is to trigger a new release on the Gitea side.
We can't use releases from Github (as far as I know) because the sync from Gitea will blow them away.

The relationship between releases and tags is odd, iirc. Probably the thing to do is to trigger a new release on the Gitea side. We can't use releases from Github (as far as I know) because the sync from Gitea will blow them away.
Author
Member

Inconsistencies in the releases and tags seem to be present in many of the repos that have been ported over to gitea

Inconsistencies in the releases and tags seem to be present in many of the repos that have been ported over to gitea
i-norden added 1 commit 2023-11-16 14:39:38 +00:00
update ipld-eth-db ref
Some checks failed
Test the stack. / Run unit tests (pull_request) Failing after 5m32s
Test the stack. / Run integration tests (pull_request) Successful in 42m35s
c7f0c9a1a4
i-norden force-pushed ian/tracing from c7f0c9a1a4 to b9983b8c55 2023-11-20 13:32:43 +00:00 Compare
i-norden force-pushed ian/tracing from b9983b8c55 to ec49318294 2023-11-20 13:50:30 +00:00 Compare
i-norden added 2 commits 2023-12-07 06:41:19 +00:00
update ipld-eth-db ref
Some checks failed
Test the stack. / Run unit tests (pull_request) Failing after 5m32s
Test the stack. / Run integration tests (pull_request) Successful in 42m35s
c7f0c9a1a4
CICD_REPO_TOKEN => CICD_PUBLISH_TOKEN
Some checks failed
Test the stack. / Run unit tests (pull_request) Failing after 5m34s
Test the stack. / Run integration tests (pull_request) Successful in 44m23s
6b271ce5f3
i-norden force-pushed ian/tracing from 6b271ce5f3 to c7f0c9a1a4 2023-12-07 07:15:50 +00:00 Compare
Author
Member

I'd like to merge this, the tests pass, but there is an issue with the ipld-eth-db image not being published https://git.vdb.to/cerc-io/ipld-eth-db/actions/runs/1

I'd like to merge this, the tests pass, but there is an issue with the ipld-eth-db image not being published https://git.vdb.to/cerc-io/ipld-eth-db/actions/runs/1
i-norden added 1 commit 2024-01-22 20:11:12 +00:00
bump ipld-eth-db to v5.2.1-alpha
Some checks failed
Test the stack. / Run unit tests (pull_request) Successful in 5m23s
Test the stack. / Run integration tests (pull_request) Failing after 9m24s
3399e4aa3c
i-norden force-pushed ian/tracing from 3399e4aa3c to 2009cecefd 2024-01-22 20:16:36 +00:00 Compare
i-norden force-pushed ian/tracing from 2009cecefd to 29c1523eb8 2024-01-22 20:17:37 +00:00 Compare
i-norden added 1 commit 2024-01-24 17:11:23 +00:00
update SO version
Some checks failed
Test the stack. / Run unit tests (pull_request) Successful in 4m51s
Test the stack. / Run integration tests (pull_request) Failing after 4m58s
86e9d79d47
i-norden force-pushed ian/tracing from 86e9d79d47 to a8d6ca8305 2024-01-25 15:58:30 +00:00 Compare
i-norden force-pushed ian/tracing from a8d6ca8305 to 8ec25764cd 2024-01-25 20:44:40 +00:00 Compare
i-norden force-pushed ian/tracing from 8ec25764cd to 402a6e183b 2024-01-29 14:30:35 +00:00 Compare
Some checks failed
Test the stack. / Run unit tests (pull_request) Successful in 5m4s
Test the stack. / Run integration tests (pull_request) Failing after 5m37s
This pull request has changes conflicting with the target branch.
  • .github/workflows/tests.yaml
  • go.mod
  • go.sum
  • pkg/eth/api.go
  • pkg/eth/test_helpers/chain_indexer.go
  • test/compose-db.yml
  • test/stack-refs.txt

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin ian/tracing:ian/tracing
git checkout ian/tracing
Sign in to join this conversation.
No reviewers
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: cerc-io/ipld-eth-server#261
No description provided.