-
-
Notifications
You must be signed in to change notification settings - Fork 258
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
Rework how we determine coordinate formats #1311
base: master
Are you sure you want to change the base?
Conversation
53fecb3
to
c3e59d2
Compare
The assumption that versions begin with numbers is fatally flawed in reality. Fortunately, where we're trying to disambiguate, most of the time, it's safe to assume that people mean a version number rather than some other format.
c3e59d2
to
20434ab
Compare
Can you add a regression tests that cover one of the artifacts used in the issue?
|
def _unusual_version_format_impl(ctx): | ||
env = unittest.begin(ctx) | ||
|
||
unpacked = unpack_coordinates("group:artifact:FY21R16") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we also add a test for a version that doesn't have any numbers?
|
||
# We add "pom" into SUPPORTED_PACKAGING_TYPES here because "pom" is not a | ||
# packaging type that Coursier CLI accepts. | ||
if unpacked.get("packaging", None) in SUPPORTED_PACKAGING_TYPES + ["pom"]: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TODO for another PR: It looks like SUPPORTED_PACKAGING_TYPES
contains "pom" so probably not necessary to add it again here?
The assumption that versions begin with numbers is fatally flawed in reality. Fortunately, where we're trying to disambiguate, most of the time, it's safe to assume that people mean a version number rather than some other format.
Closes #1290