Skip to content

[user] Fix 500 on subscription-check routes#1146

Merged
frankrousseau merged 1 commit into
cgwire:mainfrom
frankrousseau:fix-subscribed-route-500-clean
Jul 8, 2026
Merged

[user] Fix 500 on subscription-check routes#1146
frankrousseau merged 1 commit into
cgwire:mainfrom
frankrousseau:fix-subscribed-route-500-clean

Conversation

@frankrousseau

Copy link
Copy Markdown
Contributor

Problems

  • GET on the subscription-check routes (task and sequence .../subscribed)
    returned a bare bool, which plain Flask MethodView cannot serialize,
    raising a 500 (TypeError, "it was a bool").
  • Only the service layer was tested; no HTTP test covered these routes.

Solutions

  • Wrap the boolean in jsonify in HasTaskSubscribedResource and
    HasSequenceSubscribedResource, restoring the true/false JSON response.
  • Add an HTTP test exercising the subscribe then subscribed flow.

The subscribed routes returned a bare bool, which plain Flask MethodView
cannot serialize (flask_restful used to auto-serialize it). Wrap the
value in jsonify to restore the boolean JSON response, and add an HTTP
test that exercises the subscribe then subscribed flow.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@frankrousseau frankrousseau merged commit 87f95bc into cgwire:main Jul 8, 2026
14 checks passed
@frankrousseau frankrousseau deleted the fix-subscribed-route-500-clean branch July 10, 2026 12:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant