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.

How to only enable error logs?

See original GitHub issue

Hello,

I would like to disable regular logs (see below) to see only error logs.

The quiet option do not display error logs anymore.

Do you have any solutions?

    Asset       Size  Chunks             Chunk Names
  home.js  597 bytes       0  [emitted]  home
  main.js  663 bytes       1  [emitted]  main
common.js     297 kB       2  [emitted]  common

Issue Analytics

  • State:open
  • Created 8 years ago
  • Reactions:1
  • Comments:11 (3 by maintainers)

github_iconTop GitHub Comments

6reactions
karol-fcommented, Sep 4, 2015

+1

For now I’m using

webpackStream(webpackCfg, null, function(err, stats) {
                console.log(stats.compilation.errors.toString());
                console.log(stats.compilation.warnings.toString());
                plugins.browserSyncInstance.reload();
            })
3reactions
BorisKozocommented, Jun 9, 2016

Currently I am doing:

    let options = {
        colors: true
    };

    if (stats.hasErrors()) {
        options = {
            colors: true,
            hash: false,
            version: false,
            timings: false,
            assets: false,
            chunks: false,
            chunkModules: false,
            modules: false,
            children: false,
            cached: false,
            reasons: false,
            source: false,
            errorDetails: true,
            chunkOrigins: false
        };
    }

    console.log(stats.toString(options));

Works out pretty well so far …

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to Automate PHP Error Logging Quickly - Cloudways
Enable Error Logging in php.ini ... To log errors in PHP, open the php.ini file and uncomment/add the following lines of code. ......
Read more >
Display All PHP Errors: Basic & Advanced Usage
One easy way to use log files is to use the error_log function, which accepts four parameters. The only required parameter is the...
Read more >
How to Turn on WordPress Error Log (Using Debug Mode)
How to set up a WordPress error log · Step 1: Access and edit the wp-config.php file · Step 2: Add a line...
Read more >
PHP Log All Errors to a Log File to Get Detailed Information
Describes how to log ALL errors messages to a text log file when using the Apache/Nginx/Lighttpd web server with PHP fpm.
Read more >
How to Set Up WordPress Error Logs to Detect Issues (So You ...
How to enable error logging · 1. Connect to your website via sFTP · 2. Find and download your wp-config.php file · 3....
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