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

process.env.DEBUG variable can have many values #302

Open
1 task done
OleksandrKucherenko opened this issue Sep 9, 2023 · 1 comment
Open
1 task done

process.env.DEBUG variable can have many values #302

OleksandrKucherenko opened this issue Sep 9, 2023 · 1 comment
Labels
enhancement New feature or request

Comments

@OleksandrKucherenko
Copy link

Confirm this is a Node library issue and not an underlying OpenAI API issue

  • This is an issue with the Node library

Describe the bug

process.env.DEBUG variable can be used by many libraries, for example: debug npm

more details: https://github.com/debug-js/debug#windows-command-prompt-notes

in other words DEBUG environment variable can be something more complicated than just a true or undefined.

To Reproduce

https://github.com/openai/openai-node/blob/master/src/core.ts#L994-L998

DEBUG=* yarn start:dev
DEBUG=*,-openai  yarn start:dev
DEBUG=openai yarn start:dev

Code snippets

https://github.com/openai/openai-node/blob/master/src/core.ts#L994-L998

 
DEBUG=* yarn start:dev # max verbosity
DEBUG=*,-openai  yarn start:dev # show all debug msgs except openai
DEBUG=openai yarn start:dev # show only openai logs

OS

macOs, Windows, Linux

Node version

any

Library version

4.6.0

@OleksandrKucherenko OleksandrKucherenko added the bug Something isn't working label Sep 9, 2023
@rattrayalex rattrayalex removed the bug Something isn't working label Sep 9, 2023
@rattrayalex
Copy link
Collaborator

Thank you for the feature request; we'll think this over.

@rattrayalex rattrayalex added the enhancement New feature or request label Sep 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants