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

mypy-next pylint-next and mypy samples #40155

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

Conversation

kshitij-microsoft
Copy link
Member

Description

Please add an informative description that covers that changes made by the pull request and link all relevant issues.

If an SDK is being regenerated based on a new swagger spec, a link to the pull request containing these swagger spec changes has been included above.

All SDK Contribution checklist:

  • The pull request does not introduce [breaking changes]
  • CHANGELOG is updated for new features, bug fixes or other significant changes.
  • I have read the contribution guidelines.

General Guidelines and Best Practices

  • Title of the pull request is clear and informative.
  • There are a small number of commits, each of which have an informative message. This means that previously merged commits do not appear in the history of the PR. For more information on cleaning up the commits in your PR, see this page.

Testing Guidelines

  • Pull request includes test coverage for the included changes.

@Copilot Copilot bot review requested due to automatic review settings March 20, 2025 09:46

Choose a reason for hiding this comment

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

Pull Request Overview

This pull request updates several sample files with type ignore annotations and improves type annotations in credential and compute operations, while also changing some configuration values.

  • Added "#type:ignore" comments to suppress type checking warnings in sample code.
  • Changed certain configuration values from numeric to string representations.
  • Updated type annotations in credential and compute-related functions.

Reviewed Changes

Copilot reviewed 13 out of 13 changed files in this pull request and generated no comments.

Show a summary per file
File Description
sdk/ml/azure-ai-ml/samples/ml_samples_workspace.py Added "#type:ignore" for hub operations sample code.
sdk/ml/azure-ai-ml/samples/ml_samples_spark_configurations.py Updated Spark configuration values and added "#type:ignore" annotations.
sdk/ml/azure-ai-ml/azure/ai/ml/operations/_model_operations.py Minor type ignore additions.
sdk/ml/azure-ai-ml/samples/ml_samples_genAI_monitors_configuration.py Added "#type:ignore" annotation for monitoring signals.
sdk/ml/azure-ai-ml/samples/ml_samples_capability_host.py Added "#type:ignore" annotations to capability host list operations.
sdk/ml/azure-ai-ml/samples/ml_samples_misc.py Added "#type:ignore" in load_job and ModelPackage usage; updated logging_level type.
sdk/ml/azure-ai-ml/samples/ml_samples_compute.py Added "#type:ignore" in SSH settings instantiations.
sdk/ml/azure-ai-ml/samples/ml_samples_sweep_configurations.py Added "#type:ignore" annotations for inputs dictionary entries.
sdk/ml/azure-ai-ml/azure/ai/ml/entities/_compute/aml_compute.py Simplified disableLocalAuth assignment.
sdk/ml/azure-ai-ml/samples/ml_samples_cloud_configurations.py Added "#type:ignore" for cloud config keyword args.
sdk/ml/azure-ai-ml/samples/ml_samples_pipeline_job_configurations.py Added "#type:ignore" after the pipeline decorator.
sdk/ml/azure-ai-ml/azure/ai/ml/identity/_credentials/aml_on_behalf_of.py & _aio/_credentials/aml_on_behalf_of.py Enhanced type annotations on credential methods.
Comments suppressed due to low confidence (2)

sdk/ml/azure-ai-ml/samples/ml_samples_spark_configurations.py:119

  • Ensure that converting the value for 'spark.driver.cores' from an integer to a string is intended, as the API might expect a numeric type.
"spark.driver.cores": "2",

sdk/ml/azure-ai-ml/samples/ml_samples_misc.py:135

  • Verify that changing 'logging_level' from an integer to a string is compatible with its expected usage, since this modification might affect logging configurations downstream.
logging_level="1",
@azure-sdk
Copy link
Collaborator

API change check

API changes are not detected in this pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants