Skip to content

Conversation

@alexcottner
Copy link
Contributor

Ref #977 - Moving back to 400 responses for stale expected values after fastly migration

Leaving in draft for now, will merge when we are ready to test.

@alexcottner alexcottner marked this pull request as ready for review August 7, 2025 20:48
@alexcottner alexcottner requested a review from a team as a code owner August 7, 2025 20:48
@alexcottner alexcottner added the bug Something isn't working label Aug 7, 2025
# Check if client is trying to go back in time, return 400 response
if qs_expected > 0 and qs_expected < qs_since:
response = httpexceptions.HTTPNoContent()
response = httpexceptions.HTTPBadRequest()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See changes of #982

Suggested change
response = httpexceptions.HTTPBadRequest()
raise_invalid(
request,
name="_expected",
location="querystring",
description="`_expected` parameter cannot be lower than `_since`",

@leplatrem
Copy link
Contributor

maybe just revert #982 instead

@alexcottner alexcottner marked this pull request as draft September 2, 2025 15:11
@leplatrem
Copy link
Contributor

Please note that 400 requests won't be cached by the CDN (see https://github.com/mozilla/webservices-infra/pull/7525)

(This should be OK though since we don't reach the DB before returning them)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants