mirror of
https://github.com/datafolklabs/cement.git
synced 2026-02-06 09:37:26 +00:00
Final Type Annotations Complete!!! Resolves PR #628
This commit is contained in:
parent
32bf8acef3
commit
c1df8e5a72
@ -15,5 +15,5 @@ class Base(Controller):
|
||||
(['-v', '--version'], {'action': 'version', 'version': BANNER}),
|
||||
]
|
||||
|
||||
def _default(self):
|
||||
def _default(self) -> None:
|
||||
self.app.args.print_help()
|
||||
|
||||
@ -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
|
||||
@ -29,12 +31,12 @@ class CementApp(App):
|
||||
|
||||
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()
|
||||
|
||||
Loading…
Reference in New Issue
Block a user