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

puny code module deprecated warning #14108

Closed
1 task done
AhmadTahir999 opened this issue Nov 22, 2023 · 2 comments
Closed
1 task done

puny code module deprecated warning #14108

AhmadTahir999 opened this issue Nov 22, 2023 · 2 comments
Labels
underlying library issue This issue is a bug with an underlying library, like the MongoDB driver or mongodb-core
Milestone

Comments

@AhmadTahir999
Copy link

Prerequisites

  • I have written a descriptive issue title

Mongoose version

8.0.1

Node.js version

21.2.0

MongoDB version

MongoDB atlas

Operating system

macOS

Operating system version (i.e. 20.04, 11.3, 10)

No response

Issue

I am using mongoose and it has started giving puny code module deprecated warning, Please use a userland alternative instead.
mongoose connection is causing the warning if don't use the connection I have given below warning goes away. Can anyone guide me on how can I get rid of this warning? thank you for your time

const mongoose = require("mongoose");

mongoose.Promise = global.Promise;

const connect = async () => {
   try {
      await mongoose.connect(process.env.MONGO_URI);
      console.log("mongodb connected...");
   } catch (error) {
      console.log(error.message);
      process.exit(1);
   }
};

const connection = mongoose.connection;

exports.connect = connect;
exports.connection = connection;
@AhmadTahir999 AhmadTahir999 added help This issue can likely be resolved in GitHub issues. No bug fixes, features, or docs necessary help wanted labels Nov 22, 2023
@Uzlopak
Copy link
Collaborator

Uzlopak commented Nov 22, 2023

We are not directly using punycode. Please report this to the upstream depenedency.

@Uzlopak Uzlopak closed this as not planned Won't fix, can't repro, duplicate, stale Nov 22, 2023
@vkarpov15
Copy link
Collaborator

Duplicate of #14104, will be fixed in 8.1

@vkarpov15 vkarpov15 reopened this Nov 25, 2023
@vkarpov15 vkarpov15 added this to the 8.1 milestone Nov 25, 2023
@vkarpov15 vkarpov15 added underlying library issue This issue is a bug with an underlying library, like the MongoDB driver or mongodb-core and removed help This issue can likely be resolved in GitHub issues. No bug fixes, features, or docs necessary help wanted labels Nov 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
underlying library issue This issue is a bug with an underlying library, like the MongoDB driver or mongodb-core
Projects
None yet
Development

No branches or pull requests

3 participants