projects
/
arvados.git
/ blobdiff
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
21230: Update yml_override.py for PyYAML 6.0+
[arvados.git]
/
tools
/
arvbox
/
lib
/
arvbox
/
docker
/
yml_override.py
diff --git
a/tools/arvbox/lib/arvbox/docker/yml_override.py
b/tools/arvbox/lib/arvbox/docker/yml_override.py
index deea83f909b27ddc715313d40a7e8292298e53b5..5f9ee68e4fc7c2480e1ed4f4bb0ca61b28c0edfc 100755
(executable)
--- a/
tools/arvbox/lib/arvbox/docker/yml_override.py
+++ b/
tools/arvbox/lib/arvbox/docker/yml_override.py
@@
-10,12
+10,12
@@
fn = sys.argv[1]
try:
with open(fn+".override") as f:
try:
with open(fn+".override") as f:
- b = yaml.load(f)
+ b = yaml.
safe_
load(f)
except IOError:
exit()
with open(fn) as f:
except IOError:
exit()
with open(fn) as f:
- a = yaml.load(f)
+ a = yaml.
safe_
load(f)
def recursiveMerge(a, b):
if isinstance(a, dict) and isinstance(b, dict):
def recursiveMerge(a, b):
if isinstance(a, dict) and isinstance(b, dict):
@@
-27,4
+27,4
@@
def recursiveMerge(a, b):
return b
with open(fn, "w") as f:
return b
with open(fn, "w") as f:
- yaml.dump(recursiveMerge(a, b), f)
+ yaml.
safe_
dump(recursiveMerge(a, b), f)