Project

General

Profile

Actions

action #179314

open

coordination #154777: [saga][epic] Shareable os-autoinst and test distribution plugins

coordination #162131: [epic] future version control related features in openQA

Improve git conflict handling in save_needle size:M

Added by okurz 14 days ago. Updated about 8 hours ago.

Status:
Workable
Priority:
Low
Assignee:
-
Category:
Feature requests
Target version:
Start date:
2025-03-20
Due date:
% Done:

0%

Estimated time:

Description

Observation

We got an email report about too many failed minion jobs:
https://openqa.opensuse.org/minion/jobs?state=failed

One failed job: https://openqa.opensuse.org/minion/jobs?id=5038421 showing

created: 2025-03-20T14:38:07.148564Z
...
result:
  error: |-
    <strong>Failed to save ibus_test_kr-ibus-korean-switch-hangul-20250319.</strong><br><pre>Unable to push Git commit (/var/lib/openqa/share/tests/opensuse/products/opensuse/needles): To github.com:os-autoinst/os-autoinst-needles-opensuse.git
     ! [rejected]            master -> master (fetch first)
    error: failed to push some refs to 'github.com:os-autoinst/os-autoinst-needles-opensuse.git'
    hint: Updates were rejected because the remote contains work that you do not
    hint: have locally. This is usually caused by another repository pushing to
    hint: the same ref. If you want to integrate the remote changes, use
    hint: 'git pull' before pushing again.
    hint: See the 'Note about fast-forwards' in 'git push --help' for details.</pre>

There were 5 failed jobs like this around the same time: https://openqa.opensuse.org/minion/jobs?task=save_needle&state=failed&queue=¬e=

At some point the user was able to save the needle.

The problem is that update_remote and update_branch are not enabled on o3, so it can happen that a push to the needles repo happened while someone else is trying to save a new needle.
Only when those two configuration options are enabled the code will try to rebase on the upstream master.
But another problem is that update_branch needs a branch name, and that might not be the same for all repos (e.g. it's main for os-autoinst-distri-example).

Acceptance Criteria

  • AC1: The user of the openQA webUI needle editor is less likely to see an error about failed git push, e.g. on two users conflicting
  • AC2: In the general case of unrecovered git errors the error detail is still shown to users

Suggestions

Actions

Also available in: Atom PDF