Project

General

Profile

Bug #20554

workunit task does not fall back to ceph/ceph.git when it should

Added by Nathan Cutler over 1 year ago. Updated 4 months ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
-
Target version:
-
Start date:
07/08/2017
Due date:
% Done:

0%

Source:
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:

Description

Background

In master, there's a workunit.py task which clones the ceph repo to the client machine(s) in order to run "workunits", which are scripts stored under qa/workunits.

The bug

If the user specifies --suite-branch https://github.com/ceph/ceph-ci (i.e. without the ".git" extension), the code path that falls back to ceph/ceph.git when the workunit branch(/tag/ref) is not found in ceph/ceph-ci.git does not trigger (because it only works on repo strings that end in ".git").

How the bug manifests

First, notice that we have set suite_repo to ". . .ceph/ceph-ci" instead of ". . .ceph/ceph-ci.git"

  branch: master
  repo: https://github.com/ceph/ceph
  suite_branch: wip-rados-upgrade-2
  suite_repo: https://github.com/ceph/ceph-ci

The workunit yaml specifies branch jewel:

    - workunit:
        branch: jewel
        clients:
          client.0:
          - cls/test_cls_rbd.sh

The workunit task takes this seriously:

2017-07-08T06:04:09.458 INFO:teuthology.task.sequential:In sequential, running task workunit...
2017-07-08T06:04:09.464 INFO:tasks.workunit:Pulling workunits from ref jewel

And the job fails:

2017-07-08T06:04:09.594 INFO:teuthology.orchestra.run.smithi094:Running: 'rm -rf /home/ubuntu/cephtest/clone.client.0 && git clone --depth 1 --branch jewel https://github.com/ceph/ceph-ci /home/ubuntu/cephtest/clone.client.0 && cd /home/ubuntu/cephtest/clone.client.0'
...
2017-07-08T06:04:10.087 INFO:tasks.workunit.client.0.smithi094.stderr:warning: Could not find remote branch jewel to clone.
2017-07-08T06:04:10.087 INFO:tasks.workunit.client.0.smithi094.stderr:fatal: Remote branch jewel not found in upstream origin
...
CommandFailedError: Command failed on smithi094 with status 128: 'rm -rf /home/ubuntu/cephtest/clone.client.0 && git clone --depth 1 --branch jewel https://github.com/ceph/ceph-ci /home/ubuntu/cephtest/clone.client.0 && cd /home/ubuntu/cephtest/clone.client.0'

How it's supposed to work

When ". . .ceph/ceph-ci.git" is specified, the fallback code path is activated:

2017-07-08T08:16:16.939 INFO:tasks.workunit.client.0.smithi186.stderr:warning: Could not find remote branch jewel to clone.
2017-07-08T08:16:16.939 INFO:tasks.workunit.client.0.smithi186.stderr:fatal: Remote branch jewel not found in upstream origin
2017-07-08T08:16:16.941 INFO:tasks.workunit:failed to check out 'jewel' from git://git.ceph.com/ceph-ci.git; will also try in git://git.ceph.com/ceph.git
2017-07-08T08:16:16.941 INFO:teuthology.orchestra.run.smithi186:Running: 'rm -rf /home/ubuntu/cephtest/clone.client.0 && git clone --depth 1 --branch jewel git://git.ceph.com/ceph.git /home/ubuntu/cephtest/clone.client.0 && cd /home/ubuntu/cephtest/clone.client.0'

We would like it to work this way for "https://github.com/ceph/ceph-ci" as well.

History

#1 Updated by Nathan Cutler over 1 year ago

  • Subject changed from workunit task clones from the wrong branch to workunit task clones from the wrong repo
  • Description updated (diff)

#2 Updated by Nathan Cutler over 1 year ago

  • Description updated (diff)
  • Status changed from New to In Progress

#3 Updated by Nathan Cutler over 1 year ago

  • Description updated (diff)

#4 Updated by Nathan Cutler over 1 year ago

  • Description updated (diff)

#5 Updated by Nathan Cutler over 1 year ago

  • Description updated (diff)

#6 Updated by Nathan Cutler over 1 year ago

  • Subject changed from workunit task clones from the wrong repo to workunit task does not fall back to ceph/ceph.git when it should

#7 Updated by Nathan Cutler over 1 year ago

  • Status changed from In Progress to Need Review

#8 Updated by Nathan Cutler over 1 year ago

  • Description updated (diff)

#9 Updated by Nathan Cutler 4 months ago

  • Status changed from Need Review to Resolved

Also available in: Atom PDF