mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-08-21 16:23:46 +08:00
add mypy check for return-any (#24379)
* add mypy check for return-any * remove unused import * typing * remove unnecessary variable typing * cleanup * cleanup * bump submodules * small fixes * only a problem on mac Co-authored-by: Willem Melching <willem.melching@gmail.com> old-commit-hash: d2eef1955c777ef6110c7a74d2a9ca9e4e1d958c
This commit is contained in:
@@ -55,7 +55,7 @@ def get_origin(default: Optional[str] = None) -> Optional[str]:
|
||||
|
||||
@cache
|
||||
def get_normalized_origin(default: Optional[str] = None) -> Optional[str]:
|
||||
origin = get_origin()
|
||||
origin: Optional[str] = get_origin()
|
||||
|
||||
if origin is None:
|
||||
return default
|
||||
@@ -74,7 +74,7 @@ def get_version() -> str:
|
||||
|
||||
@cache
|
||||
def get_short_version() -> str:
|
||||
return get_version().split('-')[0]
|
||||
return get_version().split('-')[0] # type: ignore
|
||||
|
||||
@cache
|
||||
def is_prebuilt() -> bool:
|
||||
@@ -85,7 +85,7 @@ def is_prebuilt() -> bool:
|
||||
def is_comma_remote() -> bool:
|
||||
# note to fork maintainers, this is used for release metrics. please do not
|
||||
# touch this to get rid of the orange startup alert. there's better ways to do that
|
||||
origin = get_origin()
|
||||
origin: Optional[str] = get_origin()
|
||||
if origin is None:
|
||||
return False
|
||||
|
||||
|
||||
Reference in New Issue
Block a user