-
Notifications
You must be signed in to change notification settings - Fork 137
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
Deprecate passing invalid keyword arguments #297
Conversation
Put all the icky global state in one place.
1f7ace1
to
14e07d7
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.
LGTM
if json is not _NOTHING: | ||
return ( | ||
self._data_to_body_producer( | ||
json_dumps(json, separators=(u',', u':')).encode('utf-8'), |
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.
The u
strings shouldn't be needed right? They would only make the output unicode in python2, but the encode
makes it bytes anyways.
When will treq drop python 2 anyways?
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 suppose the u
isn't necessary, but I will leave it as-is since I was only moving it.
Treq will probably drop Python 2 once the Twisted release is out. I want to kick out a release with these deprecations first, though.
Thanks for the review @ryban! |
This is the first step described in #287.