Skip to content

Conversation

@potiuk
Copy link
Member

@potiuk potiuk commented Jun 8, 2023

After #31451 there were cases where re-running failed builds by committers without rebasing the PR could have caused that the runs were scheduled on self-hosted runners, but the runner rejected the build because it came from non-trusted actor.

This PR brings back the calculation of runs-on based on PR user login rather than on the actor of the build.


^ Add meaningful description above

Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in newsfragments.

@potiuk potiuk requested review from ashb and jedcunningham as code owners June 8, 2023 13:02
@potiuk potiuk force-pushed the fix-rerunning-failed-jobs-by-committers branch from 7b1e2a0 to a8ec922 Compare June 8, 2023 13:05
@potiuk potiuk force-pushed the fix-rerunning-failed-jobs-by-committers branch from a8ec922 to 80c02ce Compare June 8, 2023 13:15
@potiuk
Copy link
Member Author

potiuk commented Jun 8, 2023

cc: @o-nikolas and others - that should fix the situation when you are "just" rerunning someone's job without rebasing and it fails immediately. The #31451 changed the decision to run on to use "actor" which was incompatible with runner check.

This caused - for example - attempts to re-run the jobs fail in #30637

@potiuk
Copy link
Member Author

potiuk commented Jun 8, 2023

This also caused attempts to re-run fail in https://github.com/apache/airflow/pull/30367/checks @uranusjr

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
f"[warning]The {actor} retrieved as actor from GITHUB_CONTEXT's"
f"[info]{actor} retrieved as actor from GITHUB_CONTEXT's"

2 things:

  • Don't need "the" here, even if "The potiuk retrieved as actor" does sounds good :)
  • Shouldn't this be an info, not warning?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Warning is better. The colors to show are specifically designed to be easily distinguishable.

image

  • Don't need "the" here, even if "The potiuk retrieved as actor" does sounds good :)

I wanted to start the sentence capitalized.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I changed it to:

                        f"[warning]The actor: {actor} retrieved from GITHUB_CONTEXT's"

After apache#31451 there were cases where re-running failed builds by
committers without rebasing the PR could have caused that the
runs were scheduled on self-hosted runners, but the runner
rejected the build because it came from non-trusted actor.

This PR brings back the calculation of runs-on based on PR user
login rather than on the actor of the build.
@potiuk potiuk force-pushed the fix-rerunning-failed-jobs-by-committers branch from 80c02ce to 8508dc8 Compare June 8, 2023 17:10
@potiuk potiuk merged commit a0c58cb into apache:main Jun 8, 2023
@potiuk potiuk deleted the fix-rerunning-failed-jobs-by-committers branch June 8, 2023 17:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants