generated from nyjc-computing/replit-flask-app
-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Bug Description
The PATCH /auth/v1/credentials/{provider}/{user_id} endpoint returns a 500 server error when attempting to update credentials.
Location
- Route:
campus/auth/routes/credentials.py:91-112 - Resource:
campus/auth/resources/credentials.py
Error
# Returns 500 with internal server error
PATCH /auth/v1/credentials/campus/user@example.com
Content-Type: application/json
Authorization: Bearer <token>
{
"token": {
"id": "token_id",
"scopes": ["read", "write"],
"expiry_seconds": 7200
}
}
Expected Behavior
Should return 200 with the updated credentials resource, or appropriate error codes (400/404) for invalid requests.
Contract Test Blocked
tests/contract/test_auth_credentials.py::TestAuthCredentialsContract::test_update_credentialsis skipped due to this bug
Investigation Needed
- Verify the expected request payload format for updating credentials
- Check if the issue is with the token object structure
- May need to pass an
OAuthTokenmodel object instead of a dict
Related
- Found during Phase 3 of integration test refactor
- HTTP contract test coverage expansion
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working