Skip to content

Commit

Permalink
ci: check tc-admin diff retcode (#238)
Browse files Browse the repository at this point in the history
* Require tc-admin 4.0.2

First release with taskcluster/tc-admin#278

* ci: check `tc-admin diff` exit code

Avoid optimizing out all tasks when the diff fails.

---------

Co-authored-by: Ben Hearsum (he/him) <[email protected]>
  • Loading branch information
jcristau and bhearsum authored Jan 6, 2025
1 parent 3fb2555 commit 6adf2a1
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion requirements/base.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
tc-admin>=3.3.1
tc-admin>=4.0.2
taskcluster
attrs # http://www.attrs.org/en/stable/backward-compatibility.html
mozilla-repo-urls
Expand Down
2 changes: 1 addition & 1 deletion requirements/base.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# SHA1:9439d42fa1b173594e393bc7a143ac26cffe5ad6
# SHA1:5428978ea2dc6dc1c4142793053ba03fa77517ad
#
# This file is autogenerated by pip-compile-multi
# To update, run:
Expand Down
3 changes: 3 additions & 0 deletions taskcluster/fxci_config_taskgraph/optimizations.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,12 @@ def _get_modified_worker_pools(self) -> set[str]:
]
env = os.environ.copy()
if "TASKCLUSTER_PROXY_URL" in env:
# Force tc-admin diff to look at fxci even when we're running on stage
del env["TASKCLUSTER_PROXY_URL"]
env["TASKCLUSTER_ROOT_URL"] = FIREFOXCI_ROOT_URL
proc = subprocess.run(cmd, stdout=subprocess.PIPE, text=True, env=env)
if proc.returncode not in (0, 2):
proc.check_returncode()
lines = [line for line in proc.stdout.splitlines() if line.startswith("!")]

worker_pools = set()
Expand Down

0 comments on commit 6adf2a1

Please sign in to comment.