-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Expose internal request object #111
Conversation
update with upstream
Keep track of the last http request submitted by the transporter. can be used to access socket information, e.g. to achieve progress tracking on uploads.
Thanks for the PR. Returning back to #106, I'd like to return request object instead. But, the idea of transporters came into the scene why we wanted to decouple http requests from requests module. It's not just the transporter doesn't provide any useful interfaces to learn more about what's going on, also it shouldn't be transporter's role to provide info. I should probably introduce an Leaving this PR open for now. |
Thanks rakyll. Any guidance/alternatives for a short term solution that would allow me to reach into the request object? My google drive synchronization app need to be able to provide progress report (especially on big files) and I was hoping this pull request is harmless enough that we could use it until a better solution emerges. |
Fixed in 1.0.0. You can now specify request options as a default without worrying explicitly about the request object. More information on passing additional options here: https://github.com/google/google-api-nodejs-client#options Let me know how this works out for you. |
this pull request fixes #106 in a naive implementation.