diff --git a/requirements.txt b/requirements.txt index 63e03d558..fcecc7890 100644 --- a/requirements.txt +++ b/requirements.txt @@ -12,6 +12,7 @@ catalogue>=2.0.6,<2.1.0 typer>=0.3.0,<0.8.0 pathy>=0.10.0 smart-open>=5.2.1,<7.0.0 +weasel>=0.1.0rc1 # Third party dependencies numpy>=1.15.0 requests>=2.13.0,<3.0.0 diff --git a/setup.cfg b/setup.cfg index 27499805b..e1823b180 100644 --- a/setup.cfg +++ b/setup.cfg @@ -51,6 +51,7 @@ install_requires = wasabi>=0.9.1,<1.2.0 srsly>=2.4.3,<3.0.0 catalogue>=2.0.6,<2.1.0 + weasel>=0.1.0rc1 # Third-party dependencies typer>=0.3.0,<0.8.0 pathy>=0.10.0 diff --git a/spacy/cli/_util.py b/spacy/cli/_util.py index 68e3255a8..4e8102e3d 100644 --- a/spacy/cli/_util.py +++ b/spacy/cli/_util.py @@ -16,6 +16,8 @@ from thinc.util import gpu_is_available from configparser import InterpolationError import os +from weasel import app as project_cli + from ..compat import Literal from ..util import import_file, run_command, registry, logger, ENV_VARS @@ -52,11 +54,10 @@ Opt = typer.Option app = typer.Typer(name=NAME, help=HELP) benchmark_cli = typer.Typer(name="benchmark", help=BENCHMARK_HELP, no_args_is_help=True) -project_cli = typer.Typer(name="project", help=PROJECT_HELP, no_args_is_help=True) debug_cli = typer.Typer(name="debug", help=DEBUG_HELP, no_args_is_help=True) init_cli = typer.Typer(name="init", help=INIT_HELP, no_args_is_help=True) -app.add_typer(project_cli) +app.add_typer(project_cli, name="project", help=PROJECT_HELP, no_args_is_help=True) app.add_typer(debug_cli) app.add_typer(benchmark_cli) app.add_typer(init_cli) diff --git a/spacy/tests/test_cli.py b/spacy/tests/test_cli.py index 14b82ffe2..c5dfdf7e5 100644 --- a/spacy/tests/test_cli.py +++ b/spacy/tests/test_cli.py @@ -11,6 +11,9 @@ from click import NoSuchOption from packaging.specifiers import SpecifierSet from thinc.api import Config, ConfigValidationError +from weasel.cli.remote_storage import RemoteStorage +from weasel.cli.run import _check_requirements + from spacy import about from spacy.cli import info from spacy.cli._util import walk_directory