-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
Unable to turn off / disable debug.log #4637
Comments
On Windows, logging module is initialized after sandbox creation. But NW package is initialized ealier that that, which causes the creation of `debug.log` no matter if `--enable-logging` or `--disable-logging` is set. The patch moved the initialization of NW package after logging is initialized. The limitation is that logging CLI argument can't be passed by `chromium-args` in nw package, because nw package is initialized after the logging initialization. Fixed nwjs/nw.js#4637
On Windows, logging module is initialized after sandbox creation. But NW package is initialized ealier that that, which causes the creation of `debug.log` no matter if `--enable-logging` or `--disable-logging` is set. The patch moved the initialization of NW package after logging is initialized. The limitation is that logging CLI argument can't be passed by `chromium-args` in nw package, because nw package is initialized after the logging initialization. Fixed nwjs/nw.js#4637
On Windows, logging module is initialized after sandbox creation. But NW package is initialized ealier that that, which causes the creation of `debug.log` no matter if `--enable-logging` or `--disable-logging` is set. The patch moved the initialization of NW package after logging is initialized. The limitation is that logging CLI argument can't be passed by `chromium-args` in nw package, because nw package is initialized after the logging initialization. Fixed nwjs/nw.js#4637
On Windows, logging module is initialized after sandbox creation. But NW package is initialized ealier that that, which causes the creation of `debug.log` no matter if `--enable-logging` or `--disable-logging` is set. The patch moved the initialization of NW package after logging is initialized. The limitation is that logging CLI argument can't be passed by `chromium-args` in nw package, because nw package is initialized after the logging initialization. Fixed nwjs/nw.js#4637
On Windows, logging module is initialized after sandbox creation. But NW package is initialized ealier that that, which causes the creation of `debug.log` no matter if `--enable-logging` or `--disable-logging` is set. The patch moved the initialization of NW package after logging is initialized. The limitation is that logging CLI argument can't be passed by `chromium-args` in nw package, because nw package is initialized after the logging initialization. Fixed nwjs/nw.js#4637
nw::Package was initialized before logging module. Log in constructor will cause creating another log file inaccidentally. Fixed nwjs#4637
nw::Package was initialized before logging module. Log in constructor will cause creating another log file. Fixed nwjs#4637
Looks like this problem returned/is present in current NWJS 0.14.0 rc2, probably a regression or perhaps the current fix in 13 was never applied to 14. |
The fix was merged to the branch for 0.14 after 0.14.0-rc2. It's in the nightly build: http://dl.nwjs.io/live-build/04-07-2016/9e26cf8-4903036-1df60de-98bfcac |
Glad to hear that, I wasn't aware of rc3 yet. |
On Win7x64 sdk0.13.3 and sdk0.14.0rc3 the issue appears to be mostly fixed so far, but error messages are still going through to the debug log and only error messages, nothing else. The one I keep receiving is as follows: [0407/223545:ERROR:image_metadata_extractor.cc(114)] Couldn't load libexif. 126 It is spontaneous and I haven't yet manged to find a way to replicate it for a reproducible case. Don't know if error messages are supose to ignore logging by design, but if they are then this is working as it is suppose to. |
@ghostoy please check the error msg case. debug.log in the binary directory should be able to turn off completely. It should behave as https://www.chromium.org/for-testers/enable-logging |
@rogerwang This logging is because of decoding corrupted image file, for example bad icon provided in But libexif is deprecated in latest Chromium upstream. See https://chromium.googlesource.com/chromium/src/+/cd96b6f874573d7089bf2eb9d54ed53d7469bb56. |
why the log goes to debug.log, not chrome_debug.log in user data dir? |
Every log message created by It happens on Windows only because We can try to init |
libexif is loaded on Windows at start up. When loading failed, it will generate debug.log in the same directory of nw.exe without `--enable-logging`. Ship `libexif.dll` with NW.js will fix this issue. On Mac OS X, it's already shipped with NW.js. On Linux, it loads `libexif.so.12` in system path. Fixed nwjs#4637
This is fixed in git and will be available in the next nightly build. |
libexif is loaded on Windows at start up. When loading failed, it will generate debug.log in the same directory of nw.exe without `--enable-logging`. Ship `libexif.dll` with NW.js will fix this issue. On Mac OS X, it's already shipped with NW.js. On Linux, it loads `libexif.so.12` in system path. Fixed #4637
- Add test for issue nwjs#4637 - This test is passed on v0.13.1 and v0.30.5
- Add test for issue nwjs#4637 - This test is passed on v0.13.1 and v0.30.5
Supposedly the debug.log file should no longer be created by default since 9a4562b
However it keeps creating a debug.log file whenever the app runs. I already tried
"chromium-args": "disable-logging"
and"chromium-args": "--disable-logging"
but the debug.log file keeps being generated.I've only noticed this file because it was reaching an extremely large size. While I can delete it myself periodically or perhaps even create a routine to do it, this is not an ideal behavior for end users.
I did test this with the Normal NWJS version expecting this to be linked to SDK, but the behavior still stands.
Either the debug.log should be disabled unless the user adds the flag to enable it or the opposite, either way as it currently stands the debug.log file cannot be disabled by any means.
NWJS Normal: v0.13.1
OS: Win7x64
The text was updated successfully, but these errors were encountered: