We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue tracker is ONLY used for reporting bugs. Please use the YDK Community for any support issues.
Encoding should work for valid value
Error occurs
Run the script below
from ydk.models.openconfig import openconfig_routing_policy \ as oc_routing_policy routing_policy = oc_routing_policy.RoutingPolicy() com = oc_routing_policy.RoutingPolicy.DefinedSets.BgpDefinedSets.CommunitySets.CommunitySet() com.community_set_name = "COMMUNITY-SET1" com.config.community_set_name = "COMMUNITY-SET1" com.config.community_member.append("ios-regex '65172:17...$'") com.config.community_member.append("65172:16001") com.state.community_set_name = "COMMUNITY-SET1" com.state.community_member.append("ios-regex '^65172:17...$'") com.state.community_member.append("65172:16001") routing_policy.defined_sets.bgp_defined_sets.community_sets.community_set.append(com) codec.encode(provider, routing_policy)
Enable logging and post the logs below
In [5]: codec.encode(codec_p,routing_policy) --------------------------------------------------------------------------- YPYModelError Traceback (most recent call last) <ipython-input-5-2f16c043627d> in <module>() ----> 1 codec.encode(codec_p,routing_policy) ~/p/lib/python3.6/site-packages/ydk/errors/error_handler.py in helper(self, provider, entity, *args, **kwargs) 110 err_msg = "'{0}' and '{1}' cannot be None".format(pname, ename) 111 raise _YPYServiceError(error_msg=err_msg) --> 112 return func(self, provider, entity, *args, **kwargs) 113 return helper ~/p/lib/python3.6/site-packages/ydk/services/codec_service.py in encode(self, provider, entity_holder, pretty, subtree) 72 return payload_map 73 else: ---> 74 return self._encode(provider, entity_holder, pretty, subtree) 75 76 def _encode(self, provider, entity, pretty, subtree): ~/p/lib/python3.6/site-packages/ydk/services/codec_service.py in _encode(self, provider, entity, pretty, subtree) 103 result = codec_service.encode(data_node, provider.encoding, pretty) 104 self.logger.debug("Performing encode operation, resulting in {}".format(result)) --> 105 return result 106 107 @_check_argument /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/contextlib.py in __exit__(self, type, value, traceback) 97 value = type() 98 try: ---> 99 self.gen.throw(type, value, traceback) 100 except StopIteration as exc: 101 # Suppress StopIteration *unless* it's the same exception that ~/p/lib/python3.6/site-packages/ydk/errors/error_handler.py in handle_runtime_error() 80 finally: 81 if _exc: ---> 82 _raise(_exc) 83 84 ~/p/lib/python3.6/site-packages/ydk/errors/error_handler.py in _raise(exc) 52 """ 53 if sys.version_info >= (3,3): ---> 54 exec("raise exc from None") 55 else: 56 raise exc ~/p/lib/python3.6/site-packages/ydk/errors/error_handler.py in <module>() YPYModelError: Unexpected character(s) '^' (^65172:17...$'']). Path:
ydk 0.6.2
The text was updated successfully, but these errors were encountered:
7cbdeeb
Merge pull request #650 from abhikeshav/fix_embedded_quote
4b70c2c
Fix #646
No branches or pull requests
Issue tracker is ONLY used for reporting bugs. Please use the YDK Community for any support issues.
Expected Behavior
Encoding should work for valid value
Current Behavior
Error occurs
Steps to Reproduce
Run the script below
Your Script
Logs
Enable logging and post the logs below
System Information
ydk 0.6.2
The text was updated successfully, but these errors were encountered: