-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
[ci][postmerge/3] actually trigger gap builds #44660
Conversation
self.buildkite_organization, | ||
self.buildkite_pipeline, | ||
build["number"], | ||
build["jobs"][0]["id"], # first job is the blocked job |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is it possible to check some thing that is more reliable? like the label or the step?
unblock a step with a special label |
@@ -29,7 +30,7 @@ def __init__( | |||
self.repo_checkout = repo_checkout | |||
self.days_ago = days_ago | |||
|
|||
def run(self) -> List[str]: | |||
def run(self) -> List[Optional[str]]: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why is this returning a list of optional string?
can we just convert None
to empty string and drop the Optional
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let me change it to a commit --> build_id; the build_id can be optional in case the build for that commit somehow doesn't exist
pass | ||
def _find_blocked_build_and_job( | ||
self, commit: str | ||
) -> Tuple[Optional[Dict], Optional[Dict]]: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could you add a comment on what the return values are? or maybe create a simple class/TypedDict for the return value?
why is the build number a dict? and job id a dict too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah this should be str not dict; i keep changing the content of this function
@@ -29,14 +30,14 @@ def __init__( | |||
self.repo_checkout = repo_checkout | |||
self.days_ago = days_ago | |||
|
|||
def run(self) -> List[str]: | |||
def run(self) -> Dict[str, Optional[str]]: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
update the doc comment?
if not build or not job: | ||
return None | ||
|
||
self.buildkite.jobs().unblock_job( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is always returning None
?
Signed-off-by: can <[email protected]>
Signed-off-by: can <[email protected]>
Signed-off-by: can <[email protected]>
Implement the function to trigger a blocked build on postmerge
Test: