runbot/forwardport
Xavier Morel b45ecf08f9 [IMP] forwardport: handling of missing magic refs
Github can fail to create the magic refs on PRs
(`pull/refs/?/head`). Since forwardport relies on these refs to fetch
PR content this is an issue when it occurs, as the forward ports fail
in a loop.

After discussion with Github support, it turns out Github enabled
`allowReachableSHA1InWant` a while back, meaning it's possible to
fetch content by commit (rather than ref) as long as the content is
"in network".

Use this property as fallback when checking if we can see the PR head
before forward porting.

Also:

- remove explicit configuration of GC during fetch, it doesn't disable
  the autogc (yet?) but that's likely going to happen anyway
- update logging and logger hierarchy during forward port to make
  things clearer and easier to extract, although based on PR id rather
  than number
- rate limit failing forward ports to avoid running them on every cron
  (~ every minute), run them every ~30mn instead, this provides higher
  odds of recovery with less log garbage in case of transient github
  failure, and if the PR is stuck it limits the log pollution

Fixes #658
2022-12-01 10:57:32 +01:00
..
changelog [IMP] forwardport: flag detached PRs in their dashboard 2022-06-30 15:07:49 +02:00
data [FIX] runbot_merge: also show banners on PR pages 2022-08-05 15:35:51 +02:00
migrations/13.0.1.1 [IMP] forwardport: reliability of PR reminders 2020-05-26 15:56:36 +02:00
models [IMP] forwardport: handling of missing magic refs 2022-12-01 10:57:32 +01:00
tests [IMP] forwardport: handling of missing magic refs 2022-12-01 10:57:32 +01:00
__init__.py [ADD] mergebot, forwardbot: changelog 2021-10-20 15:16:48 +02:00
__manifest__.py [IMP] mergebot, forwardbot: various UI bits 2022-06-30 15:07:49 +02:00
controllers.py [ADD] mergebot, forwardbot: changelog 2021-10-20 15:16:48 +02:00