fix(azure-health-deidentification): resolve pylint 4.0.4 compatibility issues#46741
Draft
fix(azure-health-deidentification): resolve pylint 4.0.4 compatibility issues#46741
Conversation
…y issues Agent-Logs-Url: https://github.com/Azure/azure-sdk-for-python/sessions/d180fba8-8b75-4137-af0c-61e316d34682 Co-authored-by: azure-sdk <53356347+azure-sdk@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Update linting for azure-health-deidentification to pylint 4.0.4
fix(azure-health-deidentification): resolve pylint 4.0.4 compatibility issues
May 5, 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.
azure-health-deidentificationhas pylint warnings that will become build failures when pylint 4.0.4 is adopted (2026-07-13). This PR resolves all flagged issues across the source, test, and sample files.Changes
Generated source files
unidiomatic-typecheckto pylint disable directives in_model_base.pyand_utils/model_base.py— these files usetype(None)for annotation inspection (not instance typechecks), so suppression is appropriateTest files
from ... import *) with explicit named importsrandom,datetime,uuid,time,sleep,LROPoller(where not used)devtools_testutils,pytest) → first-party (azure.*)elifafterbreak→if(R1723)raise Exception→raise RuntimeError(W0719)a == x or a == y→a in (x, y)(R1714)Sample files
import os/import uuidbefore first-partyazure.*imports (C0411)f"Tagged Entities:"→"Tagged Entities:"(W1309)DeidentificationOperationTypeimport indeidentify_text_surrogate_async.pyexamples.pyWarning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
centralus-2.in.applicationinsights.azure.com/home/REDACTED/bin/azsdk /home/REDACTED/bin/azsdk ingest-telemetry --client-type copilot-cli --event-type skill_invocation --session-id d180fba8-8b75-4137-af0c-61e316d34682 --skill-name fix-pylint(dns block)pypi.org/home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/bin/python /home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/bin/python /home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/lib/python3.10/site-packages/pip/__pip-REDACTED__.py install --ignore-installed --no-user --prefix /tmp/pip-build-env-58e350ui/overlay --no-warn-script-location --no-binary :none: --only-binary :none: -i REDACTED -- setuptools>=42 wheel(dns block)/home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/bin/python /home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/bin/python /home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/lib/python3.10/site-packages/pip/__pip-REDACTED__.py install --ignore-installed --no-user --prefix /tmp/pip-build-env-s7odzigx/overlay --no-warn-script-location --no-binary :none: --only-binary :none: -i REDACTED -- setuptools>=42 wheel(dns block)/home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/bin/python /home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/bin/python /home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/lib/python3.10/site-packages/pip/__pip-REDACTED__.py install --ignore-installed --no-user --prefix /tmp/pip-build-env-xme479jc/overlay --no-warn-script-location --no-binary :none: --only-binary :none: -i REDACTED -- setuptools>=40.8.0(dns block)pypi.python.org/home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/azure-health-deidentification/.venv_next-pylint/bin/python /home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/azure-health-deidentification/.venv_next-pylint/bin/python /home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/azure-health-deidentification/.venv_next-pylint/lib/python3.10/site-packages/pip/__pip-REDACTED__.py install --ignore-installed --no-user --prefix /tmp/pip-build-env-cucc6nbu/overlay --no-warn-script-location --no-binary :none: --only-binary :none: -i REDACTED --extra-index-url REDACTED -- setuptools>=42 wheel(dns block)/home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/azure-health-deidentification/.venv_next-pylint/bin/python /home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/azure-health-deidentification/.venv_next-pylint/bin/python /home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/azure-health-deidentification/.venv_next-pylint/lib/python3.10/site-packages/pip/__pip-REDACTED__.py install --ignore-installed --no-user --prefix /tmp/pip-build-env-bheekzks/overlay --no-warn-script-location --no-binary :none: --only-binary :none: -i REDACTED --extra-index-url REDACTED -- setuptools>=77.0.3 wheel(dns block)/home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/azure-health-deidentification/.venv_next-pylint/bin/python /home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/azure-health-deidentification/.venv_next-pylint/bin/python /home/REDACTED/work/azure-sdk-for-python/azure-sdk-for-python/.venv/azure-health-deidentification/.venv_next-pylint/lib/python3.10/site-packages/pip/__pip-REDACTED__.py install --ignore-installed --no-user --prefix /tmp/pip-build-env-_nvdu_fd/overlay --no-warn-script-location --no-binary :none: --only-binary :none: -i REDACTED --extra-index-url REDACTED -- setuptools>=77.0.3 wheel(dns block)scanning-api.github.com/home/REDACTED/work/_temp/ghcca-node/node/bin/node /home/REDACTED/work/_temp/ghcca-node/node/bin/node --enable-source-maps /home/REDACTED/work/_temp/copilot-developer-action-main/dist/index.js(dns block)If you need me to access, download, or install something from one of these locations, you can either: