Skip to content

Commit c2e36e4

Browse files
committed
Handle missing noargs (#126)
Did a pip install of this specific branch to ensure the error was gone when I ran `cwms-cli`
1 parent da2417f commit c2e36e4

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

cwmscli/__main__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,10 @@ def main() -> None:
6262
}
6363
try:
6464
cli(standalone_mode=False)
65+
except click.exceptions.NoArgsIsHelpError as e:
66+
if e.ctx is not None:
67+
click.echo(e.ctx.get_help())
68+
raise SystemExit(0)
6569
except SystemExit:
6670
raise
6771
except Exception as e:

0 commit comments

Comments
 (0)