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.

Configurable save cache on failure

See original GitHub issue

Currently this cache action will only save caches if all tests succeed. In many cases this is desirable behavior. However I have some projects with long build times and flakey test suites. It would be very helpful if I could configure the cache to be saved regardless of the test suite success or failure.

I have created a fork of this project action to set the post-if to always().

Is it possible to make the cache policy configurable? Or to pass post-if as an argument from the cache configuration?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:163
  • Comments:40 (6 by maintainers)

github_iconTop GitHub Comments

16reactions
Rarstcommented, Sep 14, 2020

Seems like it would make a lot of sense in some circumstances.

Say I have following steps:

  • install dependencies (success)
  • check code style (fail)
  • post cache (skip)

It would make sense if post cache could happen conditionally on success of dependencies install, code style step is irrelevant to it.

15reactions
pat-scommented, Feb 26, 2020

Next fork with latest upstream changes (including the new 5GB cache limit): https://github.com/marketplace/actions/always-upload-cache

Read more comments on GitHub >

github_iconTop Results From Across the Web

Setting for GitLab CI to cache on failure (#56458) · Issues
Having the cache available on failure would allow to pass that file in the same pipeline. We configured the job like this :....
Read more >
Configuration cache - Gradle User Manual
The configuration cache is a feature that significantly improves build performance by caching the result of the configuration phase and reusing this for ......
Read more >
configuration-cache enabled causes build to fail
org.gradle.unsafe.configuration-cache=true. And this is the error that i'm receiving. FAILURE: Build failed with an exception.
Read more >
How caching fails - Section.io
A highly effective website cache is optimised to store and share every possible response that only contains information relevant to all users, ...
Read more >
Configure the client cache - Configuration Manager
If content is in the cache and it's the correct version, the client uses the cached content. When the required version of the...
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