Skip to content

Generalize load module #133

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

Merged
merged 3 commits into from
Feb 17, 2025
Merged

Generalize load module #133

merged 3 commits into from
Feb 17, 2025

Conversation

rbu9fe
Copy link
Contributor

@rbu9fe rbu9fe commented Feb 13, 2025

This is an attempt to fix #101, however, it doesn't work as expected and I don't know why. Perhaps you can give me a hint?

The issue is how to pass a list of features into the C API. I implemented the helper function strlist2c for that purpose based on the example in the ffi documentation: An example of calling a main-like thing
However, the pointers/memory received by the C API seem not to be valid.

Do you have an idea what's going wrong here?

@rjarry
Copy link
Collaborator

rjarry commented Feb 14, 2025

@rbu9fe rbu9fe force-pushed the generalize-load-module branch 2 times, most recently from b44e3fe to 196ddd7 Compare February 17, 2025 11:05
@rbu9fe
Copy link
Contributor Author

rbu9fe commented Feb 17, 2025

@rjarry Thanks for the hint, now it works as expected. However, the check-commits task fails due to some formatting issue of the JSON tree caused by echo. It works locally when check_issue is changed to simply call

	test $(curl -f -X GET -L --no-progress-meter \
		-H "Accept: application/vnd.github+json" \
		-H "X-GitHub-Api-Version: 2022-11-28" \
		"$api_url/issues/${1##*/}" | jq -r .state) = open

Can you please take a look?

@rjarry rjarry force-pushed the generalize-load-module branch 3 times, most recently from b0766e1 to 196ddd7 Compare February 17, 2025 13:18
rjarry and others added 3 commits February 17, 2025 14:19
For some reason, storing the output of curl into a bash variable breaks
UTF-8 encoding.

Use a shell pipeline to prevent any encoding from happening.

Signed-off-by: Robin Jarry <[email protected]>
Add parameters to define Yang model revision and features that shall be enabled.

Closes: CESNET#101
Signed-off-by: Matthias Breuninger <[email protected]>
Expects that all features are enabled due to the "*" input.

Closes: CESNET#101
Signed-off-by: Matthias Breuninger <[email protected]>
@rjarry rjarry force-pushed the generalize-load-module branch from 196ddd7 to 672e050 Compare February 17, 2025 13:23
@rbu9fe rbu9fe marked this pull request as ready for review February 17, 2025 13:25
@rjarry rjarry merged commit 3f4ef9f into CESNET:master Feb 17, 2025
10 checks passed
@rbu9fe
Copy link
Contributor Author

rbu9fe commented Feb 17, 2025

Thanks @rjarry !

@rbu9fe
Copy link
Contributor Author

rbu9fe commented Feb 17, 2025

@rjarry Can you please add a Git tag including that change?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support features in context.load_module
2 participants