Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve compatibility #6

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

realshouzy
Copy link

@realshouzy realshouzy commented Jun 2, 2024

The current implementation is incompatible with Windows because of "sh -c" and Python under 3.9, because in 3.8 it was not possible to use subscriptions in type hints, so something like list[int].

Solution:

  • Checking if the current platform is Windows then the shell command is set to cmd /c otherwise sh -c
  • from __future__ import annotations: Sets a compiler flag that treats all type hints as strings (See PEP 563)

- Make compatible with Windows and Python <3.9
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant