Title: gh-133403: Add type annotations to generate_levenshtein_examples.py by sandole · Pull Request #143317 · python/cpython · GitHub
Open Graph Title: gh-133403: Add type annotations to generate_levenshtein_examples.py by sandole · Pull Request #143317 · python/cpython
X Title: gh-133403: Add type annotations to generate_levenshtein_examples.py by sandole · Pull Request #143317 · python/cpython
Description: Summary Added type annotations to Tools/build/generate_levenshtein_examples.py Updated Tools/build/mypy.ini to include the file for strict type checking Updated .github/workflows/mypy.yml to check the file in CI Type annotations added Function parameters and return types for _substitution_cost, levenshtein, and main Variable type annotation for the examples set Added from __future__ import annotations for cleaner syntax Test plan Ran mypy --config-file=Tools/build/mypy.ini Tools/build/generate_levenshtein_examples.py All mypy strict checks pass with no issues This continues the ongoing effort in #133403 to add type checking to more build tools. Issue: gh-133403 📚 Documentation preview 📚: https://cpython-previews--143317.org.readthedocs.build/
Open Graph Description: Summary Added type annotations to Tools/build/generate_levenshtein_examples.py Updated Tools/build/mypy.ini to include the file for strict type checking Updated .github/workflows/mypy.yml to check...
X Description: Summary Added type annotations to Tools/build/generate_levenshtein_examples.py Updated Tools/build/mypy.ini to include the file for strict type checking Updated .github/workflows/mypy.yml to check...
Opengraph URL: https://github.com/python/cpython/pull/143317
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:afbf36c6-00ee-e1f1-5627-0116b0e4661c |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | E730:2ACA91:10A997A:1679AD8:6A544C18 |
| html-safe-nonce | 45792f96e2cd72a8967f173c3c0bb38a826e2d99ff0515459ee7feb9f92b232f |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFNzMwOjJBQ0E5MToxMEE5OTdBOjE2NzlBRDg6NkE1NDRDMTgiLCJ2aXNpdG9yX2lkIjoiNDUyMTI2OTg3MDgwOTc3NDMyIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | fc1cfc75377ac15a0b3352da5ba982a826afbf609f4cbefd8425d827ac1bb5be |
| hovercard-subject-tag | pull_request:3140078700 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,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/python/cpython/pull/143317/files |
| twitter:image | https://avatars.githubusercontent.com/u/39040639?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/39040639?s=400&v=4 |
| og:image:alt | Summary Added type annotations to Tools/build/generate_levenshtein_examples.py Updated Tools/build/mypy.ini to include the file for strict type checking Updated .github/workflows/mypy.yml to check... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | b9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/python/cpython git https://github.com/python/cpython.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 81598961 |
| octolytics-dimension-repository_nwo | python/cpython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 81598961 |
| octolytics-dimension-repository_network_root_nwo | python/cpython |
| turbo-body-classes | logged-out env-production page-responsive full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 07a982c1d40157c619b364352b704c3ce66bb332 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width