Skip to content
This repository was archived by the owner on Mar 3, 2026. It is now read-only.
This repository was archived by the owner on Mar 3, 2026. It is now read-only.

Move from teeny-request to standard Fetch API #2356

Closed

Description

@iRyusa

Is your feature request related to a problem? Please describe.
Using this lib with Bun is crashing when uploading a file.

1 | (function (stream, autoAllocateChunkSize) {"use strict";
                       ^
TypeError: undefined is not an object
      at lazyLoadStream (:1:20)
      at getReader (:1:20)
      at readStreamIntoSink (:1:32)
      at readableStreamIntoText (:1:20)
      at /.../node_modules/teeny-request/build/src/index.js:223:8
      at processTicksAndRejections (:55:76)

Describe the solution you'd like
Now than fetch is standard in Node/Bun/Deno/... I don't see teeny-request is needed as dep.

Describe alternatives you've considered
Overriding teeny-request by rexporting fetch locally, not ideal but at least it behave the same and the error goes away.

Additional context
n/a

Activity

  1. added
    priority: p3
    type: feature request
    on Nov 8, 2023
  2. added
    api: storage
    on Nov 8, 2023
  3. ddelgrosso1 commented on Nov 8, 2023

    @ddelgrosso1
    Contributor

    Thanks for opening an issue @iRyusa. We are currently still supporting Node 14+ which means we are unable to make the move to the NodeJS Fetch API that was added in Node 18. However, it is something we have in mind when we move to the appropriate minimum version.

  4. removed
    priority: p3
    on Nov 8, 2023
  5. ddelgrosso1 commented on Mar 13, 2024

    @ddelgrosso1
    Contributor

    A quick update, we are in the planning phases of moving away from teeny-request in favor of utilizing the auth client which by extension uses gaxios under the hood. The folks working on gaxios are definitely interested in moving that library away from node-fetch in the future once the minimum supported version moves to Node 18.

  6. iRyusa commented on Mar 13, 2024

    @iRyusa
    Author

    Really nice to hear 🙌

  7. ddelgrosso1 commented on Apr 22, 2024

    @ddelgrosso1
    Contributor

    Adding link for tracking / knowledge purposes googleapis/gaxios#618

  8. danielduhh commented on Aug 19, 2024

    @danielduhh
    Contributor

    Closing this as it should be fixed in gaxios: googleapis/google-cloud-node#7717

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

api: storagetype: feature request

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions