Title: Testing third-party stubs in isolated environments · Issue #5952 · python/typeshed · GitHub
Open Graph Title: Testing third-party stubs in isolated environments · Issue #5952 · python/typeshed
X Title: Testing third-party stubs in isolated environments · Issue #5952 · python/typeshed
Description: At the moment, whenever there is change to typeshed, we test all stdlib and third-party packages in the same testing environment, using the --custom-typeshed-dir so that all packages can see each other. There are several practical proble...
Open Graph Description: At the moment, whenever there is change to typeshed, we test all stdlib and third-party packages in the same testing environment, using the --custom-typeshed-dir so that all packages can see each o...
X Description: At the moment, whenever there is change to typeshed, we test all stdlib and third-party packages in the same testing environment, using the --custom-typeshed-dir so that all packages can see each o...
Opengraph URL: https://github.com/python/typeshed/issues/5952
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Testing third-party stubs in isolated environments","articleBody":"At the moment, whenever there is change to typeshed, we test all stdlib and third-party packages in the same testing environment, using the `--custom-typeshed-dir` so that all packages can see each other. There are several practical problems with that:\r\n\r\n* We can't test the `requires` fields for correctness; all packages are always available.\r\n* We can't have packages that depend on external packages, see for example #5768, #5618, #5847, and the discussion in #5769 (all related to `cryptography`). (Except if we'd just install all non-types dependencies for all package into our venv.)\r\n* It doesn't scale if we increase the number of third-party packages in typeshed.\r\n* Ideas like per-package configuration is not possible at the moment, see for example #1526.\r\n\r\nMy suggestion: Only run the tests for the third-party stubs that have actually changed, and run each test in a separate environment. This environment only has the requirements from `METADATA.toml` installed. This fixes the problems above and also means:\r\n\r\n* The stubs will not be able to use features from stdlib that are not yet in the latest type checker distributions.\r\n* Changes that depend on changes in another third-party stub need to wait until that change has been released. (Happens every three hours, so it shouldn't be too much of a problem.)\r\n* Running the tests for all stubs will be slower, since each package needs its own venv installation.","author":{"url":"https://github.com/srittau","@type":"Person","name":"srittau"},"datePublished":"2021-08-23T14:33:11.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":9},"url":"https://github.com/5952/typeshed/issues/5952"}
| 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:fe01f42f-b1b9-c652-e00c-fb311e2e3fad |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8430:35887C:D97026:1385CE6:6A634D8A |
| html-safe-nonce | 64e6ebc6d8138bbea780575bfd126d4e596e67fd37e1827895538fd7d96a9569 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4NDMwOjM1ODg3QzpEOTcwMjY6MTM4NUNFNjo2QTYzNEQ4QSIsInZpc2l0b3JfaWQiOiIxMTA3OTE3NjA2NDA4NjM3ODM0IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 016569f28fe218cccde8a36c583e6e17f33ccc2a8d38e771d07d011f27cfcbc7 |
| hovercard-subject-tag | issue:977102802 |
| 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/typeshed/5952/issue_layout |
| twitter:image | https://opengraph.githubassets.com/3121460ccdde0ce44f971a7a657a21080d91fb45dcffbb97b85d932390fd0b4f/python/typeshed/issues/5952 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/3121460ccdde0ce44f971a7a657a21080d91fb45dcffbb97b85d932390fd0b4f/python/typeshed/issues/5952 |
| og:image:alt | At the moment, whenever there is change to typeshed, we test all stdlib and third-party packages in the same testing environment, using the --custom-typeshed-dir so that all packages can see each o... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | srittau |
| hostname | github.com |
| expected-hostname | github.com |
| None | 59e55daad7174ca59d63c6974d58276ccb5477442e550bebb3c035e1bef11c94 |
| turbo-cache-control | no-preview |
| go-import | github.com/python/typeshed git https://github.com/python/typeshed.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 31696383 |
| octolytics-dimension-repository_nwo | python/typeshed |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 31696383 |
| octolytics-dimension-repository_network_root_nwo | python/typeshed |
| 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 | 990295d92a4cc7b63fbbd83a046217cd7d77d49c |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width