Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes for diegorusso-aarch64-bigmem #553

Merged
merged 2 commits into from
Nov 6, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions master/master.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ from functools import partial
from buildbot.plugins import reporters, schedulers, util
from buildbot import locks
from twisted.python import log
from twisted.internet import defer

import sentry_sdk
from sentry_sdk.integrations.sqlalchemy import SqlalchemyIntegration
Expand Down Expand Up @@ -204,19 +205,20 @@ def get_delay(now, end):
# Avoid a build to be started between start and end time and delay such build
# at end time
def no_builds_between(start, end):
now = datetime.now().time()
start = datetime.strptime(start, "%H:%M").time()
end = datetime.strptime(end, "%H:%M").time()
def f(builder, requests):
now = datetime.now().time()
if is_within_time_range(now, start, end):
delay = get_delay(now, end)
# Schedule the build later
deferred = defer.Deferred()
builder.master.reactor.callLater(
int(delay),
builder.buildset_manager.submitBuildSet,
deferred.callback,
requests[0],
)
return None
return deferred
# Schedule the build now
return requests[0]
return f
Expand Down
Loading