Fix misleading "Failed to auto-start" warnings on component creation#118
Draft
Copilot wants to merge 2 commits into
Draft
Fix misleading "Failed to auto-start" warnings on component creation#118Copilot wants to merge 2 commits into
Copilot wants to merge 2 commits into
Conversation
Copilot
AI
changed the title
[WIP] Fix incorrect log messages starting up Drasi Server
Fix misleading "Failed to auto-start" warnings on component creation
Jun 4, 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.
Creating a reaction (or source) with
autoStart: truelogged a spuriousWARN ... Failed to auto-start ... is already running, even though the component started fine. A genuine start failure was also logged atWARNrather thanERROR.Root cause
DrasiLib::add_{reaction,source}_with_metadataalready auto-starts the component when the server is running. The create/upsert handlers then calledstart_*again unconditionally — the second start hit an already-running component, producing the misleading warning (plus extra drasi-lib state-transition warnings for some component types).Changes
start_*when the component is stillStopped(i.e.adddid not auto-start it, e.g. server not yet running).ERRORinstead ofWARN.create+upserthandlers.Tests
test_create_reaction_auto_start_via_api: POSTs a reaction withautoStart: trueand asserts it reachesRunning. Logs confirm the component is now started exactly once.