Title: Manage `ignore_missing_imports = true` sections configs automatically · Issue #10044 · python/mypy · GitHub
Open Graph Title: Manage `ignore_missing_imports = true` sections configs automatically · Issue #10044 · python/mypy
X Title: Manage `ignore_missing_imports = true` sections configs automatically · Issue #10044 · python/mypy
Description: Feature When I'm adding typing to an existing project, I encounter many libraries that don't have type hints. The easy solution to suppressing these errors is setting ignore_missing_imports = true, but this is not great. The recommended ...
Open Graph Description: Feature When I'm adding typing to an existing project, I encounter many libraries that don't have type hints. The easy solution to suppressing these errors is setting ignore_missing_imports = true,...
X Description: Feature When I'm adding typing to an existing project, I encounter many libraries that don't have type hints. The easy solution to suppressing these errors is setting ignore_missing_imports...
Opengraph URL: https://github.com/python/mypy/issues/10044
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Manage `ignore_missing_imports = true` sections configs automatically","articleBody":"**Feature**\r\n\r\nWhen I'm adding typing to an existing project, I encounter many libraries that don't have type hints. The _easy_ solution to suppressing these errors is setting `ignore_missing_imports = true`, but this is not great. The recommended solution, assuming you don't want to write your own stubs, is to create separate sections for each such library. This can be cumbersome to create and manage. \r\n\r\nI wrote myself a small tool that generates such configs: https://github.com/indigoviolet/mypy-missing-imports . I think it would be nice for mypy to include something like it, to make the \"recommended\" path easier to follow.\r\n\r\n**Pitch**\r\n\r\nI'm imagining something like\r\n\r\n`mypy --generate-missing-import-configs \u003coptionally, /path/to/mypy.ini>`\r\n\r\nwhich would print out sections for each library identified as a `[import]` error like\r\n\r\n```\r\n[mypy-foo.*]\r\nignore_missing_imports = true\r\n```\r\n\r\nIf passed a configuration file, it would update the corresponding sections in that file.\r\n\r\nI'd be happy to try and add this to mypy if it is useful. ","author":{"url":"https://github.com/indigoviolet","@type":"Person","name":"indigoviolet"},"datePublished":"2021-02-07T01:56:19Z","url":"https://github.com/python/mypy/issues/10044"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:0384cc2e-9faa-9df5-9be0-a075804875c6 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | AA16:1A2F85:4C9A61:67439D:6B002EF8 |
| html-safe-nonce | f75178c733b17827870820f3aebcec8eeadc1d5188b9eb28ce44378b04e465f3 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBQTE2OjFBMkY4NTo0QzlBNjE6Njc0MzlEOjZCMDAyRUY4IiwidmlzaXRvcl9pZCI6IjY0MzAzMjMyODk1OTExMzE4OTYiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 6d80f61099da9c592ada6fdc98136189f499b3cd8622f1a243fad796ce602721 |
| hovercard-subject-tag | issue:802834012 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python/mypy/10044/issue_layout |
| twitter:image | https://opengraph.githubassets.com/e9241640161c5d14fb66612b56003d74ad156857edd5415c2529f0e057c450d1/python/mypy/issues/10044 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/e9241640161c5d14fb66612b56003d74ad156857edd5415c2529f0e057c450d1/python/mypy/issues/10044 |
| og:image:alt | Feature When I'm adding typing to an existing project, I encounter many libraries that don't have type hints. The easy solution to suppressing these errors is setting ignore_missing_imports = true,... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | indigoviolet |
| hostname | github.com |
| expected-hostname | github.com |
| None | 7d0829bbde9e48b2486cb5dd6d147896eb01d32134627091f818958a935ef3f0 |
| turbo-cache-control | no-preview |
| go-import | github.com/python/mypy git https://github.com/python/mypy.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 7053637 |
| octolytics-dimension-repository_nwo | python/mypy |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 7053637 |
| octolytics-dimension-repository_network_root_nwo | python/mypy |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | f3f3a43ca095cdea3abbb394112e971f9fdb94fa |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width