Opened 4 years ago

Closed 4 years ago

#61703 closed defect (invalid)

livecheck sees older version without v prefix as newer than version with v prefix and higher version number

Reported by: Tatsh (Andrew Udvare) Owned by:
Priority: Normal Milestone:
Component: base Version: 2.6.4
Keywords: Cc: tobypeterson, ryandesign (Ryan Carsten Schmidt), raimue (Rainer Müller), jmroot (Joshua Root)
Port:

Description

The project aws-iam-authenticator unfortunately tagged inconsistently so now their newest tags have a v prefix but their older ones do not. It causes the vercmp to see their longest length non-prefixed version as the newest version, rather than the version with the v and that is also a higher number.

https://github.com/kubernetes-sigs/aws-iam-authenticator/tags

Debug output:

DEBUG: Port (livecheck) version is v0.5.2
DEBUG: Fetching https://github.com/kubernetes-sigs/aws-iam-authenticator/tags
DEBUG: Using CURL options "--append-http-header" "Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"
DEBUG: The regex is "archive/([^"]+)\.tar\.gz"
DEBUG: The regex matched "archive/v0.5.2.tar.gz", extracted "v0.5.2"
DEBUG: The regex matched "archive/v0.5.1.tar.gz", extracted "v0.5.1"
DEBUG: The regex matched "archive/v0.5.1-alpha.1.tar.gz", extracted "v0.5.1-alpha.1"
DEBUG: The regex matched "archive/v0.5.0.tar.gz", extracted "v0.5.0"
DEBUG: The regex matched "archive/v0.4.0.tar.gz", extracted "v0.4.0"
DEBUG: The regex matched "archive/0.4.0-alpha.3.tar.gz", extracted "0.4.0-alpha.3"
DEBUG: The regex matched "archive/0.4.0-alpha.1.tar.gz", extracted "0.4.0-alpha.1"
DEBUG: The regex matched "archive/0.4.0-alpha.tar.gz", extracted "0.4.0-alpha"
DEBUG: The regex matched "archive/v0.3.0.tar.gz", extracted "v0.3.0"
DEBUG: The regex matched "archive/v0.2.0-pre.tar.gz", extracted "v0.2.0-pre"
aws-iam-authenticator seems to have been updated (port version: v0.5.2, new version: 0.4.0-alpha.3)

v0.5.2 should be seen as the newest. Can vercmp ignore the missing v in either version?

Portfile is here: https://github.com/Tatsh/ports/blob/master/security/aws-iam-authenticator/Portfile

Change History (5)

comment:1 Changed 4 years ago by Tatsh (Andrew Udvare)

Component: portsbase
Keywords: version livecheck added
Version: 2.6.4

comment:2 Changed 4 years ago by mf2k (Frank Schima)

Keywords: version livecheck removed

comment:3 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)

Per the comment at the top of the golang-1.0.tcl portgroup file the correct way to invoke go.setup to do what you want is:

go.setup            github.com/kubernetes-sigs/aws-iam-authenticator 0.5.2 v

This matches how the github.setup procedure of the github-1.0.tcl portgroup works, which makes sense since go.setup calls github.setup for GitHub-hosted projects.

comment:4 Changed 4 years ago by Tatsh (Andrew Udvare)

Thanks. That fixes it.

comment:5 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: invalid
Status: newclosed
Note: See TracTickets for help on using tickets.