Method
_find_implementation
(
cls,
python_tag, # type: str
free_threaded, # type: Optional[bool]
version, # type: Tuple[int, int, int]
)
Source from the content-addressed store, hash-verified
| 406 | |
| 407 | @classmethod |
| 408 | def _find_implementation( |
| 409 | cls, |
| 410 | python_tag, # type: str |
| 411 | free_threaded, # type: Optional[bool] |
| 412 | version, # type: Tuple[int, int, int] |
| 413 | ): |
| 414 | # type: (...) -> InterpreterImplementation.Value |
| 415 | for implementation in InterpreterImplementation.values(): |
| 416 | if ( |
| 417 | implementation.applies(version) |
| 418 | and python_tag.startswith(implementation.abbr) |
| 419 | and (implementation.free_threaded == free_threaded) |
| 420 | ): |
| 421 | return implementation |
| 422 | raise ValueError("Unknown interpreter: {}".format(python_tag)) |
| 423 | |
| 424 | def __init__( |
| 425 | self, |
Tested by
no test coverage detected