-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: verb request and response types can be any FTL type #1912
Conversation
I realised afterwards that the issue refers to only making the response type more lenient, not the request type. Lmk if I should keep the request type strict |
if err != nil { | ||
return fmt.Errorf("HTTP request body is not valid JSON: %w", err) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's odd to me that these checks are in the ingress package even though they check the validity of request data for all requests.
I've removed "HTTP" from the error message because this is being used outside of HTTP use cases
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It doesn't make much sense for this function to be in this package anymore really.
dff622c
to
6da5eea
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add an integration test for this please?
if err != nil { | ||
return fmt.Errorf("HTTP request body is not valid JSON: %w", err) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It doesn't make much sense for this function to be in this package anymore really.
Request or response type is fine, let's merge. |
6da5eea
to
c71696d
Compare
Should we merge this one @matt2e or are we holding off for stability? |
# Conflicts: # backend/controller/ingress/ingress.go
c71696d
to
0e30991
Compare
7f0c29a
to
4b103b3
Compare
closes #1854