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

WIP: Reduce logspam #1772

Closed
wants to merge 31 commits into from
Closed

WIP: Reduce logspam #1772

wants to merge 31 commits into from

Commits on Jul 3, 2018

  1. Don't warn about missing theme icons

    This is a completely normal condition when running in the AppImage
    container, so it just amounts to unnecessary logspam.
    ferdnyc committed Jul 3, 2018
    Configuration menu
    Copy the full SHA
    49c6ce5 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ad550e1 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    cbd6452 View commit details
    Browse the repository at this point in the history
  4. Remove app.py logspam

    Don't log attempt to set font, just failure
    Don't log when setting dark theme
    Convert "Processing command-line arguments:" into debug message
    ferdnyc committed Jul 3, 2018
    Configuration menu
    Copy the full SHA
    34fb6e5 View commit details
    Browse the repository at this point in the history
  5. Eliminate language.py logspam

    Don't log confusing "Skipping English..." message
    Don't log _attempts_ to load translators
    Log successful attempts as debug messages
    ferdnyc committed Jul 3, 2018
    Configuration menu
    Copy the full SHA
    3f453de View commit details
    Browse the repository at this point in the history
  6. Reduce project_data.py logspam

    Don't always log versions from project file in `upgrade_project_data_structures()`, only log when upgrade paths are taken.
    Don't spew generic message whenever files contain temp blender paths.
    Updated file-recovery output to be more informative
    Replaced some %-formatted strings in log messages with .format() strings
    ferdnyc committed Jul 3, 2018
    Configuration menu
    Copy the full SHA
    2b88cea View commit details
    Browse the repository at this point in the history
  7. Reduce timeline.py logspam

    Don't log every time the preview is resized
    Promote "Error applying JSON to timeline..." messages from info to error
    ferdnyc committed Jul 3, 2018
    Configuration menu
    Copy the full SHA
    e55a17c View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    1d5f6f0 View commit details
    Browse the repository at this point in the history

Commits on Jul 5, 2018

  1. Add qt_debug() method to webview

    This will allow some log messages in Angular source to be reduced from
    `log.info()` to `log.debug()` priority
    ferdnyc committed Jul 5, 2018
    Configuration menu
    Copy the full SHA
    2489c8c View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    be88a3b View commit details
    Browse the repository at this point in the history

Commits on Jul 13, 2018

  1. Configuration menu
    Copy the full SHA
    ee031f4 View commit details
    Browse the repository at this point in the history

Commits on Jul 15, 2018

  1. Revert "Eliminate language.py logspam"

    This reverts commit 3f453de.
    ferdnyc committed Jul 15, 2018
    Configuration menu
    Copy the full SHA
    2628f49 View commit details
    Browse the repository at this point in the history

Commits on Jul 16, 2018

  1. Eliminate blender logspam

    ferdnyc committed Jul 16, 2018
    Configuration menu
    Copy the full SHA
    68e7762 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    a94a2a4 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    b7fe39c View commit details
    Browse the repository at this point in the history
  4. Slash properties_model logspam

    Nearly every message is reduced from 'info' to 'debug', some
    redundant/low-information logs are eliminated, and a new, terse
    (but actually more informative) standard formatting for messages
    is introduced and applied to as many log messages as possible.
    ferdnyc committed Jul 16, 2018
    Configuration menu
    Copy the full SHA
    55960df View commit details
    Browse the repository at this point in the history
  5. Reduce file-view logspam

    * Deleted "flow" checkpoints which logged no data (e.g.)
    
       ```python3
       log.info('currentChanged')
       log.info('updateSelection')
       ```
    
    * Reduced most other messages to `log.debug()`
    ferdnyc committed Jul 16, 2018
    Configuration menu
    Copy the full SHA
    aca582d View commit details
    Browse the repository at this point in the history
  6. Extensive reduction of main_window.py logspam

    * Deleted _numerous_ blocks of program-flow debug printfs, like:
    
       ```python3
       if result == QDialog.Accepted:
           log.info('Import image sequence add confirmed')
       else:
           log.info('Import image sequence add cancelled')
    
       # Or, every time a callback fires...
       log.info('actionRedo_trigger')
       ```
    
    * Many "checkpoint" messages removed or reduced to `log.debug`
       * Where possible, checkpoint messages that logged every time
         through a loop were replaced with more informative messages
         that only log under interesting conditions, letting the
         uninteresting loop iterations pass silently
    
    * Remaining useful `log.info()` messages formatted to contain more
      information, log more tersely (sometimes combining two or three
      consecutive messages into a single, concise form
    
    * Made `keyPressEvent` log messages debug-only
    ferdnyc committed Jul 16, 2018
    Configuration menu
    Copy the full SHA
    2da62a1 View commit details
    Browse the repository at this point in the history
  7. Don't attempt to log info we don't have

    I got a little too ambitious beefing up one of the messages in
    `properties_model.py`
    ferdnyc committed Jul 16, 2018
    Configuration menu
    Copy the full SHA
    f1aa1e9 View commit details
    Browse the repository at this point in the history
  8. Reduce preferences logspam

    Every message is reduced to `log.debug()` _except_ the one about
    changing the debug mode.
    
    All debug messages are formatted with useful context, so...
    
    ```python3
    log.info(value)
    log.debug('{} set to {}'.format(param["setting"], value))
    ```
    ferdnyc committed Jul 16, 2018
    Configuration menu
    Copy the full SHA
    8ab08ea View commit details
    Browse the repository at this point in the history
  9. Reduce Angular logspam

    All `qt_log()` messages in the angular code are replaced with
    `qt_debug()` which only logs in debug mode.
    ferdnyc committed Jul 16, 2018
    Configuration menu
    Copy the full SHA
    cfc4cf9 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    d4839f6 View commit details
    Browse the repository at this point in the history
  11. Reduce tutorial logspam

    ferdnyc committed Jul 16, 2018
    Configuration menu
    Copy the full SHA
    e4edbf7 View commit details
    Browse the repository at this point in the history
  12. Reduce project_data logspam

    ferdnyc committed Jul 16, 2018
    Configuration menu
    Copy the full SHA
    2b4e994 View commit details
    Browse the repository at this point in the history
  13. Add debug logging level to logfile (only)

    This commit enables something I've been working towards for some
    time now: The ability to configure OpenShot's console output and
    logfile output to different logging levels, with potentially _more_
    messages being logged to the logfile than are shown on the console.
    
    As a result, it brings all of the following:
    * Log messages of level INFO or higher are written to the console
      log
    * By default, initially the same messages are written to the
      logfile as well
    * The `debug-mode` preference now affects openshot-qt's own logging,
      as well as the libopenshot proxy logging. When `debug-mode` is
      switched on, the `openshot-qt.log` file will receive all messages
      of level DEBUG or higher.
    * Log messages proxied from libopenshot are now logged at level
      DEBUG, instead of INFO, so that they will be written to the
      log file (only if `debug-mode` is on), but will not be printed
      to the console output.
    
    This opens up the possibility of adding a second ZeroMQ logging
    channel for messages at a _higher_ severity than debug, which
    would always be active rather than being gated by the `debug-mode`
    switch. That priority logging channel could be used for messages
    which openshot should always log, such as error messages. This
    would be a possible means of addressing OpenShot#1450.
    ferdnyc committed Jul 16, 2018
    Configuration menu
    Copy the full SHA
    e21cda7 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    57d838a View commit details
    Browse the repository at this point in the history

Commits on Jul 17, 2018

  1. Configuration menu
    Copy the full SHA
    fd811e3 View commit details
    Browse the repository at this point in the history
  2. Some main_window.py fixup

    ferdnyc committed Jul 17, 2018
    Configuration menu
    Copy the full SHA
    370c00d View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    e57b9b2 View commit details
    Browse the repository at this point in the history
  4. Reduce preview_thread logspam

    ferdnyc committed Jul 17, 2018
    Configuration menu
    Copy the full SHA
    b2d137f View commit details
    Browse the repository at this point in the history

Commits on Jul 19, 2018

  1. Configuration menu
    Copy the full SHA
    4432292 View commit details
    Browse the repository at this point in the history