Fix PR creation from origin-based worktrees (#3218) - #119
Conversation
Co-authored-by: Julius Marminge <julius@mac.lan>
Co-authored-by: Julius Marminge <julius@mac.lan>
…3219) Co-authored-by: Codex <codex@openai.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: Julius Marminge <julius@mac.lan>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
Co-authored-by: codex <codex@users.noreply.github.com>
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
… sync/upstream-20260619-ui-settings-imports # Conflicts: # apps/server/src/provider/Layers/ProviderSessionDirectory.test.ts
… sync/upstream-20260619-ui-settings-imports
… sync/upstream-20260619-ui-settings-imports
… sync/upstream-20260619-ui-settings-imports
… sync/upstream-20260619-ui-settings-imports
… sync/upstream-20260619-ui-settings-imports
… sync/upstream-20260619-ui-settings-imports
… sync/upstream-20260619-ui-settings-imports
… sync/upstream-20260619-ui-settings-imports
… sync/upstream-20260619-ui-settings-imports
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 90614b8775
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const absolutePath = path.resolve(input.workspaceRoot, normalizedInputPath); | ||
| const relativeToRoot = toPosixRelativePath(path.relative(input.workspaceRoot, absolutePath)); | ||
| if ( | ||
| relativeToRoot.length === 0 || | ||
| relativeToRoot === "." || | ||
| relativeToRoot.startsWith("../") || | ||
| relativeToRoot === ".." || | ||
| path.isAbsolute(relativeToRoot) |
There was a problem hiding this comment.
Restore realpath checks for workspace-relative paths
When relativePath traverses a symlinked directory inside the workspace (for example link -> /tmp and link/out.txt), this lexical path.relative check still treats the path as inside the root. WorkspaceFileSystem.writeFile relies on this resolver and then writes target.absolutePath without its own realpath recheck, so a workspace can cause writes outside the project root; the previous resolver resolved real paths/deepest existing ancestors before allowing the path.
Useful? React with 👍 / 👎.

What Changed
Why
UI Changes
Checklist