-
Notifications
You must be signed in to change notification settings - Fork 4
Introduce Accept headers for sending federation transactions
#36
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
base: master
Are you sure you want to change the base?
Conversation
This is currently not processed by the receiving end
| backoff_on_404: bool = False, | ||
| backoff_on_all_error_codes: bool = False, | ||
| follow_redirects: bool = False, | ||
| headers: Optional[Dict[bytes, List[bytes]]] = None, |
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.
I don't think this should be a dictionary of generic headers, we really just want to have the expected mimetype for a request, imo
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 was based on prior art, which allowed for a very simple way of rolling this into the existing headers with a simple update. What are the chances of needing some other kind of header later on from some other endpoint needing it? Like media? I would have liked to be able to add the Content-Length or something like it there(if I recall, it was missing since the last change?)
| try_trailing_slash_on_400: bool = False, | ||
| parser: Literal[None] = None, | ||
| backoff_on_all_error_codes: bool = False, | ||
| headers: Optional[Dict[bytes, List[bytes]]] = None, |
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.
This should not default to None, we are expecting json...
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.
We are expecting json, but we also do not know which places this is safe to inject into without other repercussions. It's optional for a reason, and matches well with other pre-existing similar architecture that is used
|
We will back-burner this idea for a while |
This is currently not processed by the receiving end