jayvdb added a comment.
@Halfak, re httplib2 , it doesnt have native support for oauth, but there are full-blown libraries around ( https://github.com/google/oauth2client/tree/master/oauth2client ), and also simple clients we could use as a template for a custom implementation (e.g. https://github.com/tswicegood/httplib2-oauth/blob/master/oauthclient/base.py ).
Given your involvement, I think it would be wise to try to use requests-oauthlib . I've tested it in py2.6 and provided a patch for one of its dependency bugs. https://github.com/requests/requests-oauthlib/pull/167
If we use requests-oauthlib, could we isolate the use of requests to only the Oauth negotiation, and copy the credentials from the requests session into a httplib2 session? Then only the login phase needs to use requests, and then httplib2 would be used for the rest of the workload. That would be simpler than a complete switch to requests.
TASK DETAIL https://phabricator.wikimedia.org/T74065
REPLY HANDLER ACTIONS Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign <username>.
EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: jayvdb Cc: Evanontario, Sitic, Qgil, Ricordisamoa, Nemo_bis, Halfak, Krinkle, jayvdb, valhallasw, MZMcBride, csteipp, scfc, coren, pywikipedia-bugs
pywikipedia-bugs@lists.wikimedia.org