Skip to content

v3.6.17

Latest

Choose a tag to compare

@dvershinin dvershinin released this 12 Aug 06:45
12a8932

Fixes RPM spec auto-bumps that were silently failing.

Every lastversion <file>.spec update against a spec genuinely behind upstream died with:

TypeError: '<' not supported between instances of 'str' and 'Version'

That is the only case the auto-bump exists for, so packaging cron chains failed on exactly the releases they were meant to catch. An already-current spec took the "nothing to do" branch and looked healthy, which hid it.

Root cause: current_version is read off the spec's Version: tag — the state of the file on disk — but it was stored in, and served back from, the release cache. The cache round-trips through JSON, so a cache hit returned a plain str while version was a Version.

Fixed:

  • Local project metadata is now parsed before the cache lookup and re-applied over a cache hit, mirroring the fetch path. This also fixes staleness: a cache entry written when the spec said 6.0.16 no longer dictates current_version after the spec moves on.
  • update_spec() coerces current_version and version to Version before comparing, as defence in depth.