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

Apply variable name regex to module-level names that are reassigned #3585 #10212

Open
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

jacobtylerwalls
Copy link
Member

@jacobtylerwalls jacobtylerwalls commented Feb 1, 2025

Type of Changes

Type
βœ“ πŸ› Bug fix

Description

Closes #3585
Closes #7383

invalid-name now distinguishes module-level names that are assigned only once
from those that are reassigned and now applies --variable-rgx to the latter.

Also, invalid-name is triggered for module-level names for additional types
(e.g. lists and sets).

@jacobtylerwalls jacobtylerwalls added the False Positive 🦟 A message is emitted but nothing is wrong with the code label Feb 1, 2025
@jacobtylerwalls jacobtylerwalls added this to the 4.0.0 milestone Feb 1, 2025
@jacobtylerwalls jacobtylerwalls added False Negative πŸ¦‹ No message is emitted but something is wrong with the code and removed False Positive 🦟 A message is emitted but nothing is wrong with the code labels Feb 1, 2025

This comment has been minimized.

This comment has been minimized.

Copy link

codecov bot commented Feb 1, 2025

Codecov Report

All modified and coverable lines are covered by tests βœ…

Project coverage is 95.84%. Comparing base (12a8747) to head (b2b2afb).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main   #10212   +/-   ##
=======================================
  Coverage   95.84%   95.84%           
=======================================
  Files         175      175           
  Lines       19056    19065    +9     
=======================================
+ Hits        18264    18273    +9     
  Misses        792      792           
Files with missing lines Coverage Ξ”
pylint/checkers/base/name_checker/checker.py 98.66% <100.00%> (+0.02%) ⬆️
pylint/checkers/utils.py 95.75% <100.00%> (+0.01%) ⬆️

This comment has been minimized.

This comment has been minimized.

Copy link
Member

@Pierre-Sassoulas Pierre-Sassoulas left a comment

Choose a reason for hiding this comment

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

This is a great PR ! Deal with one of the major issue with pylint (after the under 3 letters issue that you already tackled before) and greatly improves it.

I'm wondering if we should disable invalid-name on all tests unrelated to invalid-name instead of renaming variables in order to reduce churn ?

@@ -0,0 +1,7 @@
`invalid-name` now distinguishes module-level names that are assigned only once
Copy link
Member

Choose a reason for hiding this comment

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

This should probably be advertised as a breaking change for 4.0, it make sense to do it this way but pylint have been doing it a certain way for so long that "module level as constant" became a convention of a kind. (LOGGER vs logger was not settled last time I checked, admittedly a long time ago).

@jacobtylerwalls
Copy link
Member Author

jacobtylerwalls commented Feb 1, 2025

I'm wondering if we should disable invalid-name on all tests unrelated to invalid-name instead of renaming variables in order to reduce churn ?

I wondered about that also, and I'm open to it (would make the review easier), but it would mean that future changes would not notice regressions in these files. I did find cases that were important to handle by going through these files (functions, lambdas, union types, type vars), and a future contributor might find that just as useful if making changes next time someone asks us to adjust this behavior. WDYT?

@Pierre-Sassoulas
Copy link
Member

Let's not revert then. Another way to 'fix' this would be to authorize both uppercase and snake case for module level variable but not something inconsistant like _UPPER_CamelCase (as seen in the primer). I guess it's a cope out but it does have the advantages to never have false positives. Also if you had a logger and you add a formater to it you won't suddenly have to change the variable name to snake_case. Maybe we could let the user choose to make pylint 'dumber' ? What do you think ?

@jacobtylerwalls
Copy link
Member Author

Right, that's option 2 discussed a few times on the issue.

I'm not sure it's worth the complexity. Too many settings, harder to reason about and customize. Let's just proselytize for --good-names and add logger to the default value. If this is mentioned in the release note then people will πŸ’‘ for their other good names.

This comment has been minimized.

Copy link
Contributor

github-actions bot commented Feb 2, 2025

πŸ€– Effect of this PR on checked open source code: πŸ€–

Effect on astroid:
The following messages are now emitted:

  1. invalid-name:
    Constant name "stdlib_module_names" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/pylint-dev/astroid/blob/6805fa3bf4324bdd6ccb91bb200b59a6bd7a0718/astroid/_backport_stdlib_names.py#L350
  2. invalid-name:
    Constant name "to_code" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/pylint-dev/astroid/blob/6805fa3bf4324bdd6ccb91bb200b59a6bd7a0718/astroid/nodes/as_string.py#L708
  3. invalid-name:
    Constant name "inspected_modules" doesn't conform to '(([A-Z][A-Z0-9_])|(.*))$' pattern*
    https://github.com/pylint-dev/astroid/blob/6805fa3bf4324bdd6ccb91bb200b59a6bd7a0718/astroid/brain/brain_gi.py#L23
  4. invalid-name:
    Constant name "special_methods" doesn't conform to '(([A-Z][A-Z0-9_])|(.*))$' pattern*
    https://github.com/pylint-dev/astroid/blob/6805fa3bf4324bdd6ccb91bb200b59a6bd7a0718/astroid/brain/brain_gi.py#L27

The following messages are no longer emitted:

  1. invalid-name:
    Constant name "prefix" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/pylint-dev/astroid/blob/6805fa3bf4324bdd6ccb91bb200b59a6bd7a0718/astroid/modutils.py#L84

Effect on home-assistant:
The following messages are now emitted:

  1. invalid-name:
    Constant name "_DEPRECATED_Config" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/core.py#L187
  2. invalid-name:
    Constant name "_hass" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/core.py#L273
  3. invalid-name:
    Variable name "SETUP_ORDER_SORT_KEY" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/bootstrap.py#L126
  4. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/nsw_fuel_station/__init__.py#L23
  5. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/api/__init__.py#L71
  6. invalid-name:
    Constant name "BluetoothChange" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/bluetooth/models.py#L10
  7. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/bluetooth/__init__.py#L137
  8. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/nmbs/__init__.py#L19
  9. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/energyzero/__init__.py#L16
  10. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/iron_os/__init__.py#L39
  11. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/lcn/__init__.py#L60
  12. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/openai_conversation/__init__.py#L29
  13. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/demo/__init__.py#L61
  14. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/mealie/__init__.py#L32
  15. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/backup/__init__.py#L66
  16. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/blueprint/__init__.py#L25
  17. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/ping/__init__.py#L22
  18. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/wiz/__init__.py#L48
  19. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/home_connect/__init__.py#L48
  20. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/fully_kiosk/__init__.py#L27
  21. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/thread/__init__.py#L27
  22. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/slack/__init__.py#L31
  23. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/media_extractor/__init__.py#L44
  24. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/usb/__init__.py#L63
  25. invalid-name:
    Constant name "_DEPRECATED_UsbServiceInfo" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/usb/__init__.py#L145
  26. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/tado/__init__.py#L41
  27. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/fritz/__init__.py#L29
  28. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/velbus/__init__.py#L38
  29. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/ps4/__init__.py#L57
  30. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/mjpeg/__init__.py#L19
  31. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/overseerr/__init__.py#L33
  32. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/nfandroidtv/__init__.py#L16
  33. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/dynalite/__init__.py#L17
  34. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/senz/__init__.py#L29
  35. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/qbus/__init__.py#L20
  36. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/unifi/__init__.py#L25
  37. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/trace/__init__.py#L38
  38. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/repairs/__init__.py#L21
  39. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/pushover/__init__.py#L20
  40. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/renault/__init__.py#L17
  41. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/transmission/__init__.py#L116
  42. invalid-name:
    Variable name "CONF_DOWNLOAD_DIR" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/downloader/const.py#L9
  43. invalid-name:
    Variable name "CONF_DOWNLOAD_DIR" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/downloader/const.py#L15
  44. invalid-name:
    Constant name "_DEPRECATED_ZeroconfServiceInfo" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/zeroconf/__init__.py#L115
  45. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/lyric/__init__.py#L32
  46. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/stt/__init__.py#L70
  47. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/easyenergy/__init__.py#L16
  48. invalid-name:
    Variable name "ATTR_LAST_EVENT_TYPE" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/simplisafe/__init__.py#L94
  49. invalid-name:
    Variable name "ATTR_LAST_EVENT_TYPE" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/simplisafe/__init__.py#L95
  50. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/google_generative_ai_conversation/__init__.py#L37
  51. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/media_source/__init__.py#L56
  52. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/persistent_notification/__init__.py#L64
  53. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/hardware/__init__.py#L12
  54. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/tesla_fleet/__init__.py#L61
  55. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/network/__init__.py#L27
  56. invalid-name:
    Variable name "ATTRS_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/universal/media_player.py#L119
  57. invalid-name:
    Variable name "CMD_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/universal/media_player.py#L120
  58. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/otbr/__init__.py#L29
  59. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/browser/__init__.py#L24
  60. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/tag/__init__.py#L55
  61. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/onkyo/__init__.py#L18
  62. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/lametric/__init__.py#L14
  63. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/system_health/__init__.py#L31
  64. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/openhome/__init__.py#L21
  65. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/steamist/__init__.py#L30
  66. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/esphome/__init__.py#L28
  67. invalid-name:
    Constant name "current_connection" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/websocket_api/connection.py#L31
  68. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/websocket_api/__init__.py#L47
  69. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/config/__init__.py#L46
  70. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/yolink/__init__.py#L36
  71. invalid-name:
    Variable name "SIGNAL_ADD_DEFAULT_LINKS" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/insteon/const.py#L102
  72. invalid-name:
    Variable name "SIGNAL_ADD_DEFAULT_LINKS" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/insteon/const.py#L110
  73. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/analytics/__init__.py#L18
  74. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/smartthings/__init__.py#L57
  75. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/mcp_server/__init__.py#L22
  76. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/flux_led/__init__.py#L78
  77. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/netatmo/__init__.py#L55
  78. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/configurator/__init__.py#L54
  79. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/nordpool/__init__.py#L18
  80. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/keyboard/__init__.py#L22
  81. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/anthropic/__init__.py#L16
  82. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/qbittorrent/__init__.py#L35
  83. invalid-name:
    Variable name "ATTR_STREAM_TITLE" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/music_assistant/const.py#L16
  84. invalid-name:
    Variable name "ATTR_STREAM_TITLE" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/music_assistant/const.py#L63
  85. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/music_assistant/__init__.py#L39
  86. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/isal/__init__.py#L11
  87. invalid-name:
    Variable name "MONOTONIC_TIME" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/ibeacon/coordinator.py#L42
  88. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/wake_on_lan/__init__.py#L29
  89. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/discord/__init__.py#L17
  90. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/wled/__init__.py#L28
  91. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/dhcp/__init__.py#L71
  92. invalid-name:
    Constant name "_DEPRECATED_DhcpServiceInfo" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/dhcp/__init__.py#L83
  93. invalid-name:
    Constant name "PLATFORMS_v1" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/hue/bridge.py#L29
  94. invalid-name:
    Constant name "PLATFORMS_v2" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/hue/bridge.py#L30
  95. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/lg_netcast/__init__.py#L14
  96. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/ssdp/__init__.py#L191
  97. invalid-name:
    Constant name "_DEPRECATED_SsdpServiceInfo" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/ssdp/__init__.py#L193
  98. invalid-name:
    Constant name "SsdpChange" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/ssdp/__init__.py#L200
  99. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/homeworks/__init__.py#L52
  100. invalid-name:
    Variable name "ATTR_SOFTWARE_VERSION" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/roomba/vacuum.py#L51
  101. invalid-name:
    Variable name "ATTR_SOFTWARE_VERSION" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/roomba/vacuum.py#L57
  102. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/simplepush/__init__.py#L13
  103. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/homeassistant_hardware/__init__.py#L10
  104. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/file_upload/__init__.py#L32
  105. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/soundtouch/__init__.py#L47
  106. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/deconz/__init__.py#L19
  107. invalid-name:
    Constant name "_type_column_mapping" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/recorder/statistics.py#L1606
  108. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/application_credentials/__init__.py#L65
  109. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/mastodon/__init__.py#L27
  110. invalid-name:
    Constant name "_exception_map" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/bang_olufsen/config_flow.py#L42
  111. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/xbox/__init__.py#L22
  112. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/unifiprotect/__init__.py#L59
  113. invalid-name:
    Constant name "_DEPRECATED_WaterHeaterEntityEntityDescription" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/water_heater/__init__.py#L142
  114. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/netgear_lte/__init__.py#L60
  115. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/screenlogic/__init__.py#L45
  116. invalid-name:
    Variable name "LIGHT_KNX_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/knx/storage/entity_store_schema.py#L212
  117. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/bluesound/__init__.py#L19
  118. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/sun/__init__.py#L27
  119. invalid-name:
    Constant name "unknown_contact" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/fritzbox_callmonitor/base.py#L40
  120. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/xiaomi_aqara/__init__.py#L71
  121. invalid-name:
    Constant name "condition_code_to_hass" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/weatherkit/weather.py#L58
  122. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/doorbird/__init__.py#L31
  123. invalid-name:
    Variable name "DEFAULT_PORT" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/mqtt/const.py#L123
  124. invalid-name:
    Variable name "DEFAULT_RETAIN" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/mqtt/const.py#L124
  125. invalid-name:
    Variable name "DEFAULT_RETAIN" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/mqtt/const.py#L129
  126. invalid-name:
    Variable name "DEFAULT_PORT" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/mqtt/const.py#L139
  127. invalid-name:
    Constant name "_ha_uniqueid_to_sensor_key" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/pvpc_hourly_pricing/helpers.py#L14
  128. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/habitica/__init__.py#L16
  129. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/reolink/__init__.py#L56
  130. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/ohme/__init__.py#L22
  131. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/webhook/__init__.py#L35
  132. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/bluetooth_adapters/__init__.py#L11
  133. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/image_upload/__init__.py#L43
  134. invalid-name:
    Variable name "ATTR_STATUS" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/linux_battery/sensor.py#L35
  135. invalid-name:
    Variable name "ATTR_STATUS" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/linux_battery/sensor.py#L40
  136. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/device_automation/__init__.py#L62
  137. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/tplink/__init__.py#L63
  138. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/blink/__init__.py#L40
  139. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/my/__init__.py#L11
  140. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/homeassistant_alerts/__init__.py#L26
  141. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/diagnostics/__init__.py#L47
  142. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/kitchen_sink/__init__.py#L42
  143. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/auth/__init__.py#L171
  144. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/imap/__init__.py#L49
  145. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/intent/__init__.py#L65
  146. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/color_extractor/__init__.py#L27
  147. invalid-name:
    Constant name "_DEPRECATED_HassioServiceInfo" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/hassio/__init__.py#L141
  148. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/google_mail/__init__.py#L23
  149. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/wake_word/__init__.py#L38
  150. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/default_config/__init__.py#L9
  151. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/homekit_controller/__init__.py#L45
  152. invalid-name:
    Constant name "TessieChargeStates" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/tessie/const.py#L93
  153. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/tibber/__init__.py#L22
  154. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/heos/__init__.py#L20
  155. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/plex/__init__.py#L61
  156. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/onboarding/__init__.py#L28
  157. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/mobile_app/__init__.py#L58
  158. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/trafikverket_camera/__init__.py#L18
  159. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/pushbullet/__init__.py#L28
  160. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/teslemetry/__init__.py#L54
  161. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/broadlink/__init__.py#L16
  162. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/sabnzbd/__init__.py#L50
  163. invalid-name:
    Variable name "ATTR_PARAMETERS" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/zwave_js/const.py#L71
  164. invalid-name:
    Variable name "ATTR_PARAMETERS" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/zwave_js/const.py#L131
  165. invalid-name:
    Variable name "ENABLED" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/zwave_js/api.py#L119
  166. invalid-name:
    Variable name "STATUS" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/zwave_js/api.py#L124
  167. invalid-name:
    Variable name "ENABLED" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/zwave_js/api.py#L127
  168. invalid-name:
    Variable name "STATUS" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/zwave_js/api.py#L171
  169. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/recovery_mode/__init__.py#L10
  170. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/lirc/__init__.py#L24
  171. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/webostv/__init__.py#L32
  172. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/google_assistant_sdk/__init__.py#L55
  173. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/swiss_public_transport/__init__.py#L45
  174. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/abode/__init__.py#L54
  175. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/motionblinds_ble/__init__.py#L44
  176. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/search/__init__.py#L31
  177. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/energy/__init__.py#L15
  178. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/ollama/__init__.py#L40
  179. invalid-name:
    Variable name "CONFIG_SCHEMA" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/components/seventeentrack/__init__.py#L20
  180. invalid-name:
    Constant name "_DEPRECATED_cached_property" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/backports/functools.py#L23
  181. invalid-name:
    Constant name "_DEPRECATED_StrEnum" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/backports/enum.py#L23
  182. invalid-name:
    Constant name "_DEPRECATED_ContextType" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/helpers/typing.py#L57
  183. invalid-name:
    Constant name "_DEPRECATED_EventType" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/helpers/typing.py#L58
  184. invalid-name:
    Constant name "_DEPRECATED_HomeAssistantType" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/helpers/typing.py#L59
  185. invalid-name:
    Constant name "_DEPRECATED_ServiceCallType" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/helpers/typing.py#L60
  186. invalid-name:
    Constant name "_template_context_manager" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/helpers/template.py#L2747
  187. invalid-name:
    Constant name "_hass" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/helpers/config_validation.py#L134
  188. invalid-name:
    Variable name "_HAS_ENTITY_SERVICE_FIELD" doesn't conform to snake_case naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/helpers/config_validation.py#L1337
  189. invalid-name:
    Constant name "_jws" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/auth/jwt_wrapper.py#L41
  190. invalid-name:
    Constant name "_jwt" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/auth/jwt_wrapper.py#L106
  191. invalid-name:
    Constant name "OwnerPermissions" doesn't conform to UPPER_CASE naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/auth/permissions/__init__.py#L83
  192. invalid-name:
    Type alias name "JSON_TYPE" doesn't conform to predefined naming style
    https://github.com/home-assistant/core/blob/dd9bd8ef730dc6ccb33c9363e6ac8591a61fd9de/homeassistant/util/yaml/loader.py#L34

Effect on pygame:
The following messages are now emitted:

  1. invalid-name:
    Constant name "cdrom" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L118
  2. invalid-name:
    Constant name "display" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L123
  3. invalid-name:
    Constant name "draw" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L128
  4. invalid-name:
    Constant name "event" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L133
  5. invalid-name:
    Constant name "image" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L138
  6. invalid-name:
    Constant name "joystick" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L143
  7. invalid-name:
    Constant name "key" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L148
  8. invalid-name:
    Constant name "mouse" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L153
  9. invalid-name:
    Constant name "cursors" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L159
  10. invalid-name:
    Constant name "sprite" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L168
  11. invalid-name:
    Constant name "threads" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L173
  12. invalid-name:
    Constant name "pixelcopy" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L178
  13. invalid-name:
    Constant name "mask" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L194
  14. invalid-name:
    Constant name "time" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L219
  15. invalid-name:
    Constant name "transform" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L224
  16. invalid-name:
    Constant name "font" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L242
  17. invalid-name:
    Constant name "mixer" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L256
  18. invalid-name:
    Constant name "scrap" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L261
  19. invalid-name:
    Constant name "surfarray" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L266
  20. invalid-name:
    Constant name "sndarray" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L271
  21. invalid-name:
    Constant name "fastevent" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__init__.py#L276
  22. invalid-name:
    Constant name "_pixel2d_bitdepths" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/surfarray.py#L69
  23. invalid-name:
    Constant name "_cursor_id_table" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/cursors.py#L40
  24. invalid-name:
    Constant name "arrow" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/cursors.py#L156
  25. invalid-name:
    Constant name "diamond" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/cursors.py#L229
  26. invalid-name:
    Constant name "ball" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/cursors.py#L302
  27. invalid-name:
    Constant name "broken_x" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/cursors.py#L375
  28. invalid-name:
    Constant name "tri_left" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/cursors.py#L448
  29. invalid-name:
    Constant name "tri_right" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/cursors.py#L521
  30. invalid-name:
    Constant name "thickarrow_strings" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/cursors.py#L601
  31. invalid-name:
    Constant name "sizer_x_strings" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/cursors.py#L629
  32. invalid-name:
    Constant name "sizer_y_strings" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/cursors.py#L649
  33. invalid-name:
    Constant name "sizer_xy_strings" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/cursors.py#L677
  34. invalid-name:
    Constant name "textmarker_strings" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/cursors.py#L697
  35. invalid-name:
    Constant name "OpenType_extensions" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/sysfont.py#L35
  36. invalid-name:
    Constant name "Sysfonts" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/sysfont.py#L36
  37. invalid-name:
    Constant name "Sysalias" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/sysfont.py#L37
  38. invalid-name:
    Constant name "datas" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__pyinstaller/hook-pygame.py#L18
  39. invalid-name:
    Constant name "binaries" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/__pyinstaller/hook-pygame.py#L39

The following messages are no longer emitted:

  1. invalid-name:
    Constant name "_ft_init" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/fastevent.py#L13
  2. invalid-name:
    Constant name "_is_init" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/camera.py#L9
  3. invalid-name:
    Constant name "is_init" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/sysfont.py#L39
  4. invalid-name:
    Constant name "_wq" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/threads/__init__.py#L28
  5. invalid-name:
    Constant name "_use_workers" doesn't conform to UPPER_CASE naming style
    https://github.com/pygame/pygame/blob/79807da84c9bacf8df5a177763e14c924e3b15e2/src_py/threads/__init__.py#L31

Effect on black:
The following messages are now emitted:

  1. invalid-name:
    Constant name "TResult" doesn't conform to UPPER_CASE naming style
    https://github.com/psf/black/blob/9c129567e75728e2b9382f4c79bf72ef6beac37e/src/black/trans.py#L54
  2. invalid-name:
    Constant name "_stop_signal" doesn't conform to UPPER_CASE naming style
    https://github.com/psf/black/blob/9c129567e75728e2b9382f4c79bf72ef6beac37e/src/blackd/__init__.py#L27
  3. invalid-name:
    Constant name "opmap" doesn't conform to UPPER_CASE naming style
    https://github.com/psf/black/blob/9c129567e75728e2b9382f4c79bf72ef6beac37e/src/blib2to3/pgen2/grammar.py#L224

Effect on music21:
The following messages are now emitted:

  1. invalid-name:
    Constant name "minPythonVersion" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/__init__.py#L38
  2. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/tinyNotation.py#L253
  3. invalid-name:
    Constant name "stateDictDefault" doesn't conform to '(([A-Z][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/tinyNotation.py#L877
  4. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/volume.py#L33
  5. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/note.py#L50
  6. invalid-name:
    Constant name "noteheadTypeNames" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/note.py#L52
  7. invalid-name:
    Constant name "stemDirectionNames" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/note.py#L83
  8. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/key.py#L40
  9. invalid-name:
    Constant name "fifthsOrder" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/key.py#L157
  10. invalid-name:
    Constant name "modeSharpsAlter" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/key.py#L158
  11. invalid-name:
    Constant name "quantizationQuarterLengthDivisors" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/defaults.py#L91
  12. invalid-name:
    Constant name "abcVersionDefault" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/defaults.py#L113
  13. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/base.py#L109
  14. invalid-name:
    Constant name "missingImport" doesn't conform to '(([A-Z][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/base.py#L111
  15. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/repeat.py#L38
  16. invalid-name:
    Constant name "repeatExpressionReference" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/repeat.py#L403
  17. invalid-name:
    Constant name "environStorage" doesn't conform to '(([A-Z][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/environment.py#L798
  18. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/sieve.py#L73
  19. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/clef.py#L36
  20. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/configure.py#L31
  21. invalid-name:
    Constant name "testInstance" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/configure.py#L1618
  22. invalid-name:
    Constant name "te" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/configure.py#L1619
  23. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/variant.py#L42
  24. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/layout.py#L105
  25. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/instrument.py#L44
  26. invalid-name:
    Constant name "ensembleNamesBySize" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/instrument.py#L1774
  27. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/articulations.py#L93
  28. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/bar.py#L25
  29. invalid-name:
    Constant name "barTypeList" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/bar.py#L35
  30. invalid-name:
    Constant name "barTypeDict" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/bar.py#L41
  31. invalid-name:
    Constant name "reverseBarTypeDict" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/bar.py#L45
  32. invalid-name:
    Constant name "strongBarlineTypes" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/bar.py#L50
  33. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/spanner.py#L38
  34. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/text.py#L26
  35. invalid-name:
    Constant name "articleReference" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/text.py#L35
  36. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/beam.py#L92
  37. invalid-name:
    Constant name "beamableDurationTypes" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/beam.py#L99
  38. invalid-name:
    Constant name "NoneSiteRef" doesn't conform to '(([A-Z][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/sites.py#L173
  39. invalid-name:
    Constant name "singletonCounter" doesn't conform to '(([A-Z][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/sites.py#L177
  40. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/pitch.py#L45
  41. invalid-name:
    Constant name "accidentalNameToModifier" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/pitch.py#L92
  42. invalid-name:
    Constant name "unicodeFromModifier" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/pitch.py#L110
  43. invalid-name:
    Constant name "alternateNameToAccidentalName" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/pitch.py#L126
  44. invalid-name:
    Constant name "accidentalModifiersSorted" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/pitch.py#L164
  45. invalid-name:
    Constant name "environLocal" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/dynamics.py#L27
  46. invalid-name:
    Constant name "shortNames" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/dynamics.py#L30
  47. invalid-name:
    Constant name "longNames" doesn't conform to '(([A-Z_][A-Z0-9_])|(.*))$' pattern*
    https://github.com/cuthbertLab/music21/blob/62b0bf4a0feaee8bc2c7bd55ba9d4b168f232154/music21/dynamics.py#L32
  48. invalid-name:
    *Cons...

This comment was truncated because GitHub allows only 65536 characters in a comment.

This comment was generated for commit dc7f7e7

Copy link
Member

@Pierre-Sassoulas Pierre-Sassoulas left a comment

Choose a reason for hiding this comment

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

Sounds good to me. I was only skimming the functional test change but I found "something", so I'll need a lot more time to actually review it later.

inferred_left = safe_infer(binop.left)
if isinstance(binop.left, nodes.Const):
# This bizarrely became necessary after an unrelated call to igetattr().
# Seems like a code smell uncovered in #10212.
Copy link
Member

Choose a reason for hiding this comment

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

Not sure if I understand what the code smell is here, would you mind explaining a little more ?

Copy link
Member Author

Choose a reason for hiding this comment

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

The fact that I called igetattr() in my PR seemed to cause a cache-creation or cache-eviction side effect somewhere someplace causing a test to fail. It failed in a way where binop.left was already a Const and didn't need to be inferred, so I just handled for it. Debugging the cached side effect sounds like a nightmare, I didn't get that far.

I'd leave a more helpful comment if I could think of one, I'm definitely open to suggestions! Wanted to at least leave some kind of breadcrumb for the next developer.

Comment on lines +23 to +24
ITEM_LIST.append(item)
ITEM_LIST.remove(item)
Copy link
Member

Choose a reason for hiding this comment

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

We're modifying a supposed constant here ? Look like a false negative ?

Copy link
Member Author

Choose a reason for hiding this comment

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

It's still a constant even if it's mutable, right?

Copy link
Member

Choose a reason for hiding this comment

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

I think constants should be immutable but that might be an issue with the definition of what a constant is supposed to be in python (Time to read some PEP I guess?). I think I remember some argument by a user that this message will always have false positives / false negatives because it's "impossible" to know if a python object is an immutable or not. I kinda like the approach of determining if something is a constant if it's reassigned or muted in the actual code regardless of the actual immutable/mutable property of the instance we're analyzing.

Copy link
Member Author

@jacobtylerwalls jacobtylerwalls Feb 2, 2025

Choose a reason for hiding this comment

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

It's a judgment call for sure, but it strikes me as a little fancy to do that much checking. A list that gets appended to a couple times depending on a couple of if conditions at the top of a module is still a constant when another module imports it.

I'm open to other views, so no rush here, but I don't foresee this being much of a problem in practice (other than needing to silence invalid name in situations similar to: in a Django settings.py file (assuming it's even linted):

if DEBUG:
    SILENCED_SYSTEM_CHECKS += [...]

Copy link
Member

Choose a reason for hiding this comment

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

Hmm, now that you say it, I definitely mutate constants in django setting's files. It think I remember django rosetta suggesting this at some point:

if DEBUG:
    INSTALLED_APPS.append("rosetta")

It would be annoying to silence this all the time. (Maybe something for pylint-django to take care off if we choose to go this way.) Let's wait for other opinions to do it. But in any case this MR is already a huge improvement, we could merge as is (and create a discussion issue to be resolved before we release 4.0?).

Copy link
Member

Choose a reason for hiding this comment

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

I was arguing that constants shouldn't be mutated either, if we do the check so that "mutated variable are not constant so they should be snake case" then it would start to be a problem in django settings too.

Copy link
Member Author

Choose a reason for hiding this comment

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

if we do the check so that "mutated variable are not constant so they should be snake case"

Maybe I'm missing what you're saying - I would be against such a check, since I think a mutated constant is still a constant.

Copy link
Member

Choose a reason for hiding this comment

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

Yes we disagree on this. PEP8 is very vague about this, there's no definition of what a constant is. After searching for ~= 15mn I didn't find anything authoritative to support or refute my opinion in the PEP, so I welcome opinion from anyone reading this.

Imo a constant value should not change during the execution of the program. Mutating means it's modified during execution so it contradicts the idea of being a constant. (In the case of django the settings.py is read/executed once for each server launch so it's not wrong to call it a constant after the settings.py is executed and the server is launched).

Copy link
Contributor

Choose a reason for hiding this comment

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

Personally I would be cautious about mutating constants in runtime like what @Pierre-Sassoulas has mentioned, but there seems to be actual use cases as mentioned above (in Django settings).

Since there is no official definition in PEP, I think it all boils down to how strictly we want to treat constants, it could go both ways really. @jacobtylerwalls is probably thinking about constants like how the const keyword works in Javascript? Where a constant declaration cannot be reassigned but can be mutated. At the same time, we have languages like CPP that take it one step further by enforcing immutability on constant objects.

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah, the const keyword in javascript is exactly how I'm thinking about it. Plus, python explicitly has no concept of immutable objects, so "constant" is really more of a shorthand. Maybe it's unfortunate we're discussing the word "constant" at all. That's why I'm preferring to speak about "reassignments".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Breaking changes for 4.0 🦀 False Negative πŸ¦‹ No message is emitted but something is wrong with the code
Projects
None yet
3 participants