Fix pylint 4.0.4#47517
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the azure-monitor-opentelemetry-exporter package (primarily tests, plus one runtime module) to accommodate new/changed Pylint findings in 4.0.4, mostly by removing unused imports and adding targeted # pylint: disable=... pragmas where needed.
Changes:
- Adds/adjusts Pylint suppression pragmas for specific warnings (e.g.,
broad-exception-caught,unused-argument,line-too-long,do-not-use-logging-exception,no-name-in-module). - Cleans up unused imports and tweaks a couple of test names/strings to avoid Pylint complaints.
- Minor formatting change to a logged message string (removing implicit string concatenation).
Reviewed changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| sdk/monitor/azure-monitor-opentelemetry-exporter/tests/trace/test_trace_utils.py | Adds targeted Pylint suppression for fixedint import. |
| sdk/monitor/azure-monitor-opentelemetry-exporter/tests/test_utils.py | Removes unused imports and renames one test for clearer intent. |
| sdk/monitor/azure-monitor-opentelemetry-exporter/tests/test_storage.py | Removes a redundant local import and suppresses a line-length warning on a long comment line. |
| sdk/monitor/azure-monitor-opentelemetry-exporter/tests/test_rate_limiter.py | Suppresses broad-exception-caught for a thread-safety test and removes an unused local import. |
| sdk/monitor/azure-monitor-opentelemetry-exporter/tests/test_gen_ai_processor.py | Removes unused constant imports. |
| sdk/monitor/azure-monitor-opentelemetry-exporter/tests/test_base_exporter.py | Removes an unused import in a test block. |
| sdk/monitor/azure-monitor-opentelemetry-exporter/tests/quickpulse/test_exporter.py | Removes an unused client import and adds targeted suppressions for argument/line-length warnings. |
| sdk/monitor/azure-monitor-opentelemetry-exporter/tests/performance_counters/test_performance_counters.py | Rewrites a string literal to avoid implicit concatenation. |
| sdk/monitor/azure-monitor-opentelemetry-exporter/tests/customer_sdk_stats/test_manager.py | Suppresses unused-argument for patched test parameters. |
| sdk/monitor/azure-monitor-opentelemetry-exporter/azure/monitor/opentelemetry/exporter/_performance_counters/_manager.py | Suppresses do-not-use-logging-exception at a module-init logging site. |
JacksonWeber
approved these changes
Jun 16, 2026
47205b1 to
47db81d
Compare
JacksonWeber
approved these changes
Jun 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
All SDK Contribution checklist:
General Guidelines and Best Practices