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
Consider YANG models below: test.yang
module test { yang-version 1.1; namespace "http://www.test.com/test"; prefix test; include test-augment; container con { leaf a { type string; } } }
test-augment.yang
submodule test-augment { belongs-to "test" { prefix "test"; } augment "/test:con" { leaf b { type string; } } }
Using restconf PATCH /test:con/a success.
curl -X PATCH -H "Content-Type: application/yang-data+json" -d '{ "test:a": "hello123" }' http://localhost/restconf/data/test:con/a
Whereas same request on /test:con/b would failed with error below:
curl -X PATCH -H "Content-Type: application/yang-data+json" -d '{ "test:b": "hello13434" }' http://localhost/restconf/data/test:con/b { "ietf-restconf:errors" : { "error": { "error-type": "rpc", "error-tag": "malformed-message", "error-severity": "error", "error-message": "Data is not prefixed with matching namespace" } } }
Seems in restconf_methods.c:372, ymoddata and ymodapi are not the samething.
clixon/apps/restconf/restconf_methods.c
Line 372 in 31719b5
ymodapi points to a submodule yang_stmt, but ymoddata points to a main module.
The text was updated successfully, but these errors were encountered:
Fixed: [Restconf PATCH method request failed on item defined by submo…
2291275
…dule #306](#306)
Thanks for detecting this important cornercase error. Please verify the submitted fix.
Sorry, something went wrong.
Issue fixed
No branches or pull requests
Consider YANG models below:
test.yang
test-augment.yang
Using restconf PATCH /test:con/a success.
Whereas same request on /test:con/b would failed with error below:
Seems in restconf_methods.c:372, ymoddata and ymodapi are not the samething.
clixon/apps/restconf/restconf_methods.c
Line 372 in 31719b5
ymodapi points to a submodule yang_stmt, but ymoddata points to a main module.
The text was updated successfully, but these errors were encountered: