Skip to content

Commit

Permalink
Final Type Annotations Complete!!! Resolves PR #628
Browse files Browse the repository at this point in the history
  • Loading branch information
derks committed Jul 18, 2024
1 parent 32bf8ac commit c1df8e5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion cement/cli/controllers/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ class Meta:
(['-v', '--version'], {'action': 'version', 'version': BANNER}),
]

def _default(self):
def _default(self) -> None:
self.app.args.print_help()
8 changes: 5 additions & 3 deletions cement/cli/main.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@

from __future__ import annotations
import os
import sys
from typing import Optional, List
sys.path.append(os.path.join(os.path.dirname(__file__), 'contrib'))

from cement import App, CaughtSignal # noqa: E402
Expand Down Expand Up @@ -29,12 +31,12 @@ class Meta:

class CementTestApp(CementApp):
class Meta:
argv = []
config_files = []
argv: List[str] = []
config_files: List[str] = []
exit_on_close = False


def main(argv=None):
def main(argv: Optional[List[str]] = None) -> None:
with CementApp() as app:
try:
app.run()
Expand Down

0 comments on commit c1df8e5

Please sign in to comment.