New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 697141 link

Starred by 2 users

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Bug

Blocking:
issue 708262



Sign in to add a comment

add an assign_stable_images cronjob to staging master

Project Member Reported by pprabhu@chromium.org, Feb 28 2017

Issue description

See  issue 696837  for an issue caused by this.

We automatically bump stable_versions for all boards in prod periodically. For test_push, the stable versions are used from push_master's AFE database and are not automatically bumped. This sometimes leads to test failures because the stable_version was too old.

We should also bump this automatically.

Perhaps test_push can run assign_stable_versions against the test database just like a cron job does against prod?
 
Cc: shuqianz@chromium.org
Labels: -current-issue Hotlist-Fixit
Blocking: 708262
This cost me no end of pain, and delayed push-to-prod by a week (and counting).
See  issue 708262 
Richard, I didn't find anything in puppet about that cron job of updating stable images in cautotest. Is it not in puppet? How does it work? If I want to add a same cron job in push server, how can I do that?
Cc: jrbarnette@chromium.org
Re #4: You want this script: http://shortn/_irRctGblNX
It's run by the cron: chromeos-admin/puppet/modules/lab/files/autotest_cautotest/lab-management-jobs
You may have to tweak the script.  Part of the code is
based on the lab inventory code, which only counts boards
that have DUTs in both pool:suites and one critical pool
like pool:bvt.

I can give suggestions offline on how to deal with this.

I specifically tested the script with a dry run on the .hot server.
Here's what you get:

chromeos-test@chromeos-autotest:/usr/local/autotest$ site_utils/stable_images/assign_stable_images.py -n gandof quawks
Dry run:  no changes will be made.
Default R58-9334.28.0 -> R58-9334.33.0
Applying stable version changes:
    gandof                 R57-9202.18.0 -> (default)
2 boards now use the default mapping

Applying firmware updates:
    gandof                 (nothing) -> Google_Gandof.6301.155.9
    quawks                 (nothing) -> Google_Quawks.5216.204.61
0 boards have no firmware mapping
0 boards are unchanged

Executive summary:  That'll work, but you have to hard-code the
board names.

Looks like the gandof stable version is pointing at a no-longer-available image, so I'm hitting this again.
chromeos-test@chromeos-staging-master2:/usr/local/autotest$ site_utils/stable_images/assign_stable_images.py -n gandof quawcks
Dry run:  no changes will be made.
Traceback (most recent call last):
  File "site_utils/stable_images/assign_stable_images.py", line 616, in <module>
    main(sys.argv)
  File "site_utils/stable_images/assign_stable_images.py", line 604, in main
    _get_upgrade_versions(afe_versions, omaha_versions, boards))
  File "site_utils/stable_images/assign_stable_images.py", line 431, in _get_upgrade_versions
    afe_default = afe_versions[_DEFAULT_BOARD]
KeyError: 'DEFAULT'

It will be fixed by this CL. There will a cron job to update the stable versions
Fixed ^ with:

$ ./atest stable_version modify -b DEFAULT -i R61-9765.63.0

(but that code should probably fail better)

Now:

chromeos-test@chromeos-staging-master2:/usr/local/autotest$ site_utils/stable_images/assign_stable_images.py -n gandof quawks               
Dry run:  no changes will be made.
Default R61-9765.63.0 -> R61-9765.70.0
Applying stable version changes:
    gandof                 R61-9765.63.0 -> (default)
    quawks                 R61-9765.63.0 -> (default)
2 boards now use the default mapping

Applying firmware updates:
    gandof                 (nothing) -> Google_Gandof.6301.155.9
    quawks                 (nothing) -> Google_Quawks.5216.204.61
0 boards have no firmware mapping
0 boards are unchanged


I'm not sure I actually want to do that without dry run though. Not clear to me what behavior is exlected...
YOLO I did it anyway.

chromeos-test@chromeos-staging-master2:/usr/local/autotest$ site_utils/stable_images/assign_stable_images.py gandof quawks
Default R61-9765.63.0 -> R61-9765.70.0
Applying stable version changes:
    gandof                 R61-9765.63.0 -> (default)
    quawks                 R61-9765.63.0 -> (default)
2 boards now use the default mapping

Applying firmware updates:
    gandof                 (nothing) -> Google_Gandof.6301.155.9
    quawks                 (nothing) -> Google_Quawks.5216.204.61
0 boards have no firmware mapping
0 boards are unchanged


This should be a cronjob.
Summary: add an assign_stable_images cronjob to staging master (was: Automatically bump stable_version for test_push)
Mergedinto: 646068
Status: Duplicate (was: Available)
Owner: akes...@chromium.org
Status: Started (was: Duplicate)
Issue 768882 has been merged into this issue.
Owner: ----
Status: Available (was: Started)
Owner: pprabhu@chromium.org
Status: Started (was: Available)
Owner: ----
Status: Available (was: Started)

Sign in to add a comment