Title: Crash in fine grained mode likely related to enums · Issue #4596 · python/mypy · GitHub
Open Graph Title: Crash in fine grained mode likely related to enums · Issue #4596 · python/mypy
X Title: Crash in fine grained mode likely related to enums · Issue #4596 · python/mypy
Description: Here is a traceback: Traceback (most recent call last): File "[somewhere]/mypy/dmypy_server.py", line 135, in serve resp = self.run_command(command, data) File "[somewhere]/mypy/dmypy_server.py", line 169, in run_command return method(se...
Open Graph Description: Here is a traceback: Traceback (most recent call last): File "[somewhere]/mypy/dmypy_server.py", line 135, in serve resp = self.run_command(command, data) File "[somewhere]/mypy/dmypy_server.py", l...
X Description: Here is a traceback: Traceback (most recent call last): File "[somewhere]/mypy/dmypy_server.py", line 135, in serve resp = self.run_command(command, data) File "[somewhere]/mypy/dmyp...
Opengraph URL: https://github.com/python/mypy/issues/4596
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Crash in fine grained mode likely related to enums","articleBody":"Here is a traceback:\r\n```\r\nTraceback (most recent call last):\r\n File \"[somewhere]/mypy/dmypy_server.py\", line 135, in serve\r\n resp = self.run_command(command, data)\r\n File \"[somewhere]/mypy/dmypy_server.py\", line 169, in run_command\r\n return method(self, **data)\r\n File \"[somewhere]/mypy/dmypy_server.py\", line 200, in cmd_check\r\n return self.check(self.last_sources)\r\n File \"[somewhere]/mypy/dmypy_server.py\", line 214, in check\r\n return self.check_fine_grained(sources)\r\n File \"[somewhere]/mypy/dmypy_server.py\", line 246, in check_fine_grained\r\n return self.initialize_fine_grained(sources)\r\n File \"[somewhere]/mypy/dmypy_server.py\", line 291, in initialize_fine_grained\r\n messages = self.fine_grained_manager.update(changed)\r\n File \"[somewhere]/mypy/server/update.py\", line 222, in update\r\n result = self.update_single(next_id, next_path)\r\n File \"[somewhere]/mypy/server/update.py\", line 264, in update_single\r\n result = update_single_isolated(module, path, manager, previous_modules)\r\n File \"[somewhere]/mypy/server/update.py\", line 437, in update_single_isolated\r\n replace_modules_with_new_variants(manager, graph, old_modules, new_modules)\r\n File \"[somewhere]/mypy/server/update.py\", line 702, in replace_modules_with_new_variants\r\n new_module, new_module.names)\r\n File \"[somewhere]/mypy/server/astmerge.py\", line 85, in merge_asts\r\n node = replace_nodes_in_ast(new, replacement_map)\r\n File \"[somewhere]/mypy/server/astmerge.py\", line 130, in replace_nodes_in_ast\r\n node.accept(visitor)\r\n File \"[somewhere]/mypy/nodes.py\", line 230, in accept\r\n return visitor.visit_mypy_file(self)\r\n File \"[somewhere]/mypy/server/astmerge.py\", line 151, in visit_mypy_file\r\n super().visit_mypy_file(node)\r\n File \"[somewhere]/mypy/traverser.py\", line 30, in visit_mypy_file\r\n d.accept(self)\r\n File \"[somewhere]/mypy/nodes.py\", line 931, in accept\r\n return visitor.visit_if_stmt(self)\r\n File \"[somewhere]/mypy/traverser.py\", line 114, in visit_if_stmt\r\n o.else_body.accept(self)\r\n File \"[somewhere]/mypy/nodes.py\", line 766, in accept\r\n return visitor.visit_block(self)\r\n File \"[somewhere]/mypy/server/astmerge.py\", line 154, in visit_block\r\n super().visit_block(node)\r\n File \"[somewhere]/mypy/traverser.py\", line 34, in visit_block\r\n s.accept(self)\r\n File \"[somewhere]/mypy/nodes.py\", line 704, in accept\r\n return visitor.visit_class_def(self)\r\n File \"[somewhere]/mypy/server/astmerge.py\", line 176, in visit_class_def\r\n self.process_type_info(node.info)\r\n File \"[somewhere]/mypy/server/astmerge.py\", line 264, in process_type_info\r\n replace_nodes_in_symbol_table(info.names, self.replacements)\r\nAttributeError: 'NoneType' object has no attribute 'names'\r\n```\r\nUnfortunately, there is no simple repro. The only hint is that this likely related to `Enum` and/or `IntEnum` (or a class being changed from a normal class to enum).","author":{"url":"https://github.com/ilevkivskyi","@type":"Person","name":"ilevkivskyi"},"datePublished":"2018-02-20T15:59:53Z","url":"https://github.com/python/mypy/issues/4596"}
| 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:7becf625-a61f-04a6-c9b6-a4383b8cedba |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | BD5E:22E601:BF4707:100753D:6B004DC9 |
| html-safe-nonce | 79bec564092fd4a1619dfe1d1182f40bcd48da82be04ad290f13889c35e6fcff |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCRDVFOjIyRTYwMTpCRjQ3MDc6MTAwNzUzRDo2QjAwNERDOSIsInZpc2l0b3JfaWQiOiI1MzgwODA4NDI2OTIwMTAzMzY5IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 79fde014ddea7bb9f35e93199787e42750f5458c11e4406516537559702474f9 |
| hovercard-subject-tag | issue:298648764 |
| 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/4596/issue_layout |
| twitter:image | https://opengraph.githubassets.com/3e8a7fdd6b20458620da7c8bf4eba8bb859f8ec47c30a656d6a74bf57590cc4e/python/mypy/issues/4596 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/3e8a7fdd6b20458620da7c8bf4eba8bb859f8ec47c30a656d6a74bf57590cc4e/python/mypy/issues/4596 |
| og:image:alt | Here is a traceback: Traceback (most recent call last): File "[somewhere]/mypy/dmypy_server.py", line 135, in serve resp = self.run_command(command, data) File "[somewhere]/mypy/dmypy_server.py", l... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | ilevkivskyi |
| hostname | github.com |
| expected-hostname | github.com |
| None | f9517bf360d46638a1e5e7daee7158842fe5ef43c9000afa0e127564a7c2f39b |
| 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 | b27c5dde30676028abd5c5fc53ce5c9b625f8281 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width