Skip to content

Commit e46503e

Browse files
committed
update
1 parent aacbfdb commit e46503e

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

GEMstack/utils/serialization.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ def deserialize(data):
9999
"""
100100
global REGISTRY # noqa: F821, F841, F824
101101
name,version,data = deserialize_raw(data)
102-
if name not in REGISTRY:
102+
if name not in REGISTRY: # noqa: F824
103103
raise IOError("Class of type {} not found in registry".format(name))
104104
if version not in REGISTRY[name]:
105105
raise IOError("Version {} of type {} not found in registry".format(version,name))

GEMstack/utils/settings.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ def load_settings():
1313
overridden any settings using --KEY=VALUE.
1414
"""
1515
global SETTINGS # noqa: F821, F841, F824
16-
if SETTINGS is not None:
16+
if SETTINGS is not None: # noqa: F824
1717
return
1818
import os
1919
import sys
@@ -39,7 +39,7 @@ def settings():
3939
"""Returns all global settings, loading them if necessary."""
4040
global SETTINGS # noqa: F821, F841, F824
4141
load_settings()
42-
return SETTINGS
42+
return SETTINGS # noqa: F824
4343

4444

4545
def get(path : Union[str,List[str]], defaultValue=KeyError) -> Any:
@@ -49,7 +49,7 @@ def get(path : Union[str,List[str]], defaultValue=KeyError) -> Any:
4949
if isinstance(path,str):
5050
path = path.split('.')
5151
try:
52-
val = SETTINGS
52+
val = SETTINGS # noqa: F824
5353
for key in path:
5454
val = val[key]
5555
return val
@@ -69,7 +69,7 @@ def set(path : Union[str,List[str]], value : Any, leaf_only=True) -> None:
6969
load_settings()
7070
if isinstance(path,str):
7171
path = path.split('.')
72-
val = SETTINGS
72+
val = SETTINGS # noqa: F824
7373
if len(path) == 0:
7474
raise KeyError("Cannot set top-level settings")
7575
for key in path[:-1]:

0 commit comments

Comments
 (0)