Skip to content
Permalink
Browse files

fix(compose): resolve unclosed file warning

  • Loading branch information...
hanxiao committed Jul 17, 2019
1 parent 0c737a9 commit 2b7c3f180c6eb2b73378f24dd855ab44bef4e53d
Showing with 4 additions and 3 deletions.
  1. +4 −3 gnes/composer/base.py
@@ -75,9 +75,10 @@ def __init__(self, args):

self._layers = [] # type: List['YamlGraph.Layer']
self.logger = set_logger(self.__class__.__name__)
tmp = _yaml.load(args.yaml_path)
stream = StringIO()
_yaml.dump(tmp, stream)
with args.yaml_path:
tmp = _yaml.load(args.yaml_path)
stream = StringIO()
_yaml.dump(tmp, stream)
self.original_yaml = stream.getvalue()
self.name = tmp.get('name', args.name)
self.port = tmp.get('port', args.port)

0 comments on commit 2b7c3f1

Please sign in to comment.
You can’t perform that action at this time.