fix: resolve submodule paths when fetching file contents#239
Conversation
GET /api/sandboxes/file now resolves paths inside git submodules to the correct submodule repo before fetching. Previously, submodule file paths returned 404 because the file doesn't exist in the parent repo. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ⛔ Files ignored due to path filters (2)
📒 Files selected for processing (2)
✨ 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 |
Summary
/api/sandboxes/filenow resolves paths that fall inside git submodules to the correct submodule repository before fetchingresolveSubmodulePath— checks.gitmodulesto detect if a path is within a submodule, and if so returns the submodule's repo URL with the relative pathTest plan
resolveSubmodulePathunit tests (8 tests) — submodule resolution, non-submodule passthrough, null gitmodules, invalid URL, nested paths, longest-match, directory boundary checkgetSandboxesFileHandlertests (8 tests) — added submodule resolution integration test🤖 Generated with Claude Code