Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add session key plugin abi and plugingen #284

Merged
merged 4 commits into from
Dec 15, 2023

Conversation

denniswon
Copy link
Contributor

@denniswon denniswon commented Nov 26, 2023

https://alchemyinsights.slack.com/archives/C04RHSDSP9U/p1700594853613719?thread_ts=1700590335.741369&cid=C04RHSDSP9U


PR-Codex overview

Focus of this PR:

This PR focuses on adding a new SessionKeyPlugin to the accounts package. It also includes updates to the plugin manager, types, and other related files.

Detailed summary:

  • Added SessionKeyPluginGenConfig to export the plugin configuration.
  • Added FunctionId and FunctionReference types to types.ts.
  • Updated multi-owner-account.ts to extend with the TokenReceiverPlugin.
  • Added encodeFunctionReference function to utils.ts.
  • Added SessionKeyPluginGenConfig to export the plugin configuration.
  • Updated installPlugin.ts to include FunctionReference in the dependencies parameter.
  • Updated index.ts to export accountLoupeDecorators, FunctionId, and FunctionReference.
  • Updated useAlchemyProvider.ts to import and use SessionKeyPlugin.
  • Added PluginType enum to useAlchemyProvider.ts.
  • Added pluginInstall function to useAlchemyProvider.ts.
  • Added SessionKeyPlugin and SessionKeyPluginExecutionFunctionAbi to session-key.ts.
  • Added SessionKeyPluginAbi to abi.ts.

The following files were skipped due to too many changes: packages/accounts/plugindefs/session-key/abi.ts

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

Copy link
Collaborator

@moldy530 moldy530 left a comment

Choose a reason for hiding this comment

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

can you rebase ontop of moldy/msca-provider-decorators and set that as the base? that branch adds provider decorators as part of the auto generation

@moldy530 moldy530 force-pushed the moldy/plugin-manager branch 3 times, most recently from 7a7328f to 9e24f7b Compare November 30, 2023 16:33
Base automatically changed from moldy/plugin-manager to msca-base December 1, 2023 16:25
@moldy530 moldy530 force-pushed the denniswon/msca-sessionkey-plugin branch from 39a6638 to 982a4eb Compare December 1, 2023 17:49
@moldy530
Copy link
Collaborator

moldy530 commented Dec 1, 2023

you'll need to run yarn generate again now that msca-base has the provider decorators available in it

@avasisht23 avasisht23 force-pushed the msca-base branch 2 times, most recently from c69950e to 4bc3911 Compare December 3, 2023 02:04
@moldy530 moldy530 force-pushed the denniswon/msca-sessionkey-plugin branch 2 times, most recently from 5d44246 to 4aa6de5 Compare December 4, 2023 19:39
@denniswon denniswon force-pushed the denniswon/msca-sessionkey-plugin branch from 4aa6de5 to 5193181 Compare December 4, 2023 22:41
@denniswon denniswon changed the base branch from msca-base to denniswon/msca-accout-loupe December 4, 2023 22:41
@denniswon denniswon force-pushed the denniswon/msca-sessionkey-plugin branch from 5193181 to c11f9c2 Compare December 5, 2023 22:54
@denniswon denniswon force-pushed the denniswon/msca-sessionkey-plugin branch 4 times, most recently from 13be4c9 to 98064a7 Compare December 11, 2023 21:58
@denniswon denniswon changed the base branch from denniswon/msca-plugingen to denniswon/msca-token-receiver December 12, 2023 01:40
@denniswon denniswon force-pushed the denniswon/msca-sessionkey-plugin branch from 98064a7 to 3349788 Compare December 12, 2023 01:41
@denniswon denniswon force-pushed the denniswon/msca-sessionkey-plugin branch from 3349788 to fd1de2d Compare December 12, 2023 20:46
@denniswon denniswon force-pushed the denniswon/msca-sessionkey-plugin branch from fd1de2d to 3a29d52 Compare December 13, 2023 00:44
@denniswon denniswon force-pushed the denniswon/msca-sessionkey-plugin branch from 3a29d52 to 910dd8e Compare December 13, 2023 00:55
@denniswon denniswon force-pushed the denniswon/msca-sessionkey-plugin branch from 910dd8e to abc17bb Compare December 13, 2023 01:15
@denniswon denniswon force-pushed the denniswon/msca-sessionkey-plugin branch from abc17bb to ec3de5b Compare December 15, 2023 17:09
@denniswon denniswon force-pushed the denniswon/msca-token-receiver branch 2 times, most recently from 7ec80f8 to 36132cf Compare December 15, 2023 21:10
Base automatically changed from denniswon/msca-token-receiver to msca-base December 15, 2023 21:12
@denniswon denniswon force-pushed the denniswon/msca-sessionkey-plugin branch from ec3de5b to 649e692 Compare December 15, 2023 21:16
@denniswon denniswon merged commit 8748cc3 into msca-base Dec 15, 2023
2 checks passed
@denniswon denniswon deleted the denniswon/msca-sessionkey-plugin branch December 15, 2023 21:27
moldy530 pushed a commit that referenced this pull request Jan 8, 2024
* feat: msca plugingen to accept multichain address format

* feat: msca token receiver plugin with opt out option to exclude default token receiver plugin

* feat: msca token receiver plugin with opt out option to exclude default token receiver plugin

* feat: add session key plugin abi and plugingen
moldy530 added a commit that referenced this pull request Jan 8, 2024
* feat: add some plugin generation logic (#262)

* feat: add some plugin generation logic

* chore: add generate commands

* style: apply PR suggestion

Co-authored-by: Dennis Won <[email protected]>

* refactor: create plugin config concept

* feat: add multi-owner-msca impl that leverages the plugin gen (#263)

* feat: add multi-owner-msca impl that leverages the plugin gen

* feat: proposal for msca builder pattern (#264)

* feat: proposal for msca builder pattern

* refactor: rework plugin gen to create read methods for the account

---------

Co-authored-by: Dennis Won <[email protected]>

* chore: lint

* feat: add plugin manager decorator for MSCA (#274)

* feat: add initial skeleton for 6900 account support

* feat: add some plugin generation logic (#262)

* feat: add some plugin generation logic

* chore: add generate commands

* style: apply PR suggestion

Co-authored-by: Dennis Won <[email protected]>

* refactor: create plugin config concept

* feat: add multi-owner-msca impl that leverages the plugin gen (#263)

* feat: add multi-owner-msca impl that leverages the plugin gen

* feat: proposal for msca builder pattern (#264)

* feat: proposal for msca builder pattern

* refactor: rework plugin gen to create read methods for the account

---------

Co-authored-by: Dennis Won <[email protected]>

* chore: update plugin gen

* feat: add plugin manager decorator for MSCA

* feat: add a mechanism for adding provider decorators to accounts (#287)

* feat: add a mechanism for adding provider decorators to accounts

* chore: update lerna and package json to lint generated files

* refactor: rename MSCA to IMSCA

---------

Co-authored-by: Dennis Won <[email protected]>
Co-authored-by: avasisht23 <[email protected]>

* fix: missed some plugingen fixes

* refactor: change the names of the plugin decorators and add example usages (#308)

* feat: extend msca account with account loupe decorators (#309)

* refactor: move required by types to aa-core utils types folder

* feat: extend msca account with account loupe decorators

* feat: move extend method on account from msca to base account

* Update packages/core/src/account/types.ts

Co-authored-by: Michael Moldoveanu <[email protected]>

* Update packages/core/src/account/types.ts

Co-authored-by: Michael Moldoveanu <[email protected]>

* Update packages/core/src/account/types.ts

Co-authored-by: Michael Moldoveanu <[email protected]>

* Update packages/accounts/src/msca/account-loupe/decorator.ts

Co-authored-by: Michael Moldoveanu <[email protected]>

* fix: fix lint and build

---------

Co-authored-by: Michael Moldoveanu <[email protected]>

* fix: update the logic for signing 1271 messages

* feat: msca plugingen to accept multichain address format (#314)

* feat: msca plugingen to accept multichain address format

* Update packages/accounts/scripts/plugingen.ts

Co-authored-by: Michael Moldoveanu <[email protected]>

* Update packages/accounts/wagmi.config.ts

Co-authored-by: Michael Moldoveanu <[email protected]>

* feat: changed address field in plugingenconfig to addresses

---------

Co-authored-by: Michael Moldoveanu <[email protected]>

* feat: msca token receiver plugin with opt out option to exclude default token receiver plugin (#316)

* feat: msca plugingen to accept multichain address format

* feat: msca token receiver plugin with opt out option to exclude default token receiver plugin

* feat: add session key plugin abi and plugingen (#284)

* feat: msca plugingen to accept multichain address format

* feat: msca token receiver plugin with opt out option to exclude default token receiver plugin

* feat: msca token receiver plugin with opt out option to exclude default token receiver plugin

* feat: add session key plugin abi and plugingen

* feat: msca plugin provider decorator to support user op overrides (#342)

* feat: msca plugingen to generate subfolders for each plugin (#350)

---------

Co-authored-by: Dennis Won <[email protected]>
Co-authored-by: avasisht23 <[email protected]>
avasisht23 pushed a commit that referenced this pull request Jan 9, 2024
* feat: msca plugingen to accept multichain address format

* feat: msca token receiver plugin with opt out option to exclude default token receiver plugin

* feat: msca token receiver plugin with opt out option to exclude default token receiver plugin

* feat: add session key plugin abi and plugingen
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.

2 participants