renovate icon indicating copy to clipboard operation
renovate copied to clipboard

feat: support a fallback to an "old" /versions endpoint for registries that only support that

Open narwold opened this issue 2 years ago • 6 comments

Changes

This PR adds a fallback to the rubygems datasource that will hit /versions on any arbitrary registry that 404s on the /api/v1 endpoints. It turns out that this is exactly the logic that was used in RubyGemsOrgDatasource, so that code has been re-used.

One suggestion would be to rename that file to make it more generic, but discussion should be had on the best naming or whether this approach is the best in the first place.

Resolves https://github.com/renovatebot/renovate/issues/16126

Documentation

  • [x] No documentation update is required???

How I've tested my work

I have verified these changes via:

  • [x] Newly added/modified unit tests
  • [x] Both unit tests + ran on a real repository (will try to get this done)

narwold avatar Jun 28 '22 16:06 narwold

CLA assistant check
All committers have signed the CLA.

CLAassistant avatar Sep 02 '22 15:09 CLAassistant

Hi @narwold !

Hope you're fine, would you mind passing this PR in review? Do you need some more help?

Have a good day :)

jdemangeon avatar Sep 06 '22 13:09 jdemangeon

Hi @rarkins

This feature is important and blocking for us. It seems that there is still a test to do on a real repo, is it really necessary? If so how can we do it?

cheers

hugopochart avatar Sep 13 '22 07:09 hugopochart

Of course we will not merge untested code. Development branches can be tested using the processes described here: https://github.com/renovatebot/renovate/blob/main/docs/development/local-development.md

rarkins avatar Sep 13 '22 07:09 rarkins

We just did the test on a repo. We can see that two PRs have been created for the sidekiq-ent and sidekiq-pro gems which come from the registry enterprise.contribsys.com. So @narwold the last checkbox of your PR description can be checked.

@narwold do you need help to apply @rarkins' review?

hugopochart avatar Sep 13 '22 12:09 hugopochart

I'll take a look within the next couple hours. This was a little less urgent for me but still important, so I really appreciate all of you jumping on here.

narwold avatar Sep 13 '22 12:09 narwold

Hi @rarkins ! Hope you're fine

What can we do to help you for review? Have we miss something?

jdemangeon avatar Sep 27 '22 13:09 jdemangeon

@rarkins / anyone else out there 😄 - any other questions I can answer or anything else that can be done to move this forward?

narwold avatar Oct 21 '22 14:10 narwold

@jdemangeon and @hugopochart - I won't have a chance to update this immediately but will get back to it as soon as I can. No obligation by any means, but I will not take offense if you address anything here. I will do my best to get to it this week though.

narwold avatar Oct 31 '22 16:10 narwold