-
Notifications
You must be signed in to change notification settings - Fork 0
Comparing changes
Open a pull request
base repository: LabNConsulting/libyang-python
base: 3072af0
head repository: CESNET/libyang-python
compare: 2cae616
- 16 commits
- 14 files changed
- 4 contributors
Commits on Oct 16, 2025
-
data: option to allow json int/bool as strings
Depends on CESNET/libyang#2344 Add support for new option to python bindings. Signed-off-by: Brad House <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 18faa1e - Browse repository at this point
Copy the full SHA 18faa1eView commit details -
schema/context: restore some backlinks support
In libyang v1 the schema nodes had a backlinks member to be able to look up dependents of the node. SONiC depends on this to provide functionality it uses and it needs to be exposed via the python module. In theory, exposing the 'dfs' functions could make this work, but it would likely be cost prohibitive since walking the tree would be expensive to create a python node for evaluation in native python. Instead this PR depends on the this libyang PR: CESNET/libyang#2352 And adds thin wrappers. This implementation provides 2 python functions: * Context.find_backlinks_paths() - This function can take the path of the base node and find all dependents. If no path is specified, then it will return all nodes that contain a leafref reference. * Context.find_leafref_path_target_paths() - This function takes an xpath, then returns all target nodes the xpath may reference. Typically only one will be returned, but multiples may be in the case of a union. A user can build a cache by combining Context.find_backlinks_paths() with no path set and building a reverse table using Context.find_leafref_path_target_paths() Signed-off-by: Brad House <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for c8313b7 - Browse repository at this point
Copy the full SHA c8313b7View commit details -
context: use normal type hint rather than forward reference
SNode is imported and available so there's no need to use the "libyang.SNode" forward reference form. (based)pyright complains about this as it considers these forward references as `Unknown` -- perhaps it should be smarter, but that's a different issue. Signed-off-by: Christian Hopps <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 91067eb - Browse repository at this point
Copy the full SHA 91067ebView commit details -
tests: test_iffeature_state crash fix
As observed on Debian Trixie RC2, test_iffeature_state crashes due to an internal pointer being invalidated. This invalidation appears to be due to a call to lys_set_implemented() possibly causing a full recompile of the ctx. This simply reorders the caching of the path pointers so they are not invalidated when used. Signed-off-by: Brad House <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 1714370 - Browse repository at this point
Copy the full SHA 1714370View commit details -
data: add missing DNode.is_default API
Add access to libyang lyd_is_default() API. Signed-off-by: Christian Hopps <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for aa3f506 - Browse repository at this point
Copy the full SHA aa3f506View commit details -
Simplify the code to using python enum functionality. Signed-off-by: Christian Hopps <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for e977f94 - Browse repository at this point
Copy the full SHA e977f94View commit details -
data: adding ability to get target_nodes
This patch introduces target_nodes API, which allows user to get all target data nodes that current leafref node is pointing to Signed-off-by: Stefan Gula <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 2740fa2 - Browse repository at this point
Copy the full SHA 2740fa2View commit details -
data: adding dep_tree option for RPC validation
This patch introduces dep_tree option to provide config data to which the RPC can referenced to during validation Signed-off-by: Stefan Gula <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 39afe5e - Browse repository at this point
Copy the full SHA 39afe5eView commit details -
schema: adds ability to use with_choice option in children calls
This patch adds ability to use with_choice within RPC and Notification Signed-off-by: Stefan Gula <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 4147016 - Browse repository at this point
Copy the full SHA 4147016View commit details -
schema: adds ability to get various outputs as extension parent_node
This patch adds ability to get also PRefine, PType and PEnum as a valid output using extension parent_node function Signed-off-by: Stefan Gula <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for d3dd5f0 - Browse repository at this point
Copy the full SHA d3dd5f0View commit details -
data: add structured error in exception
Refactor LibyangError exception handling with structured details Signed-off-by: Pepa Hajek <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 90dad07 - Browse repository at this point
Copy the full SHA 90dad07View commit details -
schema: add missing extensions() for access to module level
Currently only have access to the extensions used under schema nodes, need access to extensions used at the module level. Add a test case for the functionality as well. Signed-off-by: Christian Hopps <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for b78cdce - Browse repository at this point
Copy the full SHA b78cdceView commit details -
schema: adds extensions and get_extension for Enum class
This patch allows to get extensions on Enum type Signed-off-by: Stefan Gula <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 2ff17b4 - Browse repository at this point
Copy the full SHA 2ff17b4View commit details -
context: adds find_xpath_atoms function
This patch is adding find_xpath_atoms on context level to allow users to get all nodes needed for xpath evaluation Signed-off-by: Stefan Gula <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for b35336b - Browse repository at this point
Copy the full SHA b35336bView commit details -
schema: adds ability to get when context nodes
This patch adds ability to get context schema node from which when contition is evaluated. It also fixes memory leak of original when_conditions Signed-off-by: Stefan Gula <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 74b7d1d - Browse repository at this point
Copy the full SHA 74b7d1dView commit details -
schema: adds libyang.Enum to package
This patch adds missing Enum class to __init__.py to allow imports by library users Signed-off-by: Stefan Gula <[email protected]>
Configuration menu - View commit details
-
Copy full SHA for 2cae616 - Browse repository at this point
Copy the full SHA 2cae616View commit details
This comparison is taking too long to generate.
Unfortunately it looks like we can’t render this comparison for you right now. It might be too big, or there might be something weird with your repository.
You can try running this command locally to see the comparison on your machine:
git diff 3072af0...2cae616