-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
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
Fix yang case when two containers with same name , but different name… #640
Conversation
…spaces, augment one container * Fix golang naming to be consistent with other langs * Updated samples and tests * address #535 * Add more debug msgs and throw exceptions to avoid segfaults * tcp server start/stop
Codecov Report
@@ Coverage Diff @@
## master #640 +/- ##
=======================================
Coverage 32.77% 32.77%
=======================================
Files 31 31
Lines 5450 5450
Branches 550 550
=======================================
Hits 1786 1786
Misses 3664 3664
Continue to review full report at Codecov.
|
@@ -38,7 +38,7 @@ TEST_CASE("CreateNoRepoP") | |||
CHECK_NOTHROW(provider.get_encoding()); | |||
} | |||
|
|||
TEST_CASE("CreateNoRepoPTCP") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Leave comment about running this test case
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
@@ -27,7 +27,7 @@ using namespace ydk; | |||
using namespace std; | |||
#define NC_VERB_VERBOSE 2 | |||
|
|||
TEST_CASE("tcp_xr") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same as above: leave a comment about running these test cases
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
@@ -0,0 +1,36 @@ | |||
## Running Go Samples |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for creating this read me
@@ -62,6 +62,7 @@ func ExecuteRPC( | |||
panicOnCStateError(cstate) | |||
|
|||
if rootSchema == nil { | |||
ydk.YLogError("root schema is nil!") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These new lines are using spaces, but the go files seem to be using tabs.
I believe python style guides recommend spaces and go style guides recommend tabs... Maybe it might be good to commit to one style for the whole project at some point in the future, but for now and for this commit, I think it's better to not mix them up.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
ydkgen/printer/go/module_printer.py
Outdated
@@ -85,7 +85,7 @@ def _print_imports(self, package): | |||
def _print_init(self, package): | |||
self.ctx.writeln('func init() {') | |||
self.ctx.lvl_inc() | |||
self.ctx.writeln('fmt.Println("Registering top level entities for package {}")'.format(package.name)) | |||
#self.ctx.writeln('fmt.Println("Registering top level entities for package {}")'.format(package.name)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you mean to delete this line?
@@ -240,3 +240,10 @@ def _print_class_setattr_body(self, clazz, leafs): | |||
def _print_class_setattr_trailer(self): | |||
self.ctx.lvl_dec() | |||
self.ctx.bline() | |||
|
|||
|
|||
def _get_qualified_yang_name(clazz): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you forgot to delete this
@@ -36,8 +36,13 @@ def print_function_body(self): | |||
if child.is_many: | |||
self._print_many(child) | |||
else: | |||
path = '' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
leave a comment on this code
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
see comments
…spaces, augment one container