[Buildroot] [PATCH v5] support/scripts/pkg-stats: add latest upstream version information

Yann E. MORIN yann.morin.1998 at free.fr
Thu Jan 3 20:38:37 UTC 2019


Brandon, All,

On 2019-01-03 13:57 -0600, Brandon Maier spake thusly:
> This is a useful tool, thanks! I don't have time to test it right now,
> but an observation.
> 
> On Thu, Jan 3, 2019 at 2:38 AM Thomas Petazzoni
> <thomas.petazzoni at bootlin.com> wrote:
> ...
> > +        elif pkg.latest_version[1] == pkg.current_version:
> > +            stats["version-uptodate"] += 1
> ...
> > +    elif pkg.latest_version[1] != pkg.current_version:
> > +        td_class.append("version-needs-update")
> 
> From https://bootlin.com/~thomas/stats.html, there's a few packages
> that are up-to-date, but get marked "version-needs-update" because
> either the Buildroot or release-monitoring version string starts with
> a "v".

There was an issue raised (long ago) about this in the anitya tool
(which generatees the DB at r-m.o):
    https://github.com/release-monitoring/anitya/issues/374

So, the version strings we get from r-m.o should no longer have a
leading 'v' anymore.

Yet, in our FOO_VERSION, we in Buildroot may still have those leading
'v'. So, we should try to compare the versions as-is, and then remove
out leading 'v' and compare again. ot sure of the exact heuristic,
though...

Regards,
Yann E. MORIN.

> For example, the vmtouch and libmodbus packages. It would be
> nice to change the version comparison to ignore a leading "v". E.g.
> 
> def version_uptodate(pkg):
>     latest = remove_prefix(pkg.latest_version[1], 'v')
>     current = remove_prefix(pkg.current_version, 'v')
>     return latest == current
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'


More information about the buildroot mailing list