Skip to content

Misplaced type annotation #5696

Closed
Closed
@iddan

Description

@iddan
  • Are you reporting a bug, or opening a feature request? bug
  • Please insert below the code you are checking with mypy,
    or a mock-up repro if the source is private. We would appreciate
    if you try to simplify your case to a minimal repro.
onboarding_protocols: Dict[str, protocol.RawProtocol] = {
    protocol_path.stem: read_protocol(protocol_path)
    for protocol_path in onboarding_protocols_path.glob('*.json')
}
  • What is the actual behavior/output? mypy emits error:misplaced type annotation
  • What is the behavior/output you expect? to parse correctly
  • What are the versions of mypy and Python you are using? mypy 0.630, Python 3.6.5
    Do you see the same issue after installing mypy from Git master? Yes
  • What are the mypy flags you are using? (For example --strict-optional) None
  • If mypy crashed with a traceback, please paste
    the full traceback below.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions