Closed joepvd closed 6 years ago
This is based on a query in job-board-production
db:
https://travisci.slack.com/archives/C0305BDHP/p1512667227000556
This was an error I made, I didn't add osx_image=xcode8.3
while setting xcode8.3 as the new default on 28 November.
Here was the curl invocation actually used (noticed missing osx_image=
tag:
curl -s -u carmen:$(heroku config:get -a job-board-production AUTH_TOKENS | awk -F: '{ print $1 }') -X PUT "https://job-board-staging.herokuapp.com/images?infra=jupiterbrain&name=travis-ci-macos10.12-xcode8.3-1507738863&is_default=true&tags=os:osx"
And I didn't spot the missing tag in the query to verify, I only looked for the is_default=
tag.
curl -s -u guest:guest GET "https://job-board-production.herokuapp.com/images?infra=jupiterbrain&is_default=true&tags=os:osx&limit=2" |jq
{
"data": [
{
"id": 5600,
"infra": "jupiterbrain",
"name": "travis-ci-macos10.12-xcode8.3-1507738863",
"tags": {
"os": "osx"
},
"is_default": true,
"created_at": "2017-11-02 16:14:35 +0000",
"updated_at": "2017-11-29 01:06:26 +0000"
}
],
"meta": {
"limit": 2
}
}
Ok,
Was able to add osx_image tags through production admin /images
job-board-production::DATABASE=> select * from job_board.images where infra = 'jupiterbrain' order by updated_at desc;
id | infra | name | tags | is_default | created_at | updated_at
------+--------------+------------------------------------------+--------------------------------------+------------+----------------------------+----------------------------
5600 | jupiterbrain | travis-ci-macos10.12-xcode8.3-1507738863 | "os"=>"osx", "os_image"=>"xcode8.3" | t | 2017-11-02 16:14:35.40569 | 2017-12-08 14:32:08.610319
5835 | jupiterbrain | travis-ci-macos10.12-xcode9.2-1512491837 | "os"=>"osx", "osx_image"=>"xcode9.2" | f | 2017-12-06 18:39:50.833606 | 2017-12-06 18:39:50.833606
3214 | jupiterbrain | travis-ci-osx10.11-xcode7.3-1480691248 | "os"=>"osx", "osx_image"=>"xcode7.3" | f | 2016-12-02 16:28:02.256675 | 2017-11-29 13:37:11.783144
5638 | jupiterbrain | travis-ci-macos10.12-xcode9.1-1509557921 | "os"=>"osx", "osx_image"=>"xcode9.1" | f | 2017-11-09 19:50:42.29115 | 2017-11-09 19:50:42.29115
5472 | jupiterbrain | travis-ci-macos10.12-xcode9-1505843868 | "os"=>"osx", "osx_image"=>"xcode9" | f | 2017-09-20 00:36:47.882573 | 2017-09-20 00:36:47.882573
3057 | jupiterbrain | travis-ci-osx10.11-xcode8-1479248015 | "os"=>"osx", "osx_image"=>"xcode8" | f | 2016-11-17 20:39:59.258281 | 2016-11-17 20:39:59.258281
3056 | jupiterbrain | travis-ci-osx10.10-xcode6.4-1479248236 | "os"=>"osx", "osx_image"=>"xcode6.4" | f | 2016-11-17 20:39:17.578655 | 2016-11-17 20:39:17.578655
(7 rows)
As discussed with @joepvd, we can add a fail mode when osx_image
tag isn't present. Otherwise, closing out.
For the
jupiterbrain
infra, there is currently not a tag forxcode8.3
. This is not a current issue, as the imagetravis-ci-macos10.12-xcode8.3-1507738863
is the default, and settingxcode8.3
in.travis.yml
will select this anyway.This will, however, create a problem when the default is changed.
Data correction looks easy, yet there seems to be a systemic cause.