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: unlock acct for auto-signing if alias resolves to KeyfileAccount #97

Merged
merged 3 commits into from
Aug 26, 2024

Conversation

fubuloubu
Copy link
Member

What I did

This PR add a small UX enhancement where acct.set_autosign(True) is automatically called if a KeyfileAccount is provided for the alias. This will assist testing in local scenarios for rapid prototyping with a local wallet.

fixes: #90

How to verify it

$ silverback run example:app --network ethereum:mainnet
...  # runs just fine without a signer

$ silverback run example:app --network ethereum:mainnet --account <my-keyfile-alias>
INFO: Loading Silverback App with settings:
  APP_NAME="bot"
  ...
Enter passphrase to permanently unlock 'my-keyfile-alias':
WARNING: Danger! This account will now sign any transaction it's given.
SUCCESS: Loaded Silverback App:
  NETWORK="ethereum:mainnet"
  SIGNER=<KeyfileAccount address=0x...  alias=dev >
INFO: Using WebsocketRunner: max_exceptions=3
...

Checklist

  • Passes all linting checks (pre-commit and CI jobs)
    - [ ] New test cases have been added and are passing
  • Documentation has been updated
  • PR title follows Conventional Commit standard (will be automatically included in the changelog)

@fubuloubu fubuloubu enabled auto-merge (squash) July 19, 2024 21:17
Copy link
Member

@mikeshultz mikeshultz left a comment

Choose a reason for hiding this comment

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

LGTM

@fubuloubu fubuloubu merged commit 14f7a8d into main Aug 26, 2024
22 checks passed
@fubuloubu fubuloubu deleted the feat/set-autosign branch August 26, 2024 21:56
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.

Add autosign to runner
2 participants