Skip to content

[ENG-998] Move collectstatic to Build - #3753

Open
vigneshhari wants to merge 1 commit into
developfrom
ENG-998
Open

[ENG-998] Move collectstatic to Build#3753
vigneshhari wants to merge 1 commit into
developfrom
ENG-998

Conversation

@vigneshhari

@vigneshhari vigneshhari commented Sep 5, 2026

Copy link
Copy Markdown
Member

Proposed Changes

Move collectstatic and compilemessages to build time instead of run time.

Associated Issue

ENG-998

Summary by CodeRabbit

  • Deployment

    • Asset collection and translation compilation now occur during the build process rather than at application startup.
    • Release and service startup workflows no longer run static-asset collection or translation compilation.
    • Docker builds now support configured additional plugins and automatically prepare required assets.
  • Reliability

    • Build and deployment scripts now stop promptly when errors occur, helping prevent incomplete releases.

@vigneshhari
vigneshhari requested a review from a team as a code owner September 5, 2026 08:21
@coderabbitai

coderabbitai Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Essentials

Run ID: 2bc1010b-8e53-46f8-83a6-a96bdf36724e

📥 Commits

Reviewing files that changed from the base of the PR and between 513dae0 and 0346514.

📒 Files selected for processing (10)
  • .gitignore
  • Procfile
  • bin/post_compile
  • bin/pre_compile
  • docker/dev.Dockerfile
  • docker/prod.Dockerfile
  • scripts/build_assets.sh
  • scripts/celery_beat.sh
  • scripts/celery_worker.sh
  • scripts/start.sh
💤 Files with no reviewable changes (3)
  • scripts/celery_beat.sh
  • scripts/start.sh
  • scripts/celery_worker.sh

Included review availability: 4 reviews are currently available. Your included PR review attempts over the past 7 days set your current allowance at 5 reviews per hour.


📝 Walkthrough

Walkthrough

Changes

The change centralizes asset building in scripts/build_assets.sh. Docker and release workflows invoke it, while service startup scripts no longer run asset collection or message compilation.

Asset build flow

Layer / File(s) Summary
Asset build hooks
.gitignore, bin/pre_compile, bin/post_compile, scripts/build_assets.sh
The repository tracks the compile hooks. The hooks create the collectstatic-disable marker, install plugins, compile messages, and collect static assets.
Build and release integration
docker/dev.Dockerfile, docker/prod.Dockerfile, Procfile
Docker builds invoke build_assets.sh with plugin settings. The release command runs migrations without collectstatic.
Service startup cleanup
scripts/celery_beat.sh, scripts/celery_worker.sh, scripts/start.sh
Celery beat, Celery worker, and Gunicorn startup no longer collect static files or compile messages.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Merge Risk: ⚪ Minimal · up to 03465

Asset compilation is moved from release and startup paths into build hooks and Docker build steps. No concrete current-head issue remains that blocks merging.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description check ✅ Passed The description clearly states the change and references associated issue ENG-998. The optional architecture section and merge checklist are not included, but the description is mostly complete and di…
Title check ✅ Passed The title clearly identifies the primary change: moving collectstatic to the build stage. It is concise and directly related to the pull request changes.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch ENG-998

Comment @coderabbitai help to get the list of available commands.

@codecov

codecov Bot commented Sep 5, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 79.65%. Comparing base (513dae0) to head (0346514).

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #3753   +/-   ##
========================================
  Coverage    79.65%   79.65%           
========================================
  Files          482      482           
  Lines        23292    23292           
  Branches      2424     2424           
========================================
  Hits         18554    18554           
  Misses        4137     4137           
  Partials       601      601           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@vigneshhari vigneshhari changed the title [ENG-998] Move collectstatic to branch [ENG-998] Move collectstatic to Build Sep 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant