Skip to content

Conversation

shunkakinoki
Copy link

@shunkakinoki shunkakinoki commented Feb 20, 2025

Includes all required core configuration, imageHash, signature modules derived from sequence-core for v3 and ensures that all critical tests are passing.

Steps to test

  1. Run the following command from the root go repository to initiate the rpc:
go run ./cmd/sequence/ server
  1. In the v3 module, run the following foundry tests:
forge test --mp test/modules/BaseSig.t.sol
forge test --mp test/modules/Calls.t.sol
forge test --mp test/modules/Payload.t.sol
forge test --mp test/Guest.t.sol
forge test --mp test/Stage1Module.t.sol
forge test --mp test/Wallet.t.sol

Caveats

Some gas-estimation commands, etc. are commented out because of the scope of this PR. will follow up in a later PR. Also, Permission, SmartSession, SessionManager related modules will follow up later.

@shunkakinoki shunkakinoki changed the base branch from master to waas-scoped-sessions February 25, 2025 11:44
@shunkakinoki shunkakinoki changed the base branch from waas-scoped-sessions to master February 25, 2025 11:45
@attente attente force-pushed the v3-core branch 2 times, most recently from 86d26f3 to 56c6f8a Compare February 26, 2025 16:20
@shunkakinoki shunkakinoki requested a review from attente February 27, 2025 10:03
shunkakinoki and others added 17 commits July 14, 2025 18:58
- Removed unnecessary parameters from GetIntentConfigurationSignature, streamlining its functionality.
- Cleaned up related test cases in intent_config_test.go to reflect the updated method signature.
- Eliminated unused types and functions related to TrailsExecutionInfo, enhancing code clarity and maintainability.
…configuration (#275)

- Updated Factory, MainModule, MainModuleUpgradable, and Guest addresses in `network.go`.
- Modified expected address in `TestIntentConfigurationAddress_RealWorldExample` in `intent_config_test.go`.
- Adjusted expected wallet address and signature in `TestWalletSignMessageAndValidate` in `wallet_test.go`.
- Updated contract artifacts for wallet contracts in JSON files.
…ests by removing unnecessary common.Address parameter
- Updated Factory, MainModule, MainModuleUpgradable, and Guest addresses in `network.go`.
- Modified the creation code for V3 in `contracts/contracts.go` to reflect recent changes.
- Updated bytecode and deployed bytecode for various contracts including Estimator, Factory, Guest, Simulator, Stage1Module, Stage2Module, Wallet, and Passkeys.
- Added new interfaces for IERC223Receiver, IERC721Receiver, and IERC1155Receiver.
- Modified existing contracts to reflect changes in bytecode and structure.
- Ensured consistency across all contract artifacts in the wallet-contracts-v3 directory.
- Updated Factory, MainModule, MainModuleUpgradable, Guest, and Utils addresses in `helpers.go` to reflect the latest deployment changes.
- Ensured consistency with the recent updates in contract artifacts for V3.
- Introduced a new method `Approval` in the ImageHash struct to generate a digest that must be signed for subsequent ImageHash approvals.
- Utilized a predefined salt for the hashing process to ensure consistency and security in the approval mechanism.
if err != nil {
return common.Address{}, fmt.Errorf("sequence, AddressFromImageHash: %w", err)
return common.Address{}, fmt.Errorf(`invalid creation code "%v": %w`, context.CreationCode, err)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
return common.Address{}, fmt.Errorf(`invalid creation code "%v": %w`, context.CreationCode, err)
return common.Address{}, fmt.Errorf("invalid creation code %q: %w", context.CreationCode, err)

Copy link
Contributor

@VojtechVitek VojtechVitek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@shunkakinoki @attente before I go through the PR in detail, what's the high-level update on this PR? Did we stabilize the v3 contracts? Is this backward-compatible regarding v1/v2?

(+38,535 added lines makes me a bit nervous :D)

It looks like we're already using this branch in relayer -- https://github.com/0xsequence/relayer/blob/master/go.mod#L29.

And we're ready to use it in stack/api too: https://github.com/0xsequence/stack/pull/1187.

That makes me think we're close?

Do we need any more time to refactor/polish this PR? Or is this ready to go?

lib/forge-std Outdated
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are we adding a new git module into the repository? Do we need to?

Can we embed/vendor/use forge some other way?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants