mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
tests: Try to fix mypy again /o\
This commit is contained in:
parent
1262642c68
commit
75b36f3b4a
1 changed files with 3 additions and 3 deletions
|
@ -2418,13 +2418,13 @@ def _parse_app_instance_name(app_instance_name: str) -> Tuple[str, int]:
|
|||
match = re_app_instance_name.match(app_instance_name)
|
||||
assert match, f"Could not parse app instance name : {app_instance_name}"
|
||||
appid = match.groupdict().get("appid")
|
||||
app_instance_nb = match.groupdict().get("appinstancenb") or "1"
|
||||
app_instance_nb_ = match.groupdict().get("appinstancenb") or "1"
|
||||
if not appid:
|
||||
raise Exception(f"Could not parse app instance name : {app_instance_name}")
|
||||
if not str(app_instance_nb).isdigit():
|
||||
if not str(app_instance_nb_).isdigit():
|
||||
raise Exception(f"Could not parse app instance name : {app_instance_name}")
|
||||
else:
|
||||
app_instance_nb = int(str(app_instance_nb))
|
||||
app_instance_nb = int(str(app_instance_nb_))
|
||||
|
||||
return (appid, app_instance_nb)
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue