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: have set_env return a context manager #329

Merged
merged 2 commits into from
Oct 10, 2024

Conversation

DanielSchiavini
Copy link
Collaborator

@DanielSchiavini DanielSchiavini commented Oct 9, 2024

What I did

  • Use the Open helper in set_env

How I did it

  • Refactor other methods to use set_env instead of _env_mgr as they became the same

Cute Animal Picture

image

@DanielSchiavini DanielSchiavini marked this pull request as ready for review October 9, 2024 10:55
boa/__init__.py Outdated Show resolved Hide resolved
@charles-cooper charles-cooper changed the title feat: allow env swap via set_env feat: have set_env return a context manager Oct 10, 2024
@charles-cooper charles-cooper merged commit bedd49e into vyperlang:master Oct 10, 2024
9 checks passed
@DanielSchiavini DanielSchiavini deleted the set-env branch October 10, 2024 18:23
Leminkay pushed a commit to Leminkay/titanoboa that referenced this pull request Oct 28, 2024
use the Open helper so that `set_env` can be used in with statements,
restoring the original env when exiting the block.
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