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

Run mypy in Key Vault CI #19158

Closed
4 tasks done
chlowell opened this issue Jun 8, 2021 · 3 comments
Closed
4 tasks done

Run mypy in Key Vault CI #19158

chlowell opened this issue Jun 8, 2021 · 3 comments
Assignees
Labels
Client This issue points to a problem in the data-plane of the library. KeyVault

Comments

@chlowell
Copy link
Member

chlowell commented Jun 8, 2021

Fix current errors and add packages to mypy_hard_failure_packages.py:

@chlowell chlowell added KeyVault Client This issue points to a problem in the data-plane of the library. labels Jun 8, 2021
@chlowell chlowell added this to the Backlog milestone Jun 8, 2021
@mccoyp mccoyp modified the milestones: Backlog, [2021] July Jun 23, 2021
@mccoyp mccoyp modified the milestones: [2021] July, [2021] August Jul 7, 2021
@mccoyp mccoyp modified the milestones: [2021] August, [2021] September Aug 3, 2021
@mccoyp
Copy link
Member

mccoyp commented Aug 19, 2021

For reference: to run mypy for a package (e.g. azure-keyvault-certificates), run
mypy --exclude _generated --ignore-missing azure
from the top of the package -- in this case, from azure-sdk-for-python/sdk/keyvault/azure-keyvault-certificates

@mccoyp mccoyp removed their assignment Aug 30, 2021
@mccoyp
Copy link
Member

mccoyp commented Sep 1, 2021

Steps to resolve:

For each package:

  1. Run mypy check
  2. Resolve warnings
  3. Once there are no warnings, add package to hard failures file
  4. Include a mypy.ini at the package root that tells mypy to ignore generated files. For example:
[mypy]
python_version = 3.6
warn_unused_configs = True
ignore_missing_imports = True

[mypy-azure.keyvault.*._generated.*]
ignore_errors = True

@YalinLi0312
Copy link
Member

Fixed.

azure-sdk pushed a commit to azure-sdk/azure-sdk-for-python that referenced this issue May 20, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Apr 11, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Client This issue points to a problem in the data-plane of the library. KeyVault
Projects
None yet
Development

No branches or pull requests

3 participants