Remove dead WordPressDataProvider and site REST proxy scaffolding - #4279
Merged
Conversation
The @wordpress/core-data data layer (WordPressDataProvider) was built but never rendered or imported, leaving its entire fetchSiteRest transport chain dead. Removes the provider, the connector method and impls, the desktop IPC plumbing, the POST /sites/:id/rest endpoint, and the shared proxy. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 task
Collaborator
📊 Performance Test ResultsComparing f07ad26 vs trunk app-size
site-editor
site-startup
Results are median values from multiple test runs. Legend: 🟢 Improvement (faster) | 🔴 Regression (slower) | ⚪ No change (<50ms diff) |
Contributor
|
Two minor follow-ups noticed while verifying the removal (neither blocks this PR):
|
Remove @wordpress/api-fetch, @wordpress/core-data, and @wordpress/data from apps/ui — they backed the deleted WordPressDataProvider and have no remaining imports. Also drop the site REST proxy rows from the surfaces design doc. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Contributor
Author
|
Thanks @youknowriad , both addressed. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related issues
How AI was used in this PR
Claude Code verified each symbol was unused independently (
grep -rnacrossapps+packages, checking for dynamic imports and string refs) before deleting anything, traced the fullfetchSiteRestdependency chain, confirmed the siblingreadLocalMediapath was still live and left it untouched, and ran lint/typecheck/tests. All changes were reviewed by the author.Proposed Changes
The
@wordpress/core-datadata layer (WordPressDataProvider) was built for Studio Desktop but is no longer wired into any UI, as Studio Desktop was removed. Because it was the only caller of thefetchSiteResttransport, that entire chain was dead: the connector method and itslocal/ipc/hostedimplementations, the desktop IPC plumbing, thePOST /sites/:id/restendpoint on the local CLI server, and the shared REST proxy in@studio/common.Testing Instructions
npm run typecheck— passes across all workspaces.npm test -- apps/studio/src/tests/ipc-handlers.test.ts apps/ui/src/data/core apps/ui/src/ui-classic/components/session-view/conversation— 32/32 pass, including thereadLocalMediaFilehandler test confirming the retained media path is intact.fetchSiteRest,WordPressDataProvider,SiteRestRequest, etc.) returns no matches.Pre-merge Checklist