fix(markdown): restore document creation and updates - #2940
Closed
George Ng (GeorgeNgMsft) wants to merge 7 commits into
Closed
fix(markdown): restore document creation and updates#2940George Ng (GeorgeNgMsft) wants to merge 7 commits into
George Ng (GeorgeNgMsft) wants to merge 7 commits into
Conversation
Restrict the unauthenticated Markdown HTTP and WebSocket service to 127.0.0.1 and advertise the same address to collaboration clients. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 824e625d-be4c-48f5-91c7-88675b55c6e6
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 02e51644-28c8-4b3f-98da-61c5fe172346
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 02e51644-28c8-4b3f-98da-61c5fe172346
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 02e51644-28c8-4b3f-98da-61c5fe172346
| message.operations, | ||
| ); | ||
| if (writableFilePath) { | ||
| fs.writeFileSync(writableFilePath, content, "utf-8"); |
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 02e51644-28c8-4b3f-98da-61c5fe172346
George Ng (GeorgeNgMsft)
marked this pull request as draft
August 28, 2026 01:58
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 02e51644-28c8-4b3f-98da-61c5fe172346
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
This was referenced Sep 3, 2026
Contributor
Author
|
Separating this out into multiple smaller PRs |
Contributor
Author
|
Superseded by native stack #2970, split bottom-to-top for reviewability:
The final stack was validated with the Markdown build, all 8 Markdown test suites (64 tests), Prettier, lint/complexity/circular/debt gates, and exact branch ancestry checks. |
jebrans
pushed a commit
to jebrans/TypeAgent
that referenced
this pull request
Sep 6, 2026
## Summary This PR fixes document creation and separates open/create semantics Layer 1 (bottom) of the replacement stack for microsoft#2940. This layer adds only core workspace-safe Markdown document creation: - propagates the host-authorized working directory through action context and agent RPC - creates Markdown files under that workspace, including nested relative paths - preserves requested initial content - rejects traversal, absolute/drive-qualified, out-of-workspace, and symlink-escape paths - avoids constructing the Markdown model for create/open actions - passes the CLI request working directory into dispatch ## Deferred to upper layers - document update/edit semantics - revision and binding-token conflict checks - streaming update persistence - browser-view persistence and synchronization - reopening editor bindings - loopback view-server changes - the unrelated `aiclient` runtimeConfig/OpenAI change ## Validation - `pnpm run prettier:changed:fix` / `pnpm run prettier:changed` (pass) - lint ratchet (pass) - complexity ratchet (pass) - circular-dependency ratchet (pass) - debt/skipped-test gate (pass) - direct path-policy smoke covering nested creation, traversal rejection, canonical root resolution, and junction escape rejection (pass) - affected TypeScript build and Jest suites were attempted but environment-blocked: worktree setup could not fetch locked public packages `baseline-browser-mapping@2.11.19` and `uuid@14.0.2` because Azure Artifacts returned 401, leaving workspace package links incomplete; the resulting compiler errors were missing-module diagnostics --------- Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.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.
Summary
ActionContext, and out-of-process agent RPC/file/loadrebinding path and evict stale collaboration roomsValidation
ActionContexttests passmarkdown.createDocument, wrote exact content at the repository root, appeared ingit status, and returned an editor URL that responded successfully