Open
Conversation
- Make webapplication.json optional (file-based routing when absent) - Skip client-side validation during retrieve (ZipTreeContainer) - Add containsPathTraversal() rejecting .., absolute paths, null bytes, control chars, glob wildcards, backslashes, and percent-encoding - Add assertNoTraversal() resolved-path check as defense in depth - Add 100 KB size limit matching server-side WebApplicationFileProcessor - Validate fallback/rewrite file existence with and without outputDir - Reject outputDir that resolves to the bundle root (. or ./) - Config paths must use forward slashes (URL-style, portable) Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
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.
What does this PR do?
Adds per-file deploy result tracking for WebApplication bundles. Previously, deploying a WebApplication returned a single rolled-up result for the entire bundle. Now, each individual file (HTML, JS, CSS, etc.) gets its own FileResponse with the correct Created/Changed/Deleted status, matching how LWC bundles already report per-file results.
Key changes:
Parse WebApplicationResource deploy messages into individual FileResponse entries, mapping server fullName values back to local file paths
Fix getState() to prioritize deleted over changed — the Metadata API sets both flags to true on deletes
Filter out server-generated internal paths (webapplicationcontentindex.json, languageSettings, /languages/) from user-facing results
Suppress spurious "unmatched server result" warnings for WebApplicationResource entries already consumed by their parent WebApplication
Guard webapplication.json validation to only run on real filesystem (NodeFSTreeContainer), preventing crashes during retrieve (ZipTreeContainer) and source tracking (VirtualTreeContainer).
What issues does this PR fix or reference?
#, @W-21301307@
Functionality Before
Deploying a WebApplication bundle returned a single entry in the deploy results table — just the bundle name and type. Individual file statuses were lost.
<insert gif and/or summary>
Functionality After
Each file in a WebApplication bundle gets its own row in the deploy results with accurate per-file status (Created, Changed, Deleted, Unchanged). The parent .webapplication-meta.xml also gets its own entry with the bundle-level state.
<insert gif and/or summary>