Skip to content

punycode deprecation warning. #220

@cirvladimir

Description

@cirvladimir

Hello, I'm getting a deprecation warning when I use the @google-cloud/pubsub library.
Here is the warning:

(node:11518) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.

I checked where it's comming from, and I can see that in node_modules/whatwg-url/lib/url-state-machine.js there's a require("punycode"), which I assume causes the warning. Checking why my app imports that version of the whatwg-url pacakge I get the following:

└─┬ @google-cloud/pubsub@4.3.3
  └─┬ google-gax@4.3.1
    └─┬ node-fetch@2.7.0
      └── whatwg-url@5.0.0

Is there a newer version of something I'm supposed to be using so I don't get the warning?

Environment details

  • OS: Ubuntu
  • Node.js version: 21.7.0
  • npm version: 10.5.0
  • @google-cloud/pubsub version: 4.3.3

Steps to reproduce

  1. Install latest @google-cloud/pubsub from npm (version 4.3.3)
  2. import { PubSub } from "@google-cloud/pubsub";
  3. Run the app
  4. A deprecation warning pops up

Metadata

Metadata

Assignees

No one assigned

    Labels

    api: pubsubIssues related to the Pub/Sub API.priority: p2Moderately-important priority. Fix may not be included in next release.size: lPull request size is large.type: processA process-related concern. May include testing, release, or the like.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions