feat: GitHub-backed devcontainer config dropdown for project chat#1021
Merged
simple-agent-manager[bot] merged 7 commits intoMay 16, 2026
Conversation
Replace the free-text devcontainer config input in project chat with a dropdown populated from the project's GitHub repository. Users can now see which named devcontainer configs exist without remembering directory names. API: GET /api/projects/:projectId/devcontainer-configs discovers configs by querying the GitHub git tree API, with a contents API fallback for truncated trees. Non-GitHub projects return a graceful unsupported response. Frontend: Reusable DevcontainerConfigSelect component and useDevcontainerConfigs hook. Auto-detect is always the first option. Saved values not found in discovery show as "(saved, not found)". Discovery failure is non-blocking. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.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
GET /api/projects/:projectId/devcontainer-configsendpoint that discovers devcontainer configs from the project's GitHub repository using the git tree API, with contents API fallback for truncated trees.DevcontainerConfigSelectanduseDevcontainerConfigssurfaces for future reuse in task/profile/settings forms.app.sammy.partyweb asset bundle after a Pages/API deploy.Details
API Endpoint
requireOwnedProject.project.installationId->githubInstallations.id-> externalinstallationIdfor token generation..devcontainer/devcontainer.json, root.devcontainer.json) as auto-detect support..devcontainer/<name>/devcontainer.json, filtered byDEVCONTAINER_CONFIG_NAME_REGEXand max length.{ unsupported: true, configs: [] }.Frontend
DevcontainerConfigSelectalways includes "Auto-detect" as first option.<name> (saved, not found).ChatInputuses the dropdown on both mobile and desktop when the workspace profile is not lightweight.Not in scope
TaskSubmitForm,ProfileFormDialog, andSettingsDrawer.Test plan
pnpm --filter @simple-agent-manager/api test -- devcontainer-configs(18 passing).pnpm --filter @simple-agent-manager/web test -- devcontainer-config-select(9 passing).pnpm lintexits 0 (existing warnings only).pnpm typecheck.9ea499d4.25957699022passed; authenticated Playwright onhttps://app.sammy.party/projects/01KJNR9R3TEN3KX1ETE33852R8/chatverified Config renders as a<select>withAuto-detect, andGET https://api.sammy.party/api/projects/01KJNR9R3TEN3KX1ETE33852R8/devcontainer-configsreturned the GitHub-backed CrewAI response.Linked Idea
01KRNJTR9T4XZ2RMZWRZCGP88F— GitHub-backed devcontainer config dropdown for project chatSpecialist Review Evidence (Required for agent-authored PRs)
needs-human-reviewlabel added and merge deferred to humanselectedDevcontainerConfigNamesubmission path; discovery endpoint and component have focused tests.Exceptions (If any)
Agent Preflight (Required)
Classification
External References
Official documentation for the GitHub REST API was consulted for repository tree and contents discovery behavior:
Codebase Impact Analysis
Affected code paths are
apps/api/src/routes/projects/devcontainer-configs.tsandapps/api/src/routes/projects/index.tsfor the new project-scoped endpoint,apps/web/src/hooks/useDevcontainerConfigs.tsandapps/web/src/components/devcontainer/DevcontainerConfigSelect.tsxfor discovery UI state,apps/web/src/lib/api/projects.tsandapps/web/src/lib/api/index.tsfor client API wiring, andapps/web/src/pages/project-chat/ChatInput.tsx/index.tsxfor the chat submission surface. Tests were added underapps/api/tests/unit/routes/devcontainer-configs.test.tsandapps/web/tests/unit/components/devcontainer-config-select.test.tsx. The reusable staging deploy workflow also re-deploys the API Worker once after secret configuration so the custom-domain Worker ends with the current built asset bundle.Documentation & Specs
N/A: this change is a small product surface addition for an already-supported devcontainer config field. The API and UI behavior are documented in this PR body, and follow-up surfaces are explicitly out of scope.
Constitution & Risk Check
Checked Principle XI/no hardcoded values by reusing shared
DEVCONTAINER_CONFIG_NAME_REGEXandDEVCONTAINER_CONFIG_NAME_MAX_LENGTHinstead of duplicating validation rules. Main risks are GitHub API failure, token leakage, and UI/backend drift; the implementation returns sanitized 502 responses, never sends installation tokens to the browser, and keeps chat submission on the existingdevcontainerConfigNamerequest path.🤖 Generated with Claude Code