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

azure-synapse-monitoring needs linting updates for pylint version 3.2.7 #39301

Open
azure-sdk opened this issue Jan 19, 2025 · 1 comment
Open
Labels
pylint Service Attention Workflow: This issue is responsible by Azure service team. Synapse

Comments

@azure-sdk
Copy link
Collaborator

azure-sdk commented Jan 19, 2025

ACTION NEEDED: This version of pylint will be merged on 2025-04-14. The build will begin to fail for this library if errors are not fixed.

Library name: azure-synapse-monitoring
Pylint version: 3.2.7
Pylint Build: Link to build (2025-03-30)

Pylint Errors:

2025-03-30T10:20:37.7635270Z ************* Module azure
2025-03-30T10:20:37.7636375Z azure/init.py:1: [C0304(missing-final-newline), ] Final newline missing
2025-03-30T10:20:37.7636905Z ************* Module azure.synapse.init
2025-03-30T10:20:37.7637414Z azure/synapse/init.py:1: [C0304(missing-final-newline), ] Final newline missing
2025-03-30T10:20:37.7637931Z ************* Module azure.synapse.monitoring._configuration
2025-03-30T10:20:37.7638696Z azure/synapse/monitoring/_configuration.py:70: [C0301(line-too-long), ] Line too long (129/120)
2025-03-30T10:20:37.7639325Z azure/synapse/monitoring/_configuration.py:18: [C4760(no-typing-import-in-type-check), ] Do not import from typing inside of TYPE_CHECKING.
2025-03-30T10:20:37.7640022Z azure/synapse/monitoring/_configuration.py:23: [R0902(too-many-instance-attributes), MonitoringClientConfiguration] Too many instance attributes (13/10)
2025-03-30T10:20:37.7640732Z azure/synapse/monitoring/_configuration.py:35: [C4761(do-not-use-legacy-typing), MonitoringClientConfiguration.init] Do not use legacy typing using comments.
2025-03-30T10:20:37.7641887Z azure/synapse/monitoring/_configuration.py:55: [C4761(do-not-use-legacy-typing), MonitoringClientConfiguration._configure] Do not use legacy typing using comments.
2025-03-30T10:20:37.7642711Z ************* Module azure.synapse.monitoring._monitoring_client
2025-03-30T10:20:37.7643297Z azure/synapse/monitoring/_monitoring_client.py:16: [C4760(no-typing-import-in-type-check), ] Do not import from typing inside of TYPE_CHECKING.
2025-03-30T10:20:37.7644035Z azure/synapse/monitoring/_monitoring_client.py:19: [C4756(no-legacy-azure-core-http-response-import), ] Do not import HttpResponse from azure.core.pipeline.transport outside of Azure Core.
2025-03-30T10:20:37.7644907Z azure/synapse/monitoring/_monitoring_client.py:21: [C0413(wrong-import-position), ] Import "from ._configuration import MonitoringClientConfiguration" should be placed at the top of the module
2025-03-30T10:20:37.7645702Z azure/synapse/monitoring/_monitoring_client.py:22: [C0413(wrong-import-position), ] Import "from .operations import MonitoringOperations" should be placed at the top of the module
2025-03-30T10:20:37.7646452Z azure/synapse/monitoring/_monitoring_client.py:23: [C0413(wrong-import-position), ] Import "from . import models" should be placed at the top of the module
2025-03-30T10:20:37.7647405Z azure/synapse/monitoring/_monitoring_client.py:26: [C4748(client-accepts-api-version-keyword), MonitoringClient] The client constructor needs to take in an optional keyword-only api_version argument. See details: https://azure.github.io/azure-sdk/python_design.html#specifying-the-service-version
2025-03-30T10:20:37.7648307Z azure/synapse/monitoring/_monitoring_client.py:37: [C4761(do-not-use-legacy-typing), MonitoringClient.init] Do not use legacy typing using comments.
2025-03-30T10:20:37.7649344Z azure/synapse/monitoring/_monitoring_client.py:56: [C4758(docstring-keyword-should-match-keyword-only), MonitoringClient._send_request] "stream" missing in docstring or in method signature. There should be a direct correlation between :keyword: arguments in the docstring and keyword-only arguments in method signature. See details: https://azure.github.io/azure-sdk/python_documentation.html#docstrings
2025-03-30T10:20:37.7650413Z azure/synapse/monitoring/_monitoring_client.py:56: [C4761(do-not-use-legacy-typing), MonitoringClient._send_request] Do not use legacy typing using comments.
2025-03-30T10:20:37.7651349Z azure/synapse/monitoring/_monitoring_client.py:71: [W0212(protected-access), MonitoringClient._send_request] Access to a protected member _pipeline of a client class
2025-03-30T10:20:37.7652068Z azure/synapse/monitoring/_monitoring_client.py:74: [C4761(do-not-use-legacy-typing), MonitoringClient.close] Do not use legacy typing using comments.
2025-03-30T10:20:37.7652782Z azure/synapse/monitoring/_monitoring_client.py:78: [C4761(do-not-use-legacy-typing), MonitoringClient.enter] Do not use legacy typing using comments.
2025-03-30T10:20:37.7653501Z azure/synapse/monitoring/_monitoring_client.py:83: [C4761(do-not-use-legacy-typing), MonitoringClient.exit] Do not use legacy typing using comments.
2025-03-30T10:20:37.7654259Z azure/synapse/monitoring/_monitoring_client.py:12: [C0411(wrong-import-order), ] third party import "msrest.Deserializer" should be placed before first party import "azure.core.PipelineClient"
2025-03-30T10:20:37.7654913Z ************* Module azure.synapse.monitoring.operations._monitoring_operations
2025-03-30T10:20:37.7655538Z azure/synapse/monitoring/operations/_monitoring_operations.py:11: [C0301(line-too-long), ] Line too long (133/120)
2025-03-30T10:20:37.7656156Z azure/synapse/monitoring/operations/_monitoring_operations.py:84: [C0301(line-too-long), ] Line too long (137/120)
2025-03-30T10:20:37.7656865Z azure/synapse/monitoring/operations/_monitoring_operations.py:156: [C0301(line-too-long), ] Line too long (137/120)
2025-03-30T10:20:37.7657633Z azure/synapse/monitoring/operations/_monitoring_operations.py:13: [C4756(no-legacy-azure-core-http-response-import), ] Do not import HttpResponse from azure.core.pipeline.transport outside of Azure Core.
2025-03-30T10:20:37.7658688Z azure/synapse/monitoring/operations/_monitoring_operations.py:19: [C4760(no-typing-import-in-type-check), ] Do not import from typing inside of TYPE_CHECKING.
2025-03-30T10:20:37.7659849Z azure/synapse/monitoring/operations/_monitoring_operations.py:46: [C4758(docstring-keyword-should-match-keyword-only), MonitoringOperations.get_spark_job_list] "cls" missing in docstring or in method signature. There should be a direct correlation between :keyword: arguments in the docstring and keyword-only arguments in method signature. See details: https://azure.github.io/azure-sdk/python_documentation.html#docstrings
2025-03-30T10:20:37.7661099Z azure/synapse/monitoring/operations/_monitoring_operations.py:46: [C4761(do-not-use-legacy-typing), MonitoringOperations.get_spark_job_list] Do not use legacy typing using comments.
2025-03-30T10:20:37.7661950Z azure/synapse/monitoring/operations/_monitoring_operations.py:88: [W0212(protected-access), MonitoringOperations.get_spark_job_list] Access to a protected member _pipeline of a client class
2025-03-30T10:20:37.7663225Z azure/synapse/monitoring/operations/_monitoring_operations.py:103: [C4758(docstring-keyword-should-match-keyword-only), MonitoringOperations.get_sql_job_query_string] "cls" missing in docstring or in method signature. There should be a direct correlation between :keyword: arguments in the docstring and keyword-only arguments in method signature. See details: https://azure.github.io/azure-sdk/python_documentation.html#docstrings
2025-03-30T10:20:37.7664497Z azure/synapse/monitoring/operations/_monitoring_operations.py:103: [C4761(do-not-use-legacy-typing), MonitoringOperations.get_sql_job_query_string] Do not use legacy typing using comments.
2025-03-30T10:20:37.7665385Z azure/synapse/monitoring/operations/_monitoring_operations.py:160: [W0212(protected-access), MonitoringOperations.get_sql_job_query_string] Access to a protected member _pipeline of a client class
2025-03-30T10:20:37.7666144Z azure/synapse/monitoring/operations/_monitoring_operations.py:9: [W0611(unused-import), ] Unused import warnings
2025-03-30T10:20:37.7666732Z ************* Module azure.synapse.monitoring.models._models
2025-03-30T10:20:37.7667355Z azure/synapse/monitoring/models/_models.py:12: [R0902(too-many-instance-attributes), SparkJob] Too many instance attributes (15/10)
2025-03-30T10:20:37.7668210Z ************* Module azure.synapse.monitoring.models._models_py3
2025-03-30T10:20:37.7668829Z azure/synapse/monitoring/models/_models_py3.py:15: [R0902(too-many-instance-attributes), SparkJob] Too many instance attributes (15/10)
2025-03-30T10:20:37.7669441Z ************* Module azure.synapse.monitoring.aio._configuration
2025-03-30T10:20:37.7670002Z azure/synapse/monitoring/aio/_configuration.py:66: [C0301(line-too-long), ] Line too long (134/120)
2025-03-30T10:20:37.7670714Z azure/synapse/monitoring/aio/_configuration.py:21: [R0902(too-many-instance-attributes), MonitoringClientConfiguration] Too many instance attributes (13/10)
2025-03-30T10:20:37.7671380Z ************* Module azure.synapse.monitoring.aio._monitoring_client
2025-03-30T10:20:37.7672051Z azure/synapse/monitoring/aio/_monitoring_client.py:12: [C4756(no-legacy-azure-core-http-response-import), ] Do not import HttpResponse from azure.core.pipeline.transport outside of Azure Core.
2025-03-30T10:20:37.7672898Z azure/synapse/monitoring/aio/_monitoring_client.py:19: [C0413(wrong-import-position), ] Import "from ._configuration import MonitoringClientConfiguration" should be placed at the top of the module
2025-03-30T10:20:37.7673725Z azure/synapse/monitoring/aio/_monitoring_client.py:20: [C0413(wrong-import-position), ] Import "from .operations import MonitoringOperations" should be placed at the top of the module
2025-03-30T10:20:37.7674514Z azure/synapse/monitoring/aio/_monitoring_client.py:21: [C0413(wrong-import-position), ] Import "from .. import models" should be placed at the top of the module
2025-03-30T10:20:37.7675642Z azure/synapse/monitoring/aio/_monitoring_client.py:24: [C4748(client-accepts-api-version-keyword), MonitoringClient] The client constructor needs to take in an optional keyword-only api_version argument. See details: https://azure.github.io/azure-sdk/python_design.html#specifying-the-service-version
2025-03-30T10:20:37.8718969Z azure/synapse/monitoring/aio/_monitoring_client.py:53: [C4758(docstring-keyword-should-match-keyword-only), MonitoringClient._send_request] "stream" missing in docstring or in method signature. There should be a direct correlation between :keyword: arguments in the docstring and keyword-only arguments in method signature. See details: https://azure.github.io/azure-sdk/python_documentation.html#docstrings
2025-03-30T10:20:37.8720949Z azure/synapse/monitoring/aio/_monitoring_client.py:67: [W0212(protected-access), MonitoringClient._send_request] Access to a protected member _pipeline of a client class
2025-03-30T10:20:37.8722403Z azure/synapse/monitoring/aio/_monitoring_client.py:13: [C0411(wrong-import-order), ] third party import "msrest.Deserializer" should be placed before first party imports "azure.core.AsyncPipelineClient", "azure.core.pipeline.transport.AsyncHttpResponse"
2025-03-30T10:20:37.8723405Z ************* Module azure.synapse.monitoring.aio.operations._monitoring_operations
2025-03-30T10:20:37.8724103Z azure/synapse/monitoring/aio/operations/_monitoring_operations.py:11: [C0301(line-too-long), ] Line too long (133/120)
2025-03-30T10:20:37.8724830Z azure/synapse/monitoring/aio/operations/_monitoring_operations.py:79: [C0301(line-too-long), ] Line too long (137/120)
2025-03-30T10:20:37.8725598Z azure/synapse/monitoring/aio/operations/_monitoring_operations.py:150: [C0301(line-too-long), ] Line too long (137/120)
2025-03-30T10:20:37.8726542Z azure/synapse/monitoring/aio/operations/_monitoring_operations.py:13: [C4756(no-legacy-azure-core-http-response-import), ] Do not import HttpResponse from azure.core.pipeline.transport outside of Azure Core.
2025-03-30T10:20:37.8727728Z azure/synapse/monitoring/aio/operations/_monitoring_operations.py:42: [C4758(docstring-keyword-should-match-keyword-only), MonitoringOperations.get_spark_job_list] "cls" missing in docstring or in method signature. There should be a direct correlation between :keyword: arguments in the docstring and keyword-only arguments in method signature. See details: https://azure.github.io/azure-sdk/python_documentation.html#docstrings
2025-03-30T10:20:37.8729158Z azure/synapse/monitoring/aio/operations/_monitoring_operations.py:83: [W0212(protected-access), MonitoringOperations.get_spark_job_list] Access to a protected member _pipeline of a client class
2025-03-30T10:20:37.8729907Z azure/synapse/monitoring/aio/operations/_monitoring_operations.py:98: [C4758(docstring-keyword-should-match-keyword-only), MonitoringOperations.get_sql_job_query_string] "cls" missing in docstring or in method signature. There should be a direct correlation between :keyword: arguments in the docstring and keyword-only arguments in method signature. See details: https://azure.github.io/azure-sdk/python_documentation.html#docstrings
2025-03-30T10:20:37.8730631Z azure/synapse/monitoring/aio/operations/_monitoring_operations.py:154: [W0212(protected-access), MonitoringOperations.get_sql_job_query_string] Access to a protected member _pipeline of a client class
2025-03-30T10:20:37.8731126Z azure/synapse/monitoring/aio/operations/_monitoring_operations.py:8: [W0611(unused-import), ] Unused Generic imported from typing
2025-03-30T10:20:37.8731568Z azure/synapse/monitoring/aio/operations/_monitoring_operations.py:9: [W0611(unused-import), ] Unused import warnings
2025-03-30T10:20:37.8731780Z
2025-03-30T10:20:37.8732139Z ------------------------------------------------------------------
2025-03-30T10:20:37.8732512Z Your code has been rated at 8.50/10 (previous run: 7.88/10, +0.62)
2025-03-30T10:20:37.8732678Z
2025-03-30T10:20:38.8316831Z

How to fix:
Note: If you are a bot. Fix the issue by fixing the above pylint errors.
Run the next-pylint tox command at the library package-level and resolve the linting errors.

  1. ../azure-synapse-monitoring>pip install "tox<5"
  2. ../azure-synapse-monitoring>tox run -e next-pylint -c ../../../eng/tox/tox.ini --root .

See the Pylint Guide for more information.

@kristapratico kristapratico added the Service Attention Workflow: This issue is responsible by Azure service team. label Jan 21, 2025
Copy link

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @wanyang7 @zesluo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pylint Service Attention Workflow: This issue is responsible by Azure service team. Synapse
Projects
None yet
Development

No branches or pull requests

2 participants