Title: Handle simple if statements when processing stubs · Issue #569 · microsoft/python-language-server · GitHub
Open Graph Title: Handle simple if statements when processing stubs · Issue #569 · microsoft/python-language-server
X Title: Handle simple if statements when processing stubs · Issue #569 · microsoft/python-language-server
Description: Typeshed's stubs contain many if statements to declare things based on the Python version and the system platform. In order to have the right type info, when analyzing stubs we should handle those checks. They're not complicated, and are...
Open Graph Description: Typeshed's stubs contain many if statements to declare things based on the Python version and the system platform. In order to have the right type info, when analyzing stubs we should handle those ...
X Description: Typeshed's stubs contain many if statements to declare things based on the Python version and the system platform. In order to have the right type info, when analyzing stubs we should handle th...
Opengraph URL: https://github.com/microsoft/python-language-server/issues/569
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Handle simple if statements when processing stubs","articleBody":"Typeshed's stubs contain many if statements to declare things based on the Python version and the system platform. In order to have the right type info, when analyzing stubs we should handle those checks. They're not complicated, and are usually like:\r\n\r\n```python\r\nif sys.version_info >= (3, 6): ...\r\nif sys.platform == 'win32': ...\r\nif sys.version_info >= (3, 3) and sys.platform != 'win32': ...\r\n```\r\n\r\nSee:\r\n- https://github.com/python/typeshed/blob/master/stdlib/3/os/__init__.pyi\r\n- https://github.com/python/typeshed/blob/master/stdlib/3/os/path.pyi\r\n\r\nSeems like it's all `sys.version_info` and `sys.platform`.","author":{"url":"https://github.com/jakebailey","@type":"Person","name":"jakebailey"},"datePublished":"2019-01-31T18:19:26Z","url":"https://github.com/microsoft/python-language-server/issues/569"}
| 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:9e06f8c4-48f7-8ee0-5e30-205c61a424a8 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E5B0:262F52:E9529:12E7C1:6AFE52BE |
| html-safe-nonce | 4bd6d89b6f182cff33986d46d0fdbb76914309e46b2161b63b7c597a970602a5 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFNUIwOjI2MkY1MjpFOTUyOToxMkU3QzE6NkFGRTUyQkUiLCJ2aXNpdG9yX2lkIjoiNTc3NzgyMzEwOTEzNDMwODAzMSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | f820da97bf33bada436c4ccf2425f162b8b3da0b30806943f95bb87f053f4be3 |
| hovercard-subject-tag | issue:405375926 |
| 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/microsoft/python-language-server/569/issue_layout |
| twitter:image | https://opengraph.githubassets.com/8169f68e44c5943a429a9fbfcfb36b0ac17f9521726f05cdcc63801684e11777/microsoft/python-language-server/issues/569 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/8169f68e44c5943a429a9fbfcfb36b0ac17f9521726f05cdcc63801684e11777/microsoft/python-language-server/issues/569 |
| og:image:alt | Typeshed's stubs contain many if statements to declare things based on the Python version and the system platform. In order to have the right type info, when analyzing stubs we should handle those ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | jakebailey |
| hostname | github.com |
| expected-hostname | github.com |
| None | 3ad2b58e42f481583284b895305360b61b0223636c9dde6d696b575347163a26 |
| turbo-cache-control | no-preview |
| go-import | github.com/microsoft/python-language-server git https://github.com/microsoft/python-language-server.git |
| octolytics-dimension-user_id | 6154722 |
| octolytics-dimension-user_login | microsoft |
| octolytics-dimension-repository_id | 145901977 |
| octolytics-dimension-repository_nwo | microsoft/python-language-server |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 145901977 |
| octolytics-dimension-repository_network_root_nwo | microsoft/python-language-server |
| 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 | 8df44dbe1c8091b38c3e0165c05a1e5c1563762e |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width