HCAI-Lab/w2-consensus-deepdive-unlearning-artifacts / pyright_venv /lib /python3.9 /site-packages /pyright /cli.py
| import sys | |
| import logging | |
| import subprocess | |
| from typing import Any, List, Union, NoReturn | |
| from . import node | |
| from ._utils import install_pyright | |
| __all__ = ( | |
| 'run', | |
| 'main', | |
| ) | |
| log: logging.Logger = logging.getLogger(__name__) | |
| def main(args: List[str], **kwargs: Any) -> int: | |
| return run(*args, **kwargs).returncode | |
| def run(*args: str, **kwargs: Any) -> Union['subprocess.CompletedProcess[bytes]', 'subprocess.CompletedProcess[str]']: | |
| pkg_dir = install_pyright(args, quiet=None) | |
| script = pkg_dir / 'index.js' | |
| if not script.exists(): | |
| raise RuntimeError(f'Expected CLI entrypoint: {script} to exist') | |
| return node.run('node', str(script), *args, **kwargs) | |
| def entrypoint() -> NoReturn: | |
| sys.exit(main(sys.argv[1:])) | |
Xet Storage Details
- Size:
- 758 Bytes
- Xet hash:
- 0f842c1e74c95e32901b85bf3717869dac4400f13538dbaefaf1b6212162ad05
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.