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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: allow skip cancel if named job in progress #107

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

mrbrannan
Copy link

馃憢

I have a use case where if a named job is currently running the workflow should not be cancelled (deploying to S3). I figured I would create a PR in case anyone else sees value in the functionality.

Also open to any input, first PR for a github action.

Awesome work btw!

@mikehardy
Copy link
Contributor

This is not a democracy really, but I do want to register in this as well - this happens to me in one repo with one specific job and right now I'm just careful with what I run at the same time :-)

@styfle
Copy link
Owner

styfle commented Aug 23, 2021

Thanks for the PR!

If this gets a few upvotes and others want it, we can merge it.

I'll review soon 馃憤

@ghost
Copy link

ghost commented Nov 4, 2021

This would be really great to have!

Repository owner deleted a comment Nov 9, 2021
workflow_run_id: id,
jobs: jobs.filter(
({ status, name }: any) =>
status === 'in_progress' && disqualifying_jobs.includes(name),
Copy link
Owner

Choose a reason for hiding this comment

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

Should we use Job ID instead of Job Name? Or at least make both work like we do for workflow name/id?

: []
).filter(workflow => workflow.jobs.length > 0);

let workflow_runs_to_cancel = [...workflow_runs];
Copy link
Owner

Choose a reason for hiding this comment

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

Why is this cloned?

@HackToHell
Copy link

This would be amazing to have, I was looking to implement exactly this.

@styfle styfle changed the title Allow users to skip cancellation if named job in progress. feat: allow skip cancel if named job in progress Oct 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants