24 / 48 · 16 CI/CD Pipelines · Artifact Management← prev⊞ allnext →☰ Read as one page
4.6Anti-Patterns in Artifact Management
| Anti-Pattern | Problem | Fix |
|---|---|---|
| No artifacts collected | Failures require re-running the pipeline to debug | Always upload reports, screenshots, and logs |
| Artifacts only on success | You only need debugging artifacts when things fail | Use if: failure() or if: always() |
| No retention policy | Storage costs grow unbounded | Set retention days per artifact type |
| Generic artifact names | Cannot tell which browser or shard failed | Include matrix variables in artifact names |
| Uploading everything always | Wastes storage on passing runs | Upload traces/screenshots only on failure |