Skip to content

Bad while loop pegging CPU on Windows #42

@cdgriffith

Description

@cdgriffith

https://github.com/magmax/python-readchar/blob/master/readchar/readchar.py#L71

Nothing slowing this while loop is causing a CPU core to be pegged on Windows. Either removing if msvcrt.kbhit() or adding a time.sleep(0.001) (or similar) is necessary.

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