Github user ran-z commented on a diff in the pull request:

    https://github.com/apache/incubator-ariatosca/pull/95#discussion_r111165982
  
    --- Diff: extensions/aria_extension_tosca/simple_v1_0/modeling/__init__.py 
---
    @@ -677,21 +715,18 @@ def pattern(node_type, container): # pylint: 
disable=unused-argument
         return None
     
     
    -def parse_implementation_string(context, service_template, implementation):
    -    if not implementation:
    -        return None, ''
    +def split_prefix(string):
    +    split = IMPLEMENTATION_PREFIX_REGEX.split(string, 2)
    +    if len(split) < 2:
    +        return None, string
    +    return split[0].strip(), split[1].lstrip()
     
    -    index = implementation.find('>')
    -    if index == -1:
    -        return None, implementation
    -    plugin_name = implementation[:index].strip()
    -    
    -    if plugin_name == 'execution':
    -        plugin_specification = None
    -    else:
    -        plugin_specification = 
service_template.plugin_specifications.get(plugin_name)
    -        if plugin_specification is None:
    -            raise ValueError('unknown plugin: "{0}"'.format(plugin_name))
     
    -    implementation = implementation[index+1:].strip()
    -    return plugin_specification, implementation
    +def set_nested(the_dict, keys, value):
    --- End diff --
    
    could you add a few comments here, possibly an example of input --> output, 
just so it's clearer? thanks


---
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 [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to