Test rail report fails on attemts to find version,yaml in artifacts of jobs

Bug #1536628 reported by Tatyanka
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Released
High
Artem Panchenko
8.0.x
Invalid
Undecided
Unassigned

Bug Description

Verion.yaml was removed (in 9.0) https://review.openstack.org/#/c/259029/
https://review.openstack.org/#/c/261968/
https://review.openstack.org/#/c/258994/
So test rail report start to fail with 404 error

liberty.all/116/api/json?depth=0
2016-01-21 10:01:24,852 - DEBUG - Request artifact content from https://product-ci.infra.mirantis.net/job/9.0-liberty.all/116//artifact/version.yaml.txt
Traceback (most recent call last):
  File "fuelweb_test/testrail/report.py", line 704, in <module>
    main()
  File "fuelweb_test/testrail/report.py", line 614, in main
    milestone, iso_number, prefix = get_version(runner_build.build_data)
  File "fuelweb_test/testrail/report.py", line 134, in get_version
    return get_version_from_parameters(jenkins_build_data)
  File "fuelweb_test/testrail/report.py", line 165, in get_version_from_parameters
    return get_version_from_artifacts(upstream_build.build_data)
  File "fuelweb_test/testrail/report.py", line 178, in get_version_from_artifacts
    url=jenkins_build_data['url'], artifact=JENKINS['version_artifact']))
  File "/home/jenkins/workspace/9.0-liberty.testrail_reports/fuelweb_test/testrail/builds.py", line 71, in get_build_artifact
    s = opener.open(req).read()
  File "/usr/lib/python2.7/urllib2.py", line 410, in open
    response = meth(req, response)
  File "/usr/lib/python2.7/urllib2.py", line 523, in http_response
    'http', request, response, code, msg, hdrs)
  File "/usr/lib/python2.7/urllib2.py", line 448, in error
    return self._call_chain(*args)
  File "/usr/lib/python2.7/urllib2.py", line 382, in _call_chain
    result = func(*args)
  File "/usr/lib/python2.7/urllib2.py", line 531, in http_error_default
    raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
urllib2.HTTPError: HTTP Error 404: Not Found
Build step 'Execute shell' marked build as failure
[description-setter] Description set:
Finished: FAILURE

Tags: area-qa
Maciej Relewicz (rlu)
Changed in fuel:
status: New → Confirmed
Changed in fuel:
assignee: Fuel QA Team (fuel-qa) → Artem Panchenko (apanchenko-8)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-qa (master)

Fix proposed to branch: master
Review: https://review.openstack.org/270848

Changed in fuel:
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-qa (master)

Reviewed: https://review.openstack.org/270848
Committed: https://git.openstack.org/cgit/openstack/fuel-qa/commit/?id=f4ca926c21d879d01239006ad7e0d238ecefc3b0
Submitter: Jenkins
Branch: master

commit f4ca926c21d879d01239006ad7e0d238ecefc3b0
Author: Artem Panchenko <email address hidden>
Date: Thu Jan 21 16:56:05 2016 +0200

    Change job artifact for getting iso version

    In Fuel 9.0 there is no version.yaml.txt build artifact
    anymore. Modified reporter to use another artifact
    'magnet_link.txt', which contains iso file name. Parse
    iso name if order to get its version.

    Also refactored 'get_version' and related methods a bit,
    so version fetching algorithm look more obvious.

    Change-Id: I7964de1dba83bf810815f6e0ed00c726aa1d97ad
    Closes-bug: #1536628

Changed in fuel:
status: In Progress → Fix Committed
Revision history for this message
Artem Panchenko (apanchenko-8) wrote :

TestRail reporter works fine for 9.0 jobs:

+ python fuelweb_test/testrail/report.py -v -l -j 9.0.swarm.runner
2016-02-08 08:31:27,366 - INFO - Initializing TestRail Project configuration...
2016-02-08 08:31:29,650 - INFO - Getting tests results from Jenkins...
2016-02-08 08:31:29,650 - DEBUG - Request job info from https://****//job/9.0.swarm.runner/api/json?depth=0
2016-02-08 08:31:29,690 - DEBUG - Request build data from https://****/job/9.0.swarm.runner/7/api/json?depth=0
...
2016-02-08 08:31:38,250 - INFO - Found existing TestPlan "9.0 liberty iso #182".

Changed in fuel:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.