JuliaRegistries / Registrator.jl

Julia package registration bot
https://julialang.org/packages
Other
210 stars 47 forks source link

Intentional version skip #426

Open cossio opened 9 months ago

cossio commented 9 months ago

Sometimes I want to register a package in General that skips a version, but Automerge will complain about this. In those cases, to avoid having to ping people to manually merge the registration PR, it would be nice if we could do something like:

@JuliaRegistrator register versionskip=true

so that it is clear that the version skip is intentional. I'm not sure if it's possible for Registrator.jl to communicate somehow with the rules in RegistryCI to tell it to bypass this particular check?

(Ups, seems the JuliaRegistrator call above actually called the bot, sorry about that)

JuliaRegistrator commented 9 months ago

Error while trying to register: Register Failed @cossio, it looks like you are not a publicly listed member/owner in the parent organization (JuliaRegistries). If you are a member/owner, you will need to change your membership to public. See GitHub Help

cossio commented 9 months ago

An alternative idea is to let RegistryCI recognize a comment containing [versionskip] (or something similar) in the registration PR to let it bypass the version skip check and auto merge anyway. Not sure which would be preferable.

ericphanson commented 9 months ago

Currently, Registrator.jl passes information to RegistryCI.jl via the PR text. For example, here is where it parses the PR body to find the commit that is being registered. So one option is to:

  1. Update Registrator.jl to add a new line to the PR text it registers with something like * The PR author is intentionally allowing skipped versions when versionskip=true is passed. This requires the comment-bot to understand that argument and pass it all the way through to where it creates the PR.
  2. Update RegistryCI.jl to add an extra boolean here to keep track of that versionskip state, and to look for that line in the PR text and then update the state accordinly. Then pass the information through to this line to enable the guideline conditionally on that variable.