Skip to content

panic: key not found, module __unknown__ with incomplete assignment expression #2093

@correctmost

Description

@correctmost

Describe the Bug

Pyrefly crashes when checking this fuzzed code:

(:=
Thread panicked, shutting down: panicked at pyrefly/lib/binding/bindings.rs:297:13:
Internal error: key not found, module `__unknown__`, path `/home/user/a.py`, key Hashed { hash: StarlarkHashValue(289934492), key: Definition(ShortIdentifier(1..1)) }

Version info

0.48.0

Sandbox Link

https://pyrefly.org/sandbox/?project=N4IgZglgNgpgziAXKOBDAdgEwEYHsAeAdAA4CeSIAFIgLwgA0IArgC7RwnmIgDEABAFU2UCC1J8wTdAGM2udHAA66ZZhhgJuAE4BbVCwD66JjuwwtlfIj4R0LAJR8AtAD4%2BcFlsTK%2BvvlpgWJi10CUUQADkTMy8%2BYHwAX3DlBhAyALAoUkIWXB0oCn4ABVIMrPcMHAI%2BaXlIAHNg-Qh5QmV%2BAGUYGD4ACxYWYjhEAHoR9PUswm16kZh0EcxcaTgR2vQGprkFzS0%2BVAA3VGhUbFgauohGrWb5PlxibY5lMhZe%2BScD8zgW0Jo%2BcIAZkIAEYAEzJdAgBKMVCyCBfABi0BgFDQWDwRDI0KAA

(Only applicable for extension issues) IDE Information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    crashhelp wantedLarger than "good first issue", but still well-defined and ready for someone to pick up

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions