[INTPAK-77] Make RPM build logic fail cleanly if artifact URL 404s Created: 18/Nov/17  Updated: 29/Jun/18  Resolved: 29/Jun/18

Status: Closed
Project: integration-packaging
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Lowest
Reporter: Daniel Farrell Assignee: Unassigned
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

Some recent problems with ODL infra exposed a poor failure behavior of the RPM build logic. Carbon artifacts were not being published to Nexus, so autorelease was triggering build-rpm job with an artifact URL that didn't actually point at an artifact. The build logic was failing with a misleading error. Should be more clear.

09:24:31 File "/w/workspace/packaging-build-rpm-master/packaging/rpm/build.py", line 365, in <module>
09:24:31 version = extract_version(args.download_url)
09:24:31 File "/w/workspace/packaging-build-rpm-master/packaging/rpm/build.py", line 82, in extract_version
09:24:31 date = datetime.datetime.strptime(odl_date, "%d %b %Y").strftime(
09:24:31 File "/usr/lib64/python2.7/_strptime.py", line 325, in _strptime
09:24:31 (data_string, format))
09:24:31 ValueError: time data '' does not match format '%d %b %Y'

Imported from Trello



 Comments   
Comment by Daniel Farrell [ 29/Jun/18 ]

This is done here: https://git.opendaylight.org/gerrit/gitweb?p=releng/builder.git;a=blob;f=jjb/packaging/build-rpm.sh;h=4f2f0d620454fd371cd861a8d51c5675f39d1530;hb=refs/heads/master#l17

Generated at Wed Feb 07 20:03:32 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.