question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Can logging be disabled?

See original GitHub issue

Expected Behavior

Ideally it would not log steps to the console by default, or logging could be disabled. I see the IS_LOG value in the “flags” module, but it’s defined as a const and I’m not sure how I can affect that value at run time in a way to prevent logging. Thanks!

Describe the problem

Actual Behavior

Currently the library prints messages to the console as it’s executing, such as: Checking to see if there is an authorization response to be delivered. (here)

Steps to reproduce the behavior

Invoking the library functions as demonstrated in the Electron sample application

Environment

  • AppAuth-JS version: 0.3.5
  • AppAuth-JS Environment (Node, Browser (UserAgent), …): node 10.9

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:16
  • Comments:10 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
ArthurKnoepcommented, Mar 2, 2020

Are there any updates on this ?

1reaction
aikovencommented, Sep 15, 2020

For now one can manually edit node_modules/@openid/appauth/built/flags.js file to set IS_LOG = false and then use patch-package to persist these changes.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Enabling and disabling logging - IBM
This topic describes how to enable and disable logging through the administrative console.
Read more >
Disabling Cloud Logging | Resource Manager Documentation
To disable Cloud Logging, you must have the Organization Administrator ( roles/resourcemanager.organizationAdmin ) role. This role can only be granted at ...
Read more >
Python Logging - Disable logging from imported modules
The problem is that calling getLogger without arguments returns the root logger so when you set the level to logging.
Read more >
Enable or disable query and response logging
You can temporarily enable query and response logging to help ​Akamai​ troubleshoot an issue. These logs are sent and available to ​Akamai​.
Read more >
How can I enable/disable logging on specific devices?
In order to save your user's battery and bandwidth, you may want that not all devices send logs by default. Here is how:...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found