Skip to content
This repository has been archived by the owner on Aug 17, 2024. It is now read-only.

Fixes #53 -- bug due false assumption that a version follows semver. #60

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

sevalsixarci
Copy link

Hi, as title this fix #53

The bug occurs when a package (on GitHub) has a release tag with a name that is not a version number.
You can experience this with the package arturo (https://nimble.directory/pkg/arturo), which has an unexpected tag "v0.9.82-pre2" as you can see in the stack trace [...] invalid integer: 82-pre2.

The fix addresses this issue by disregarding the tag name and instead utilizing the date associated with the tag.

I also point out that since this code only works for Github (as before) it would fit better inside github.nim.

@sevalsixarci
Copy link
Author

Ciao Federico,
I was wondering: your code expects the version as git tag that while (if annoted) has a date - as per my observation and proposed solution - doesn't mean that a newer tag is a newer version so this fix is incorrect.

Also the specific case presented as an example is actually following semver.

So I think we should discard this with another patch that correctly parses the version name. The second patch is based on semver package by @euantorano that I vetted having a stable working API and a compatible license.

Let me know your opinion.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

An error has occured in one of your routes.
1 participant