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

[Error] Parsing solidity version in a range #2

Closed
thanhtoantnt opened this issue Mar 14, 2023 · 6 comments
Closed

[Error] Parsing solidity version in a range #2

thanhtoantnt opened this issue Mar 14, 2023 · 6 comments

Comments

@thanhtoantnt
Copy link

  • Example: pragma solidity >=0.4.21 < 0.6.0;
  • Error: ValueError: Invalid NPM block in '>=0.4.21 < 0.6.0': '<'
@taquangtrung
Copy link
Owner

taquangtrung commented Mar 14, 2023

It's a bug of python-semanticversion.

It doesn't allow whitespace between < and 0.6.0.

@thanhtoantnt: can you fix the bug on the benchmark first?

We can fix on solc-detect or raise an issue to node-semver later.

@thanhtoantnt
Copy link
Author

@taquangtrung you mean to change the pragma in the test case if it has the solidity version like this?

@taquangtrung
Copy link
Owner

Yes, we can temporarily fix the benchmark to: pragma solidity >=0.4.21 <0.6.0;

This is an incompatibility between the semantic versioning of Solc and Nodejs.

@taquangtrung
Copy link
Owner

The issue with whitespace was discussed here: rbarrois/python-semanticversion#127

But it seems the author's response is slow.

@taquangtrung
Copy link
Owner

@thanhtoantnt: you shouldn't close this issue, since we haven't fixed it in this repo.

@taquangtrung
Copy link
Owner

Anyway, I just fixed it in this commit: e74324b

So now it can be closed

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

No branches or pull requests

2 participants