GitHub Actions

Unblocking GitHub Actions: Mastering Artifact Storage for Enhanced Software Developer Productivity

GitHub Actions are indispensable for modern CI/CD, serving as the backbone for countless automated workflows. But nothing grinds software developer productivity to a halt faster than a blocked pipeline. The dreaded "Failed to CreateArtifact: Artifact storage quota has been hit" error is a common, yet profoundly frustrating, roadblock. It prevents new workflow runs from uploading essential build artifacts, effectively pausing development and delivery. This isn't just a technical glitch; it's a direct hit on team velocity and morale.

A recent GitHub Community discussion (Discussion #190225) perfectly illustrates this challenge. A user, CrescentEngg, found their private repository's Actions blocked despite diligently deleting all artifacts via API, confirming a zero artifact count, checking for caches, and waiting over 12 hours. The quota remained stubbornly 'stuck,' preventing new uploads. This scenario is all too familiar for many engineering teams.

Understanding the "Stuck" Quota Phenomenon

The core of the problem often lies not in actual storage usage, but in the asynchronous nature of GitHub's backend recalculations. While the UI or API might show total_count = 0, the underlying storage metrics can take significantly longer to refresh. This delay can span 24-48 hours, far exceeding the stated 6-12 hour window. For teams relying on rapid iterations and continuous delivery, this waiting period is unacceptable.

Immediate Troubleshooting & Expert Advice

When faced with this immediate crisis, the community quickly chimed in with a range of practical solutions and insights, emphasizing that while the error message is clear, the resolution isn't always instant due to backend synchronization delays. Here’s a summary of the key recommendations:

  • Patience, Beyond the Stated: While GitHub states 6-12 hours for recalculation, real-world experience indicates it can sometimes take 24-48 hours for the storage usage to fully refresh on the backend after deletions. If you've just deleted a large volume of artifacts, give it more time than you think.
  • Trigger a Fresh Workflow: Sometimes, a new workflow run can prompt a re-evaluation of storage. Pushing a small, empty commit (git commit --allow-empty -m "trigger workflow" && git push) can initiate this without impacting your codebase.
  • Check Organization-Level Quota: This is a crucial, often overlooked step for teams working within organizations. Even if your specific repository appears clean, an exceeded organization-wide Actions quota can still block uploads across all repos. Navigate to Settings → Billing → Actions to verify.
  • Verify with GitHub API Again: Use the GitHub API (e.g., gh api repos/ORG/REPO/actions/artifacts) to double-check artifact status, ensuring no lingering artifacts are reported.
  • Temporary Workaround: Disable Uploads: For critical workflows that must run even without artifacts, you can temporarily disable the artifact upload step by adding an if: false condition. This allows the workflow to complete, though without storing its outputs:
    - name: Upload Artifact
      if: false
      uses: actions/upload-artifact@v4
      with:
        name: build
        path: dist/
    
  • When to Contact GitHub Support: If, after all these steps and sufficient waiting, the quota remains stuck, it's highly likely a backend synchronization issue on GitHub’s side. At this point, opening a support ticket is the only path forward.
Visual representation of managing GitHub Actions artifact storage: overflowing storage, delayed recalculation, and proactive steps like adjusting retention days and monitoring billing.
Visual representation of managing GitHub Actions artifact storage: overflowing storage, delayed recalculation, and proactive steps like adjusting retention days and monitoring billing.

Proactive Strategies for Sustainable CI/CD

While the above steps address immediate blocks, true software developer productivity comes from preventing these issues altogether. Technical leaders, product managers, and delivery managers should implement proactive strategies:

  • Aggressive Artifact Deletion: Regularly audit and delete old workflow runs and their associated artifacts. Remember, GitHub does not automatically delete artifacts after a workflow run is deleted; they persist until their retention period expires.
  • Optimize Artifact Retention: This is arguably the most impactful proactive measure. Configure retention-days in your upload-artifact steps to match your actual needs. For development builds, 1-3 days might suffice; for release candidates, perhaps 7-14 days. Avoid indefinite storage.
    - name: Upload artifact
      uses: actions/upload-artifact@v4
      with:
        name: build
        path: dist/
        retention-days: 7 # Adjust as needed
    
  • Monitor Usage and Billing: Regularly check your Actions usage via the organization's billing settings. This provides crucial visibility into current consumption and helps anticipate when you might approach limits. Integrating this into a performance analytics dashboard can provide a high-level overview of resource consumption alongside other CI/CD metrics.
  • Educate Your Team: Ensure all developers understand the impact of artifact storage and the importance of setting appropriate retention policies. This can be a great topic for a retrospective meeting agenda to discuss best practices and potential pitfalls.
  • Upgrade Your Plan: If your team's legitimate needs consistently exceed the free or current plan's storage limits, upgrading your GitHub plan is a straightforward solution. This is a cost of doing business for high-velocity teams.

Beyond the Technical: A Leadership Perspective

For CTOs and engineering managers, artifact storage isn't just a technical detail; it's a matter of operational efficiency and cost management. Unplanned downtime due to quota issues directly impacts project timelines and delivery commitments. Proactive management of CI/CD resources, including artifact storage, is a hallmark of mature engineering organizations.

By integrating artifact management into your team's standard operating procedures and regularly reviewing usage, you can ensure that GitHub Actions remains an accelerator, not an impediment, to your software developer productivity. Empowering your teams with clear guidelines and the right tooling prevents these frustrating blocks, keeping the focus on shipping value.

Conclusion

Hitting the GitHub Actions artifact storage quota can be a significant bottleneck, but it's a solvable problem with a combination of patience, immediate troubleshooting, and robust proactive strategies. From understanding the backend recalculation delays to optimizing artifact retention and monitoring organization-wide usage, technical leaders and developers alike have the tools to navigate this challenge. By adopting these best practices, teams can maintain seamless CI/CD pipelines, enhance software developer productivity, and ensure consistent, predictable delivery.

Share:

Track, Analyze and Optimize Your Software DeveEx!

Effortlessly implement gamification, pre-generated performance reviews and retrospective, work quality analytics, alerts on top of your code repository activity

 Install GitHub App to Start
devActivity Screenshot