Move worker downtime configuration to workers.py#701
Open
encukou wants to merge 4 commits intopython:mainfrom
Open
Move worker downtime configuration to workers.py#701encukou wants to merge 4 commits intopython:mainfrom
encukou wants to merge 4 commits intopython:mainfrom
Conversation
The `canStartBuild=no_builds_between(...)` configuration is used for regular maintenance windows (restarts/reprovisions) and quiet periods for benchmark runs. - Rename to `downtime`; canStartBuild & quarantining are implementation details. - Move configuration to workers.py. - Move implementation to new module, worker_downtime.py
zware
approved these changes
Apr 10, 2026
| STABLE, | ||
| ONLY_MAIN_BRANCH, | ||
| ) | ||
| from custom.worker_downtime import no_builds_between |
Member
There was a problem hiding this comment.
Looks like a phantom import?
Suggested change
| from custom.worker_downtime import no_builds_between |
Member
There was a problem hiding this comment.
The ZoneInfo import can also be removed.
vstinner
reviewed
Apr 10, 2026
| # Builds scheduled between 8am - 10am PT on Wednesdays will be delayed to | ||
| # 10am PT. | ||
| itamaro_downtime = no_builds_between( | ||
| "8:00", "10:00", day_of_week=2, tz=ZoneInfo("America/Los_Angeles") |
Member
There was a problem hiding this comment.
You might add WEDNESDAY = 2 to worker_downtime.py for extra clarity.
| STABLE, | ||
| ONLY_MAIN_BRANCH, | ||
| ) | ||
| from custom.worker_downtime import no_builds_between |
Member
There was a problem hiding this comment.
The ZoneInfo import can also be removed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We use
builder.canStartBuildfor scheduled downtime, which is per-worker configuration.Move it out of
master.cfgto the appropriate places:workers.pyworker_downtime.pyThis applies
ambv-bb-win11's maintenance window to the PR builds, for which it was left out in GH-589.