Skip to content

Expand type: ignore documentation #11354

Closed
@tusharsadhwani

Description

@tusharsadhwani

Feature

Allowing a short message with your type ignore comments, for better context

Pitch

I wanted to add a little comment with my type: ignore to provide some context as to why that ignore is present in the code.

This is the thing that I tried:

for text in iter(buff.read1, b""):  # type: ignore - typeshed bug
    print(decoder.decode(text), end="")

Unfortunately that doesn't work.
I tried a few other variants, like # type: ignore; typeshed bug, but I could find no way to add a message to the ignore comment.

It also seems like an easy feature that I could work on :)

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions