Skip to content

Remove old pages - #4678

Draft
marcoacierno wants to merge 2 commits into
mainfrom
remove-old-cms
Draft

Remove old pages#4678
marcoacierno wants to merge 2 commits into
mainfrom
remove-old-cms

Conversation

@marcoacierno

Copy link
Copy Markdown
Member

What

ToDo

@vercel

vercel Bot commented Jun 20, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
pycon Error Error Jun 20, 2026 6:01pm

@claude

claude Bot commented Jun 20, 2026

Copy link
Copy Markdown
Contributor

Removes the legacy pages Django app and its GraphQL API layer (PagesQuery, api/pages/), along with the page FK from MenuLink. The frontend already uses Wagtail CMS (cmsPages), so the removal looks safe on that side.

Critical: broken migration graph

cms/migrations/0006_menu_menulink.py declares a dependency on ('pages', '0002_auto_20190914_1504'), which no longer exists once the pages app is deleted. A fresh migrate run (CI, staging, new dev environment) will fail with an unresolvable dependency error. This needs to be fixed before merge — either by editing 0006 to remove that dependency entry, or by squashing the cms migration history.

Missing migration for cms schema drift

The page FK field is removed from cms/models.py (MenuLink) but no new migration was generated to drop the page_id column from cms_menulink. Running makemigrations after applying this PR will surface the drift. A migration with RemoveField(model_name='menulink', name='page') is needed.

pages_page table left in production

Deleting the app's migration files without a final DeleteModel migration (or a RunSQL DROP TABLE) means the pages_page table stays in every existing database indefinitely. Worth including a squash or a standalone data migration to clean it up.

@marcoacierno
marcoacierno marked this pull request as draft June 20, 2026 18:02
@codecov

codecov Bot commented Jun 20, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.41%. Comparing base (1e28562) to head (c66fc65).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4678      +/-   ##
==========================================
- Coverage   92.45%   92.41%   -0.04%     
==========================================
  Files         355      351       -4     
  Lines       10719    10656      -63     
  Branches      818      816       -2     
==========================================
- Hits         9910     9848      -62     
+ Misses        697      696       -1     
  Partials      112      112              
🚀 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.

@marcoacierno

Copy link
Copy Markdown
Member Author

@claude fix the merge conflicts

@claude

claude Bot commented Aug 15, 2026

Copy link
Copy Markdown
Contributor

Claude finished @marcoacierno's task in 3m 37s —— View job


Fixing merge conflicts

  • Fetch latest origin/main and identify conflicts
  • Resolve conflicts — blocked (see below)
  • Commit & push — blocked

I'm unable to fix the merge conflicts in this environment. Two things block me:

1. The git operations I need aren't in my allowed tools.
git fetch / git merge / git checkout / git stash all come back as "requires approval" and don't execute here (only git status, git diff, git add, git commit, and the push script are permitted). Without git merge I can't create the merge commit, and without git fetch --unshallow I can't get the history needed to merge.

2. The checkout is shallow.
origin/main only has its tip commit (ace3c25) and git merge-base HEAD origin/main finds no common ancestor, so even a local 3-way merge isn't possible until history is unshallowed — which needs the (blocked) git fetch.

What the conflicts look like

Comparing this branch against origin/main, main has moved on significantly since the branch was created. The relevant overlaps with this PR's deletions:

  • pages app is still alive on mainmain re-introduces/keeps backend/pages/** and backend/api/pages/** (including backend/api/tests/schema/test_pages.py), which this PR deletes. These will surface as delete/modify conflicts, and main may now have new references into pages that a straight deletion would break.
  • Files this PR modifies that main also changed (content conflicts likely):
    • backend/api/schema.py
    • backend/api/cms/types.py
    • backend/cms/models.py
    • backend/pycon/settings/base.py

Given how far main has advanced, this branch most likely needs to be rebased on the current main and have the pages-removal re-applied against the new state, rather than a simple conflict fixup.

To let me do this

Please grant these tools (via the action's --allowedTools) so I can fetch full history and merge:

Bash(git fetch:*), Bash(git merge:*), Bash(git checkout:*)

Then re-run @claude fix the merge conflicts and I'll complete it. Otherwise the merge can be resolved manually with:

git checkout remove-old-cms
git fetch origin main
git merge origin/main   # or: git rebase origin/main
# resolve conflicts (keep the pages/ + api/pages/ deletions), then commit & push

· branch remove-old-cms

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