Skip to content
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

fix: update content-length header for next page requests #1404

Merged
merged 2 commits into from Jun 8, 2021

Conversation

@schweikert
Copy link
Contributor

@schweikert schweikert commented Jun 7, 2021

The content-length header only gets updated at request object initialization, so make sure we update it here after we modified the body.

Fixes #1403

@schweikert schweikert requested a review from as a code owner Jun 7, 2021
@google-cla google-cla bot added the cla: yes label Jun 7, 2021
@schweikert schweikert force-pushed the fix_1403 branch 2 times, most recently from 1e2117d to 04bd2d8 Jun 7, 2021
Copy link
Contributor

@busunkim96 busunkim96 left a comment

Thank you! Could you add/modify a test that checks for this?

class Next(unittest.TestCase):

@busunkim96 busunkim96 changed the title update content-length header for next page requests fix: update content-length header for next page requests Jun 7, 2021
@schweikert schweikert force-pushed the fix_1403 branch 2 times, most recently from a630385 to 1e048d2 Jun 8, 2021
@schweikert
Copy link
Contributor Author

@schweikert schweikert commented Jun 8, 2021

Thank you! Could you add/modify a test that checks for this?

Ah yes, thanks for spotting this! Done.

The content-length header only gets updated at request object
initialization, so make sure we update it here after we modified the
body.

Fixes googleapis#1403
@busunkim96 busunkim96 merged commit 8019f2f into googleapis:master Jun 8, 2021
3 checks passed
gcf-merge-on-green bot pushed a commit that referenced this issue Jun 14, 2021
🤖 I have created a release \*beep\* \*boop\*
---
## [2.9.0](https://www.github.com/googleapis/google-api-python-client/compare/v2.8.0...v2.9.0) (2021-06-12)


### Features

* **analyticsadmin:** update the api 3ed7887 ([33237a8](https://www.github.com/googleapis/google-api-python-client/commit/33237a8250e3becfaa1e4b5f67ef0c887cfc44a9))
* **analyticsadmin:** update the api a715d2b ([0f0918f](https://www.github.com/googleapis/google-api-python-client/commit/0f0918f92a699753b52c77dd236ad84ee00a32a7))
* **apigee:** update the api 9fcf80b ([0f0918f](https://www.github.com/googleapis/google-api-python-client/commit/0f0918f92a699753b52c77dd236ad84ee00a32a7))
* **appengine:** update the api ffcf860 ([26aa9e2](https://www.github.com/googleapis/google-api-python-client/commit/26aa9e282e30ca9c8797ee5346cbe9c0b9ca65a7))
* **chat:** update the api 47ff8a5 ([0f0918f](https://www.github.com/googleapis/google-api-python-client/commit/0f0918f92a699753b52c77dd236ad84ee00a32a7))
* **composer:** update the api 4862529 ([33237a8](https://www.github.com/googleapis/google-api-python-client/commit/33237a8250e3becfaa1e4b5f67ef0c887cfc44a9))
* **containeranalysis:** update the api 9a1c70b ([26aa9e2](https://www.github.com/googleapis/google-api-python-client/commit/26aa9e282e30ca9c8797ee5346cbe9c0b9ca65a7))
* **documentai:** update the api 07a6e77 ([26aa9e2](https://www.github.com/googleapis/google-api-python-client/commit/26aa9e282e30ca9c8797ee5346cbe9c0b9ca65a7))
* **drive:** update the api 773910f ([26aa9e2](https://www.github.com/googleapis/google-api-python-client/commit/26aa9e282e30ca9c8797ee5346cbe9c0b9ca65a7))
* **genomics:** update the api 8a1c8a6 ([33237a8](https://www.github.com/googleapis/google-api-python-client/commit/33237a8250e3becfaa1e4b5f67ef0c887cfc44a9))
* **gkehub:** update the api 0fd49e0 ([33237a8](https://www.github.com/googleapis/google-api-python-client/commit/33237a8250e3becfaa1e4b5f67ef0c887cfc44a9))
* **managedidentities:** update the api 0927c19 ([c3f8675](https://www.github.com/googleapis/google-api-python-client/commit/c3f86757bccb6b42552f87d37a645651c58d6c7a))
* **managedidentities:** update the api e96adbb ([26aa9e2](https://www.github.com/googleapis/google-api-python-client/commit/26aa9e282e30ca9c8797ee5346cbe9c0b9ca65a7))
* **spanner:** update the api 87da2f3 ([26aa9e2](https://www.github.com/googleapis/google-api-python-client/commit/26aa9e282e30ca9c8797ee5346cbe9c0b9ca65a7))


### Bug Fixes

* update content-length header for next page ([#1404](https://www.github.com/googleapis/google-api-python-client/issues/1404)) ([8019f2f](https://www.github.com/googleapis/google-api-python-client/commit/8019f2f96abc6a4375873becb2f17b399f738654)), closes [#1403](https://www.github.com/googleapis/google-api-python-client/issues/1403)
---


This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

4 participants