fix: prevent spurious agent startup in dev mode and remove tiktoken#454
Merged
jesseturner21 merged 1 commit intomainfrom Feb 26, 2026
Merged
Conversation
When running `agentcore dev` with multiple agents, useDevServer would start the first agent's server before the user selected one, because getDevConfig defaults to agents[0] when agentName is undefined. Guard config resolution on agentName being set so the server only starts after explicit selection. Also remove tiktoken from the LangChain template dependencies as the package no longer resolves correctly.
Contributor
Coverage Report
|
jesseturner21
approved these changes
Feb 26, 2026
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
agentcore devwith multiple agents, the first agent's server would briefly start before the user selected one. This happened becauseuseDevServercalledgetDevConfigwithagentName: undefined, which defaults toagents[0]. Added a guard so the server only starts after an agent is explicitly selected.tiktoken == 0.11.0from the LangChain/LangGraph template dependencies as the package no longer resolves correctly. Also removed it from the reserved project names list.Test plan
agentcore devin a project with 2+ agents — verify only the selected agent's server starts (no brief startup of the first agent)agentcore dev --agent <name>— verify single-agent and--agentflag flows still workpyproject.tomlno longer includes tiktokennpm testpasses (149 test files, 1 snapshot updated)