Skip to content

Conversation

ceyonur
Copy link
Collaborator

@ceyonur ceyonur commented Jul 3, 2025

Why this should be merged

This PR fully wraps the plugin/evm/vm as innerVM in atomic/vm/vm and completely seperates out atomicVM from plugin/evm/vm.

This PR does not move tests to atomic package, a subsequent PR will do that with introducing a refactor to vm tests.

How this works

This pull request introduces several updates to the plugin/evm/atomic/vm module, focusing on improving code consistency, simplifying the verification logic, and updating dependencies. The most significant changes include replacing ctx with Ctx for better naming consistency, refactoring the SemanticVerifier implementation, and updating the avalanchego dependency version.

Code consistency improvements:

  • Replaced ctx with Ctx across the VM struct and its associated methods to align with Go conventions for exported fields. This change affects multiple files, including plugin/evm/atomic/vm/vm.go and plugin/evm/atomic/vm/api.go. [1] [2] [3] [4] [5]

Refactoring for semantic verification:

  • Refactored the SemanticVerifier into a new VerifierBackend and semanticVerifier structure, simplifying the logic for verifying atomic transactions. This change improves modularity and readability in plugin/evm/atomic/vm/tx_semantic_verifier.go. [1] [2] [3] [4] [5]

Dependency updates:

  • Updated the avalanchego dependency in go.mod to version v1.13.1-rc.4.0.20250531182522-ce450499b7d7 for compatibility with the latest changes.
  • Added github.com/NYTimes/gziphandler v1.1.1 as an indirect dependency in go.mod.

Workflow adjustments:

  • Updated the run-monitored-tmpnet-cmd action version in .github/workflows/ci.yml to ce450499b7d7c3f7b8927185b6a7b778856a702e for both standard and Warp E2E tests. [1] [2]

Miscellaneous improvements:

  • Re-enabled previously commented-out functionality in methods such as SetState and CreateHandlers in plugin/evm/atomic/vm/vm.go, ensuring the atomic VM fully wraps the inner VM. [1] [2]

How this was tested

Modified existing tests

Need to be documented?

no

Need to update RELEASES.md?

updated

@ceyonur ceyonur marked this pull request as ready for review July 3, 2025 10:28
@ceyonur ceyonur requested a review from a team as a code owner July 3, 2025 10:28
ceyonur added 2 commits July 4, 2025 12:20
Signed-off-by: Ceyhun Onur <ceyhun.onur@avalabs.org>
@ceyonur ceyonur enabled auto-merge July 7, 2025 13:02
@ceyonur ceyonur added this pull request to the merge queue Jul 7, 2025
Merged via the queue into master with commit f0ef658 Jul 7, 2025
9 checks passed
@ceyonur ceyonur deleted the atomic-vm-finalize-1 branch July 7, 2025 13:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants