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

fix: vvm version detection #343

Merged
merged 8 commits into from
Nov 22, 2024

Conversation

trocher
Copy link
Contributor

@trocher trocher commented Nov 18, 2024

What I did

  • Bump vvm version.
  • Fix vvm version detection. The regex was too restrictive and would not match for example # @version ^0.3.7 or # pragma version >=0.3.10.
  • Fix Cannot load contract #342

How I did it

Uses vvm version's detector which uses SpecifierSet.

How to verify it

See the updated test that would fail without the new changes.

Description for the changelog

fix vvm version detection

Cute Animal Picture

Put a link to a cute animal picture inside the parenthesis-->

boa/interpret.py Outdated Show resolved Hide resolved
@trocher trocher marked this pull request as draft November 19, 2024 08:54
@trocher
Copy link
Contributor Author

trocher commented Nov 19, 2024

  • fix: relax version detection checks vvm#30 is a blocker for that PR since:
    • it exposes detect_version_specifier_set such that titanoboa can check if the installed vyper version is in the set before calling detect_vyper_version_from_source.
    • it relax vvm version check to allow for versions like >=0.3.10, <0.4.0 or ^0.4.0
  • fix combined_json for versions >0.3.10 vvm#29 is not a blocker but is recommanded as vvm compilation will currently fail for versions >0.3.10.

@charles-cooper
Copy link
Member

  • fix: relax version detection checks vvm#30 is a blocker for that PR since:

    • it exposes detect_version_specifier_set such that titanoboa can check if the installed vyper version is in the set before calling detect_vyper_version_from_source.
    • it relax vvm version check to allow for versions like >=0.3.10, <0.4.0 or ^0.4.0
  • fix combined_json for versions >0.3.10 vvm#29 is not a blocker but is recommanded as vvm compilation will currently fail for versions >0.3.10.

these are merged and part of vvm 0.3.2 release (https://pypi.org/project/vvm/0.3.2/), so i think we can update this PR now

@trocher trocher marked this pull request as ready for review November 21, 2024 23:55
boa/interpret.py Outdated Show resolved Hide resolved
Copy link
Member

@charles-cooper charles-cooper left a comment

Choose a reason for hiding this comment

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

nice work. thanks!

@charles-cooper charles-cooper merged commit 08d4c53 into vyperlang:master Nov 22, 2024
9 checks passed
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.

Cannot load contract
3 participants