mozilla-services / mozilla-services/updatebot

Handled when Try is Closed

Open
#398 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Enhancement Medium
Dominant language
Python
Stars
9
Forks
8
PR merge metrics
No merged PRs in 30d

Description

CompletedProcess(args=['./mach', 'try', 'auto', '--push-to-vcs'], returncode=1, stdout=b'Creating temporary commit for remote...\nA try_task_config.json\npushing to ssh://hg.mozilla.org/try\nsearching for changes\nremote: adding changesets\nremote: adding manifests\nremote: adding file changes\nremote: \nremote: \nremote: ************************** ERROR ****************************\nremote: try is CLOSED! Reason: Windows OOM\nremote: To push despite the closed tree, include "CLOSED TREE" in your push comment\nremote: *************************************************************\nremote: \nremote: \nremote: transaction abort!\nremote: rollback completed\ntemporary commit removed, repository restored\nError running mach:\n\n    mach try auto --push-to-vcs\n\nThe error occurred in code that was called by the mach command. This is either\na bug in the called code itself or in the way that mach is calling it.\nYou can invoke ``./mach busted`` to check if this issue is already on file. If it\nisn\'t, please use ``./mach busted file try`` to report it. If ``./mach busted`` is\nmisbehaving, you can also inspect the dependencies of bug 1543241.\n\nIf filing a bug, please include the full output of mach, including this error\nmessage.\n\nThe details of the failure are as follows:\n\nsubprocess.CalledProcessError: Command \'(\'/usr/bin/hg\', \'push-to-try\', \'-m\', \'Tasks automatically selected.\\n\\nmach try command: `./mach try auto --push-to-vcs`\\n\\nPushed via `mach try auto`\')\' returned non-zero exit status 255.\n\n  File "/builds/worker/checkouts/gecko/tools/tryselect/mach_commands.py", line 366, in try_auto\n    return run(command_context, **kwargs)\n           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File "/builds/worker/checkouts/gecko/tools/tryselect/mach_commands.py", line 173, in run\n    return mod.run(**kwargs)\n           ^^^^^^^^^^^^^^^^^\n  File "/builds/worker/checkouts/gecko/tools/tryselect/selectors/auto.py", line 108, in run\n    return push_to_try(\n           ^^^^^^^^^^^^\n  File "/builds/worker/che...

The easy fix is to just not error and leave a comment saying we couldn't submit to try because it was closed. The harder fix is to change the state machine so it tries submitting to try at a later time. That change might be made even larger to handle various external services being down (Bugzilla, Try, Treeherder...)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with tools/tryselect/mach_commands.py at try_auto, then follow the stack trace through selectors/auto.py and push_to_try. Reproduce the closed-Try response and define completion as handling that response without an unhandled command error, while preserving the reported outcome to the user.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
ci-cd, devops
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.