devagentic-canvas: auto-append /v1 to base URL when missing#14
Merged
Conversation
Operators in containerized deployments naturally set
DEVAGENTIC_BASE_URL=$DUPLEX_SERVICE_URL — which omits the /v1
prefix. The canvas plugin then composes {base}/canvases →
http://devbox:6070/canvases and silently 404s (logged DEBUG,
returns None from _request, slash command shows opaque error).
Fix: in _base_url(), append /v1 unless the resolved value already
ends with /vN. Backward-compatible (existing setups with explicit
/v1 are unaffected). Respects explicit /v2, /v3 etc.
Skills + memory adapters already handle both forms (they
unconditionally strip /v1 because they target /graphql) — only
canvas was affected.
Closes #13.
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
Closes #13. Dogfooded from inside
devagentic-duplex-claude— operators who follow the natural container pattern (DEVAGENTIC_BASE_URL=\$DUPLEX_SERVICE_URL) silently 404 because the env var only carries the host[:port], not the/v1prefix the canvas client appends paths under.Fix
plugins/devagentic-canvas/client.py::_base_url()now appends/v1unless the resolved value already ends with/vN. Backward-compatible — existing setups with explicit/v1are unaffected; explicit/v2//v3etc. are respected.Scope
Only the canvas plugin is affected. The skills + memory adapters (
agent/devagentic_skills.py,agent/devagentic_memory.py) already handle both forms — they unconditionally strip/v1because they target…/graphql. Issue #13's initial scope was broader; on triage it narrowed to canvas only, called out in the issue's own resolution.Test plan
tests/test_devagentic_canvas_plugin.pycovering: missing/v1, explicit/v1, explicit/v2, trailing slash. All four cover the matrix in [synergy] DEVAGENTIC_BASE_URL silently 404s when /v1 prefix is omitted (canvas plugin + skills + memory adapters) #13.pytest tests/test_devagentic_canvas_plugin.py→ 36 passed (32 previous + 4 new).Filed by hermes-maintainer (PowerCreek).