question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Skip if there are newer runs

See original GitHub issue

I have a quite huge integration test suit and would like to cancel it if at least one newer run is scheduled/in progress.

Is something like this possible?

jobs:
  skip_individual_steps_job:
    runs-on: ubuntu-latest
    steps:
      - id: skip_check
        uses: fkirc/skip-duplicate-actions@master
        with:
          cancel_others: 'false'
          concurrent_skipping: 'newer_runs' # <-- a value that makes concurrent skip functionality works only if newer runs exist
      - if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
        run: |
          echo "Run long test suit" & sleep 60

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:10 (9 by maintainers)

github_iconTop GitHub Comments

1reaction
fkirccommented, Feb 24, 2021

To be honest, I am not entirely sure how to solve it because I never combined those two features together. If you look at the checks in https://github.com/fkirc/skip-duplicate-actions/blob/b68a254ac00b33f707866bae1ebe647e56363d1a/src/index.ts#L144, you might figure out a solution.

1reaction
fkirccommented, Feb 24, 2021

If you are using the same_contentoption, then you might need to add the option do_not_skip: ["push", "workflow_dispatch", "schedule"] or something similar. Otherwise, it might happen that both PR and PUSH are skipped.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Is it possible to skip a new scheduled flow run if a previous ...
Imagine that you have a workflow scheduled to run hourly. But sometimes this flow may take longer than an hour and you want...
Read more >
C++ - Skipping code after first run-through? - Stack Overflow
On the first run, it executes fine. The problem however is when it runs through the code again after the user enters 'r'...
Read more >
Build Azure Repos Git repositories - Azure Pipelines
The pipelines triggered by changes to the PR's source branch, if there are no pushed commits whose messages or descriptions contain [skip ci]...
Read more >
Mocha - the fun, simple, flexible JavaScript test framework
skip ('should return -1 unless present', function () { // this test will not be run }); it('should return the index when present',...
Read more >
How to run a Skip Test in Robot Framework - Neova Solutions
Sometimes skipping tests can play a crucial role in saving time. When there are certain types of errors in the given test case,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found