{
  "id": 1558349,
  "title": "Your CI is not flaky. It fails every 7 days.",
  "url": "https://urgent.news/2026/08/17/your-ci-is-not-flaky-it-fails-every-7-days",
  "topic": "tech",
  "section": "Tech",
  "published": "2026-08-17T20:28:15.000Z",
  "source": {
    "name": "Dev.to",
    "slug": "dev-to",
    "url": "https://dev.to/heinrichneb/your-ci-is-not-flaky-it-fails-every-7-days-4ljd"
  },
  "original_language": "en",
  "account": "Your continuous integration (CI) pipeline may not be flaky, but it may fail every seven days. Before labeling a test as flaky, it's essential to document the failure dates. A flaky test can be discouraging, often leading to disinterest in further investigation until it fails during a release. To avoid this, examine the gaps between failures instead of assuming the test is flaky.\n\nTo do this, run the command `gh run list --workflow = ci.yml --status = failure --limit 50 --json createdAt --jq .[].createdAt | sort` to list the last 50 failures' creation dates. If the gaps between failures consistently occur on the same number, it suggests a timer-triggered issue, not the test itself. A seven-day cycle is particularly worth noting, as GitHub Actions evicts cache entries untouched for a week. Dependencies that are only restored, not rebuilt, may disappear on a schedule, causing a slow, cold, and sometimes failing test after that.\n\nThis pattern could be due to certificates, tokens, log rotations, or nightly database refreshes, all of which follow a calendar, unlike flaky tests. In one case, the CI pipeline's cache expired every seven days, causing tests to fail due to marginal timeout issues. The fix wasn't to extend the timeout but to ensure the cache was refreshed more frequently. Your CI pipeline might not be flaky; it might just follow a seven-day calendar.",
  "summary": "Quick take Before you label a failing test flaky, write down the dates it failed. Flaky has no rhythm. Yours might. \"Flaky\" is the most expensive word in CI. It closes the investigation. Nobody looks at a flaky test again until it fails on the day of a release. Here is a cheap way to earn the label instead of assuming it. Pull the dates of the last failures and look at the gaps: gh run list…",
  "key_points": [
    "CI pipeline may fail every seven days, not flaky",
    "Examine failure gaps to identify timer-triggered issue",
    "GitHub Actions cache evicts entries after a week"
  ],
  "editors_take": null,
  "illustration": null,
  "coverage": {
    "outlets": 1,
    "also_reported_by": []
  },
  "ai_generated": true,
  "disclaimer": "Summaries, key points and the editor’s take are written by software from other outlets’ reporting and may contain errors — always check the linked original."
}