ariatosca-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From AviaE <...@git.apache.org>
Subject [GitHub] incubator-ariatosca pull request #189: ARIA-174 Refactor instantiation phase
Date Wed, 09 Aug 2017 10:05:56 GMT
Github user AviaE commented on a diff in the pull request:

    https://github.com/apache/incubator-ariatosca/pull/189#discussion_r132140607
  
    --- Diff: aria/utils/console.py ---
    @@ -31,51 +31,51 @@
     
     
     class TopologyStylizer(object):
    -    def __init__(self, indentation=2):
    +    def __init__(self, indentation=0):
             self._str = StringIO()
             self._indentation = indentation
     
    -    def write(self, str_):
    -        puts(str_, stream=self._str)
    +    def write(self, string):
    +        self._str.write(' ' * self._indentation)
    +        self._str.write(string)
    +        self._str.write(os.linesep)
     
         @contextmanager
    -    def indent(self, indentation=None):
    -        with indent(indentation or self._indentation):
    -            yield
    +    def indent(self, indentation=2):
    +        self._indentation += indentation
    +        yield
    +        self._indentation -= indentation
     
         @staticmethod
    -    def section(value):
    +    def section_style(value):
    --- End diff --
    
    Is this even used?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message