Skip to content

Dumps *gigantic* object into console on error #14529

@ChristopherJTrent

Description

@ChristopherJTrent

Prerequisites

  • I have written a descriptive issue title
  • I have searched existing issues to ensure the bug has not already been reported

Mongoose version

8.3.1

Node.js version

21.6.2

MongoDB server version

Irrelevant

Typescript version (if applicable)

No response

Description

Every time I have a problem with mongoose, it decides to dump a gigantic (larger than my terminal scrollback, which is set to 1 billion lines) object into the console.
This makes it completely impossible to diagnose anything.
I have mongoose.set('debug', false),
I don't have any other loggers enabled.

Steps to Reproduce

Happens in random places in this repo: https://github.com/acheung-94/pet-portal/tree/buildNewPetForm
notably when you send a put request to /api/pets/:id

Expected Behavior

I expect there to be some way to get mongoose to not dump the entire mongoose object to console

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions