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

Support timeout-minutes in composite-actions #1979

Open
Flydiverny opened this issue Jun 29, 2022 · 12 comments
Open

Support timeout-minutes in composite-actions #1979

Flydiverny opened this issue Jun 29, 2022 · 12 comments
Labels
enhancement New feature or request Runner Feature Feature scope to the runner

Comments

@Flydiverny
Copy link

Flydiverny commented Jun 29, 2022

Describe the enhancement
We would like to see timeout-minutes supported on steps in composite actions

Code Snippet
If applicable, add a code snippet.

name: terraform-cache

inputs:
  working-directory:
    description: Directory to run terraform in
    required: false
    default: ""

runs:
  using: composite
  steps:
    - name: Cache Terraform
      uses: actions/cache@v3
      timeout-minutes: 2
      with:
        path: ${{ runner.temp }}/.terraform.d/plugin-cache
        key: ${{ runner.os }}-terraform-${{ inputs.working-directory }}-${{ hashFiles('**/.terraform.lock.hcl') }}
        restore-keys: |
          ${{ runner.os }}-terraform-${{ inputs.working-directory }}-
          ${{ runner.os }}-terraform-

Additional information
Occasionally actions like actions/cache bug out (see actions/cache#810 etc) and run for the default timeout time (6 hours) which causes unnecessary costs and extra work as CI will be left running and needs to be aborted and re-run.
With the possibility to set timeout-minutes on steps in composite actions this damage could be limited and have actions finish in a timely manner even if the cache action fails.

I see from previous ADRs 0549 and 1144 that timeout-minutes are to be considered in the future and last mention it was waited with due to little buzz about this feature missing, so heres some buzz 🐝 🙂


NOTE: if the feature request has been agreed upon then the assignee will create an ADR. See docs/adrs/README.md

@Flydiverny Flydiverny added the enhancement New feature or request label Jun 29, 2022
@ghost
Copy link

ghost commented Jun 29, 2022

👋 +1

@PavanMudigondaTR
Copy link

+1000 behalf of all of our Developers and Automation Engineers who need this badly !

@vctqs1
Copy link

vctqs1 commented Oct 27, 2022

+1111

@phungtruongnguyen94
Copy link

+2222

@Recurse-blip
Copy link

Just recently came across this limitation. I hope it will be implemented swiftly.

@fl250144
Copy link

+1

v4hn added a commit to v4hn/ros-deb-builder-action that referenced this issue Jan 18, 2023
@malfet
Copy link

malfet commented Jan 23, 2023

It's weird not to have this option.
And at the very least it should have been documented

@jmdelaney8
Copy link

+1

@asottile-sentry
Copy link

please stop commenting +1, many of us are subscribed to receive updates on this issue

  • if you want to see it happen, click the +1 react on the original issue
  • if you want to be notified about changes to this issue click the [subscribe] button on the right
  • but please please stop commenting +1, some of us are interested in updates to this and not comment spam

bader added a commit to intel/llvm that referenced this issue Feb 15, 2023
Reverts #8287

Apparently composite actions do not support timeout. See
actions/runner#1979.
ideepika pushed a commit to ideepika/rook that referenced this issue Feb 20, 2023
ideepika pushed a commit to ideepika/rook that referenced this issue Feb 20, 2023
ideepika pushed a commit to ideepika/rook that referenced this issue Feb 20, 2023
use timeout for the step in main workflow instead

actions/runner#1979
https://github.com/metabase/metabase/pull/24554/files

once support for timeout-minutes is added we can remove these steps

Signed-off-by: Deepika Upadhyay <[email protected]>
ideepika pushed a commit to ideepika/rook that referenced this issue Feb 20, 2023
use timeout for the step in main workflow instead

actions/runner#1979
https://github.com/metabase/metabase/pull/24554/files

once support for timeout-minutes is added we can remove these steps

Signed-off-by: Deepika Upadhyay <[email protected]>
ideepika pushed a commit to ideepika/rook that referenced this issue Feb 20, 2023
use timeout for the step in main workflow instead

actions/runner#1979
https://github.com/metabase/metabase/pull/24554/files

once support for timeout-minutes is added we can remove these steps

Signed-off-by: Deepika Upadhyay <[email protected]>
ideepika pushed a commit to ideepika/rook that referenced this issue Feb 21, 2023
use timeout for the step in main workflow instead

actions/runner#1979
https://github.com/metabase/metabase/pull/24554/files

once support for timeout-minutes is added we can remove these steps

Signed-off-by: Deepika Upadhyay <[email protected]>
ideepika pushed a commit to ideepika/rook that referenced this issue Feb 21, 2023
use timeout for the step in main workflow instead

actions/runner#1979
https://github.com/metabase/metabase/pull/24554/files

once support for timeout-minutes is added we can remove these steps

Signed-off-by: Deepika Upadhyay <[email protected]>
ideepika pushed a commit to koor-tech/rook that referenced this issue Feb 22, 2023
use timeout for the step in main workflow instead

actions/runner#1979
https://github.com/metabase/metabase/pull/24554/files

once support for timeout-minutes is added we can remove these steps

Signed-off-by: Deepika Upadhyay <[email protected]>
ideepika pushed a commit to koor-tech/rook that referenced this issue Feb 22, 2023
use timeout for the step in main workflow instead

actions/runner#1979
https://github.com/metabase/metabase/pull/24554/files

once support for timeout-minutes is added we can remove these steps

Signed-off-by: Deepika Upadhyay <[email protected]>
Rakshith-R pushed a commit to Rakshith-R/rook that referenced this issue Feb 24, 2023
use timeout for the step in main workflow instead

actions/runner#1979
https://github.com/metabase/metabase/pull/24554/files

once support for timeout-minutes is added we can remove these steps

Signed-off-by: Deepika Upadhyay <[email protected]>
ideepika pushed a commit to koor-tech/koor that referenced this issue Mar 10, 2023
use timeout for the step in main workflow instead

actions/runner#1979
https://github.com/metabase/metabase/pull/24554/files

once support for timeout-minutes is added we can remove these steps

Signed-off-by: Deepika Upadhyay <[email protected]>
ideepika pushed a commit to koor-tech/koor that referenced this issue Jun 1, 2023
use timeout for the step in main workflow instead

actions/runner#1979
https://github.com/metabase/metabase/pull/24554/files

once support for timeout-minutes is added we can remove these steps

Signed-off-by: Deepika Upadhyay <[email protected]>
Copy link
Contributor

This issue is stale because it has been open 365 days with no activity. Remove stale label or comment or this will be closed in 15 days.

@github-actions github-actions bot added the Stale label Feb 12, 2024
@nikaro
Copy link

nikaro commented Feb 12, 2024

not stale, still wanted, hire more people

@github-actions github-actions bot removed the Stale label Feb 19, 2024
@moarpheus
Copy link

Dear GitHub, kind ask to introduce this option into composite actions

det pushed a commit to trunk-io/trunk-action that referenced this issue Jun 25, 2024
There may be times where the trunk action is unresponsive and is hung in
CI.
To understand whether this is a linter or trunk cli issue, we'll need
logs to confirm.

This PR adds the following optional inputs `timeout-seconds` and
`cat-trunk-debug-logs`
which will wrap the trunk check action with the unix `timeout` command
should the user supply an argument for `timeout-seconds`

Should the user specify `cat-trunk-debug-logs: true`, the trunk action
will also cat out cli & daemon logs from `.trunk/logs/`

Unfortunately, `timeout-minutes` doesn't work in `composite-actions` see
actions/runner#1979
and https://github.com/orgs/community/discussions/50481

**Test Plan**:
<details>

<summary>End to End test to ensure timeout + logs work</summary>

<img width="1873" alt="image"
src="https://github.com/trunk-io/trunk-action/assets/31294356/27ca9a1b-fe54-4e73-928e-63625d1f934e">


</details>

<details>

<summary>End to End test to ensure timeout works </summary>

<img width="1878" alt="image"
src="https://github.com/trunk-io/trunk-action/assets/31294356/8fb7351a-11c0-4e83-9490-864c6ecdafc0">



</details>

- [ ] Add Regression test (not entirely sure I can run this workflow)
May need some help here!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Runner Feature Feature scope to the runner
Projects
None yet
Development

No branches or pull requests