google-api-nodejs-client
google-api-nodejs-client copied to clipboard
Trying to download large email (>5MB) throws when options http2: true
Environment details
- OS: Linux / Macos
- Node.js version: v18.10.0
- npm version: 8.19.2
-
googleapis
version: 105/109.0.1
Steps to reproduce
- Get a large email from Google API with the options {http2: false}
- The function returns the following error:
Could not download email 17d03869ffcd2de1 Error: unexpected end of file
at Zlib.zlibOnError [as onerror] (node:zlib:189:17)
at Zlib.callbackTrampoline (node:internal/async_hooks:130:17) {
errno: -5,
code: 'Z_BUF_ERROR'
}
Making the same request using the Try this API
Making the same request with the {http2: false} option works as well.
Possibly related with: #3108
I have also observed that. As http2 should be used now instead of batch calls, this is pretty critical thing.