diff --git a/requirements.txt b/requirements.txt index 9ef12c9..7f9e84b 100644 --- a/requirements.txt +++ b/requirements.txt @@ -2,7 +2,7 @@ confection>=0.0.4,<0.2.0 wasabi>=0.9.1,<1.2.0 srsly>=2.4.3,<3.0.0 -typer-slim>=0.3.0,<1.0.0 +typer>=0.3.0,<1.0.0 cloudpathlib>=0.7.0,<1.0.0 smart-open>=5.2.1,<8.0.0 # Third party dependencies diff --git a/setup.cfg b/setup.cfg index de3e4a7..5a9be7d 100644 --- a/setup.cfg +++ b/setup.cfg @@ -35,7 +35,7 @@ install_requires = packaging>=20.0 wasabi>=0.9.1,<1.2.0 srsly>=2.4.3,<3.0.0 - typer-slim>=0.3.0,<1.0.0 + typer>=0.3.0,<1.0.0 cloudpathlib>=0.7.0,<1.0.0 smart-open>=5.2.1,<8.0.0 requests>=2.13.0,<3.0.0 diff --git a/weasel/cli/main.py b/weasel/cli/main.py index 3d19098..f162470 100644 --- a/weasel/cli/main.py +++ b/weasel/cli/main.py @@ -15,7 +15,7 @@ Arg = typer.Argument Opt = typer.Option -app = typer.Typer(name=NAME, help=HELP, no_args_is_help=True, add_completion=False) +app = typer.Typer(name=NAME, help=HELP, no_args_is_help=True, add_completion=False, rich_markup_mode=None) def _get_parent_command(ctx: typer.Context) -> str: diff --git a/weasel/tests/cli/test_cli_app.py b/weasel/tests/cli/test_cli_app.py index bd983e2..bdcd5d5 100644 --- a/weasel/tests/cli/test_cli_app.py +++ b/weasel/tests/cli/test_cli_app.py @@ -12,12 +12,13 @@ runner = CliRunner() -@pytest.mark.parametrize("cmd", ["--help"]) +@pytest.mark.parametrize("cmd", [None, "--help"]) def test_show_help(cmd): """Basic test to confirm help text appears""" - # This test used to exercise the no-args help as well but - # it no longer seems to work in typer-slim. Maybe I'm doing it wrong? - result = runner.invoke(app, [cmd]) + if cmd: + result = runner.invoke(app, [cmd]) + else: + result = runner.invoke(app) for line in HELP.splitlines(): assert line in result.stdout