I need to find a rule to put in requirements.txt for a package x
in order to match any version starting with major 3, even if they are alpha, beta, rc, whatever is the latest.
So for example that rule should match:
3.0.0a3
3.0.0b5
3.0.0rc2
3.0.0
3.0.1
3.1.0b0
3.1.0
...
whatever is the latest.
At the moment, the true latest version of x
is 3.0.0b8.
I tried with: x==3.*
but it doesn't work:
ERROR: Could not find a version that satisfies the requirement x==3.* (from versions: 3.0.0b5, 3.0.0b6, 3.0.0b7, 3.0.0b8)
ERROR: No matching distribution found for x==3.*
I tried to read PEP440 but I couldn't figure that out. Any ideas?
Thanks