Skip to content

Commit ec76bba

Browse files
committed
Don't include Serve in command schemas
1 parent 9c66381 commit ec76bba

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

shapeflow/cli.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@ class IterCommand(abc.ABCMeta):
4949
"""
5050
__command__: str
5151
"""Command name. This is how the command is addressed from the commandline.
52-
""" # todo: nope, doesn't work'
52+
"""
53+
5354

5455
def __str__(cls):
5556
try:
@@ -452,7 +453,7 @@ def _update(self) -> None:
452453

453454

454455
class Checkout(Command, GitMixin):
455-
"""Check out a specific version of the application. Please not you will
456+
"""Check out a specific version of the application. Please note you will
456457
not have access to this command if you check out a version before 0.4.4
457458
"""
458459

shapeflow/main.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
from shapeflow.video import init, VideoAnalyzer
3636
import shapeflow.plugins
3737
from shapeflow.server import ShapeflowServer
38-
from shapeflow.cli import Command
38+
from shapeflow.cli import Command, Serve
3939

4040
from shapeflow.db import History
4141

@@ -59,7 +59,9 @@ def schemas() -> Dict[str, dict]:
5959
return {
6060
'config': VideoAnalyzerConfig.schema(),
6161
'settings': settings.schema(),
62-
'commands': [argparse2schema(c.parser) for c in Command],
62+
'commands': [
63+
argparse2schema(c.parser) for c in Command if c is not Serve
64+
],
6365
'analyzer_state': dict(AnalyzerState.__members__),
6466
'queue_state': dict(QueueState.__members__),
6567
}

0 commit comments

Comments
 (0)