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

[flake8-logging] Stabilize root-logger-call (LOG015) #16654

Merged
merged 1 commit into from
Mar 12, 2025

Conversation

ntBre
Copy link
Contributor

@ntBre ntBre commented Mar 12, 2025

Summary

Stabilizes LOG015. The tests and docs looked good.

Test Plan

1 closed documentation issue from 4 days after the rule was added, but no other issues or PRs.

Summary
--

Stabilizes LOG015. The tests and docs looked good.

Test Plan
--

1 closed documentation issue from 4 days after the rule was added, but no other
issues or PRs.
@ntBre ntBre added the rule Implementing or modifying a lint rule label Mar 12, 2025
@ntBre ntBre added this to the v0.10 milestone Mar 12, 2025
Copy link

codspeed-hq bot commented Mar 12, 2025

CodSpeed Performance Report

Merging #16654 will degrade performances by 10.81%

Comparing brent/log015-0.10 (21453fb) with micha/ruff-0.10 (b8f1284)

Summary

❌ 1 regressions
✅ 31 untouched benchmarks

⚠️ Please fix the performance issues or acknowledge them on CodSpeed.

Benchmarks breakdown

Benchmark BASE HEAD Change
red_knot_check_file[incremental] 4.9 ms 5.5 ms -10.81%

Copy link
Contributor

ruff-ecosystem results

Linter (stable)

ℹ️ ecosystem check detected linter changes. (+287 -1 violations, +0 -0 fixes in 4 projects; 51 projects unchanged)

apache/superset (+52 -0 violations, +0 -0 fixes)

ruff check --no-cache --exit-zero --ignore RUF9 --no-fix --output-format concise --no-preview --select ALL

+ superset/migrations/versions/2016-05-27_15-03_1226819ee0e3_fix_wrong_constraint_on_table_columns.py:64:9: LOG015 `warning()` call on root logger
+ superset/migrations/versions/2016-09-15_08-48_65903709c321_allow_dml.py:43:9: LOG015 `exception()` call on root logger
+ superset/migrations/versions/2016-09-22_10-21_3b626e2a6783_sync_db_with_models.py:116:9: LOG015 `warning()` call on root logger
+ superset/migrations/versions/2016-09-22_10-21_3b626e2a6783_sync_db_with_models.py:128:9: LOG015 `warning()` call on root logger
+ superset/migrations/versions/2016-09-22_10-21_3b626e2a6783_sync_db_with_models.py:135:9: LOG015 `warning()` call on root logger
+ superset/migrations/versions/2016-09-22_10-21_3b626e2a6783_sync_db_with_models.py:63:9: LOG015 `warning()` call on root logger
+ superset/migrations/versions/2016-09-22_10-21_3b626e2a6783_sync_db_with_models.py:72:9: LOG015 `warning()` call on root logger
+ superset/migrations/versions/2016-09-22_10-21_3b626e2a6783_sync_db_with_models.py:77:9: LOG015 `warning()` call on root logger
+ superset/migrations/versions/2016-09-22_10-21_3b626e2a6783_sync_db_with_models.py:83:9: LOG015 `warning()` call on root logger
+ superset/migrations/versions/2016-09-22_10-21_3b626e2a6783_sync_db_with_models.py:91:9: LOG015 `warning()` call on root logger
... 42 additional changes omitted for project

bokeh/bokeh (+5 -0 violations, +0 -0 fixes)

ruff check --no-cache --exit-zero --ignore RUF9 --no-fix --output-format concise --no-preview --select ALL

+ scripts/milestone.py:33:9: LOG015 `debug()` call on root logger
+ scripts/milestone.py:41:9: LOG015 `debug()` call on root logger
+ src/bokeh/document/document.py:377:17: LOG015 `warning()` call on root logger
+ src/bokeh/io/notebook.py:581:5: LOG015 `debug()` call on root logger
+ src/bokeh/io/notebook.py:582:5: LOG015 `debug()` call on root logger

rotki/rotki (+0 -1 violations, +0 -0 fixes)

- rotkehlchen/logging.py:66:59: RUF100 [*] Unused `noqa` directive (non-enabled: `LOG015`)

zulip/zulip (+230 -0 violations, +0 -0 fixes)

ruff check --no-cache --exit-zero --ignore RUF9 --no-fix --output-format concise --no-preview --select ALL

+ analytics/views/stats.py:484:13: LOG015 `warning()` call on root logger
+ tools/lib/provision.py:91:5: LOG015 `critical()` call on root logger
+ zerver/actions/create_realm.py:170:9: LOG015 `info()` call on root logger
+ zerver/actions/invites.py:131:5: LOG015 `log()` call on root logger
+ zerver/actions/message_send.py:1923:9: LOG015 `exception()` call on root logger
+ zerver/actions/message_send.py:523:13: LOG015 `error()` call on root logger
+ zerver/actions/realm_settings.py:622:9: LOG015 `warning()` call on root logger
+ zerver/actions/realm_settings.py:742:9: LOG015 `info()` call on root logger
+ zerver/actions/scheduled_messages.py:378:5: LOG015 `info()` call on root logger
+ zerver/actions/scheduled_messages.py:395:17: LOG015 `info()` call on root logger
+ zerver/actions/scheduled_messages.py:400:17: LOG015 `exception()` call on root logger
+ zerver/actions/uploads.py:61:13: LOG015 `warning()` call on root logger
+ zerver/apps.py:12:5: LOG015 `info()` call on root logger
+ zerver/data_import/import_util.py:593:5: LOG015 `info()` call on root logger
+ zerver/data_import/import_util.py:594:5: LOG015 `info()` call on root logger
+ zerver/data_import/import_util.py:625:5: LOG015 `info()` call on root logger
+ zerver/data_import/import_util.py:636:9: LOG015 `exception()` call on root logger
+ zerver/data_import/import_util.py:642:5: LOG015 `info()` call on root logger
+ zerver/data_import/import_util.py:650:17: LOG015 `info()` call on root logger
+ zerver/data_import/import_util.py:674:5: LOG015 `info()` call on root logger
+ zerver/data_import/import_util.py:675:5: LOG015 `info()` call on root logger
+ zerver/data_import/import_util.py:686:5: LOG015 `info()` call on root logger
+ zerver/data_import/import_util.py:727:5: LOG015 `info()` call on root logger
+ zerver/data_import/import_util.py:728:5: LOG015 `info()` call on root logger
+ zerver/data_import/import_util.py:748:13: LOG015 `warning()` call on root logger
+ zerver/data_import/import_util.py:771:5: LOG015 `info()` call on root logger
+ zerver/data_import/mattermost.py:244:17: LOG015 `info()` call on root logger
+ zerver/data_import/mattermost.py:694:9: LOG015 `warning()` call on root logger
+ zerver/data_import/mattermost.py:749:5: LOG015 `info()` call on root logger
+ zerver/data_import/mattermost.py:800:5: LOG015 `info()` call on root logger
+ zerver/data_import/rocketchat.py:271:5: LOG015 `info()` call on root logger
+ zerver/data_import/rocketchat.py:328:5: LOG015 `info()` call on root logger
+ zerver/data_import/rocketchat.py:385:9: LOG015 `info()` call on root logger
+ zerver/data_import/rocketchat.py:389:9: LOG015 `info()` call on root logger
+ zerver/data_import/rocketchat.py:403:9: LOG015 `info()` call on root logger
+ zerver/data_import/rocketchat.py:407:9: LOG015 `info()` call on root logger
+ zerver/data_import/rocketchat.py:656:13: LOG015 `info()` call on root logger
+ zerver/data_import/rocketchat.py:723:17: LOG015 `info()` call on root logger
+ zerver/data_import/rocketchat.py:760:21: LOG015 `info()` call on root logger
... 191 additional changes omitted for project

Changes by rule (2 rules affected)

code total + violation - violation + fix - fix
LOG015 287 287 0 0 0
RUF100 1 0 1 0 0

Linter (preview)

✅ ecosystem check detected no linter changes.

@ntBre
Copy link
Contributor Author

ntBre commented Mar 12, 2025

There's -1 RUF100 violation in the ecosystem results, which actually makes sense. I guess rotki was running on preview and needed the noqa, which caused RUF100 on stable. Now LOG015 is stable and the noqa is no longer unused.

Everything else looks like a true positive to me.

@ntBre ntBre mentioned this pull request Mar 12, 2025
2 tasks
@ntBre ntBre merged commit 406402b into micha/ruff-0.10 Mar 12, 2025
20 of 21 checks passed
@ntBre ntBre deleted the brent/log015-0.10 branch March 12, 2025 12:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rule Implementing or modifying a lint rule
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants