Summary
The framework startup banner prints Swagger: and Dashboard: URLs unconditionally,
including under tina4 serve --production and with TINA4_DEBUG=false, where both of
those endpoints correctly return 404.
Reproduction
TINA4_OVERRIDE_CLIENT=true tina4 serve --production --no-browser
Banner shows:
Server: http://localhost:7146 (uvicorn)
Swagger: http://localhost:7146/swagger
Dashboard: http://localhost:7146/__dev
Debug: OFF
but:
curl -o /dev/null -w '%{http_code}\n' http://127.0.0.1:7146/__dev # 404
curl -o /dev/null -w '%{http_code}\n' http://127.0.0.1:7146/swagger # 404
Why it matters
It is only cosmetic, but it is actively misleading in two directions: an operator
reads it as "swagger and the dev dashboard are exposed in production" (they are not),
and a developer clicking the link gets a 404 with no explanation. It also made
verifying the dev-admin production gate harder, because the banner and the actual
behaviour disagreed.
Proposed fix (all 4, parity)
Print each line only when that surface is actually enabled: gate the Swagger: line
on the swagger predicate (is_enabled() / isEnabled() / enabled? /
swaggerEnabled()) and the Dashboard: line on the dev-admin/debug gate. When
suppressed, print nothing rather than a dead URL.
Not yet fixed.
Summary
The framework startup banner prints
Swagger:andDashboard:URLs unconditionally,including under
tina4 serve --productionand withTINA4_DEBUG=false, where both ofthose endpoints correctly return 404.
Reproduction
Banner shows:
but:
Why it matters
It is only cosmetic, but it is actively misleading in two directions: an operator
reads it as "swagger and the dev dashboard are exposed in production" (they are not),
and a developer clicking the link gets a 404 with no explanation. It also made
verifying the dev-admin production gate harder, because the banner and the actual
behaviour disagreed.
Proposed fix (all 4, parity)
Print each line only when that surface is actually enabled: gate the
Swagger:lineon the swagger predicate (
is_enabled()/isEnabled()/enabled?/swaggerEnabled()) and theDashboard:line on the dev-admin/debug gate. Whensuppressed, print nothing rather than a dead URL.
Not yet fixed.