Downgrades are possible in certain scenario's

mdbook was temporarily -2 in the repositories and then downgraded to -1. This should never be allowed by our tooling.

What happened:

Mdbook was updated to -1 in the packages repository, but due to an internet outage the package was not released (but uploaded to the staging directory on repos.archlinux.org). A different packager noticed mdbook was still out of date, bumped the pkgrel to -2 and released the package When the original -1 packagers internet connection was restored they released the package, downgrading the package.

https://gitlab.archlinux.org/archlinux/packaging/state/-/commits/main/extra-x86_64/mdbook https://gitlab.archlinux.org/archlinux/packaging/packages/mdbook/-/commits/main?ref_type=heads

  • Write a unittest for this scenario
  • Check if it's possible to circumvent the downgrade
  • Write some smart code 🍪
Edited by Levente Polyak