Skip to content

Ensure configured logger severity is respected#35749

Merged
MartinHjelmare merged 2 commits intohome-assistant:devfrom
bdraco:fix_logger_ignores_higher_levels
May 23, 2020
Merged

Ensure configured logger severity is respected#35749
MartinHjelmare merged 2 commits intohome-assistant:devfrom
bdraco:fix_logger_ignores_higher_levels

Conversation

@bdraco
Copy link
Copy Markdown
Member

@bdraco bdraco commented May 17, 2020

Proposed change

If the logger severity was lowered for a module
it was not respected.

Type of change

  • Dependency upgrade
  • Bugfix (non-breaking change which fixes an issue)
  • New integration (thank you!)
  • New feature (which adds functionality to an existing integration)
  • Breaking change (fix/feature causing existing functionality to break)
  • Code quality improvements to existing code or addition of tests

Example entry for configuration.yaml:

# Example configuration.yaml
logger:
  default: debug
  logs:
      custom_components.synology_dsm: debug
      custom_components.zeroconf: critical
      custom_components.gogogate2: debug
      custom_components.homekit: debug
      custom_components.isy994: debug
      PyISY: debug
      pyisy: debug
      PyISY-beta: debug
      pyhap: debug
      custom_components.hunterdouglas_powerview: debug
      aiounifi: debug
      custom_components.unifi: debug
      custom_components.nut: debug
      custom_components.device_tracker.unifi: debug
      custom_components.switch.unifi: debug
      custom_components.tplink: debug
      pyHS100: debug
      python-kasa: debug
      kasa: debug
      custom_components.tado: debug
      custom_components.lutron_caseta: debug
      custom_components.flume: debug
      custom_components.flume: debug
      PyTado: debug
      custom_components.elkm1: debug
      custom_components.harmony: debug
      elkm1: debug
      custom_components.nexia: debug
      custom_components.homekit: debug
      custom_components.nut: debug
      custom_components.rachio: debug
      custom_components.myq: debug
      pylutron-caseta: debug
      pylutron_caseta: debug
      urllib3: debug
      requests: debug
      pymyq: debug
      aioharmony: debug
      aioharmony.harmonyapi: debug
      aioharmony.harmonyclient: debug
      nexia: debug
      custom_components.august: debug
      custom_components.pvpc_hourly_pricing: debug
      homeassistant.components.zeroconf: debug
      homeassistant.components.homekit: debug
      august.api: debug
      august.async_api: debug
      august.api_async: debug
      aiohttp: debug
      custom_components.recorder: debug
      custom_components.isy994: debug
      homeassistant.components.zwave: debug
      custom_components.sense: debug
      custom_components.rachio: debug
      custom_components.august2: debug
      sense_energy: debug
      PyTado: debug
      pytado: debug
      zeroconf: debug
      homeassistant.components.tado: debug
      custom_components.tado: debug
      custom_components.hd_powerview: debug

Additional information

Checklist

  • The code change is tested and works locally.
  • Local tests pass. Your PR cannot be merged unless tests pass
  • There is no commented out code in this PR.
  • I have followed the development checklist
  • The code has been formatted using Black (black --fast homeassistant tests)
  • Tests have been added to verify that the new code works.

If user exposed functionality or configuration variables are added/changed:

If the code communicates with devices, web services, or third-party tools:

  • The manifest file has all fields filled out correctly.
    Updated and included derived files by running: python3 -m script.hassfest.
  • New or updated dependencies have been added to requirements_all.txt.
    Updated by running python3 -m script.gen_requirements_all.
  • Untested files have been added to .coveragerc.

The integration reached or maintains the following Integration Quality Scale:

  • No score or internal
  • 🥈 Silver
  • 🥇 Gold
  • 🏆 Platinum

If the logger severity was lowered for a module
it was not respected.
@probot-home-assistant
Copy link
Copy Markdown

Hey there @home-assistant/core, mind taking a look at this pull request as its been labeled with a integration (logger) you are listed as a codeowner for? Thanks!
(message by CodeOwnersMention)

@bdraco bdraco linked an issue May 17, 2020 that may be closed by this pull request
Copy link
Copy Markdown
Member

@MartinHjelmare MartinHjelmare left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a clean up needed.

Comment thread homeassistant/components/logger/__init__.py Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Logger configuration ineffective logger severity ignored

3 participants