#1028 Permission check for an unknown tenant answers 500 'Permission check failed' instead of 403/404
Description
EditFound during #1020 (live): GET /api/v1/analytics/queues?tenant_id=nosuchtenant1020 as admin@test: require_permission catches 'Tenant not found: nosuchtenant1020' from the auth library and returns 500 {status:error,error:'Permission check failed'} (before #1020 spectree turned it into a 500 pydantic list; after #1020 the body is served as written, still 500). Same for a JWT whose tenant does not exist. EARS: If the request names a tenant that does not exist, then the API shall answer 403 (or 404) without a 500 and without logging a stack trace at ERROR.
Comments
Loading comments...
Context
Loading context...
Audit History
View AllLoading audit history...