Skip to content
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

feat: custom metadata support #268

Merged
merged 2 commits into from
Mar 6, 2023
Merged

Conversation

tri-adam
Copy link
Member

@tri-adam tri-adam commented Mar 2, 2023

Add OptMetadata, which allows supplying custom metadata when calling NewDescriptorInput. Add GetMetadata, which allows a user to parse custom metadata from a Descriptor.

Note that I've had to disable the unused linter, since the code in this PR triggers a panic in the linter. I've opened #269 to re-enable that in the future, once the bug is fixed.

@tri-adam tri-adam self-assigned this Mar 2, 2023
Add OptMetadata, which allows supplying custom metadata when calling
NewDescriptorInput. Add GetMetadata, which allows a user to parse custom
metadata from a Descriptor.
@tri-adam tri-adam marked this pull request as ready for review March 3, 2023 19:25
@codecov-commenter
Copy link

codecov-commenter commented Mar 6, 2023

Codecov Report

Merging #268 (6e2497e) into main (a29fb45) will increase coverage by 0.08%.
The diff coverage is 72.72%.

📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

@@            Coverage Diff             @@
##             main     #268      +/-   ##
==========================================
+ Coverage   72.64%   72.72%   +0.08%     
==========================================
  Files          35       35              
  Lines        2884     2904      +20     
==========================================
+ Hits         2095     2112      +17     
- Misses        636      638       +2     
- Partials      153      154       +1     
Impacted Files Coverage Δ
pkg/sif/descriptor.go 73.20% <63.63%> (+0.73%) ⬆️
pkg/sif/create.go 72.58% <100.00%> (ø)
pkg/sif/descriptor_input.go 86.44% <100.00%> (+0.39%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Switch to encoding.BinaryUnmarshaler/encoding.BinaryMarshaler for
GetMetadata/OptMetadata rather than "any" type.
Copy link
Member

@dtrudg dtrudg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@tri-adam tri-adam merged commit 5a9464b into sylabs:main Mar 6, 2023
@tri-adam tri-adam deleted the get-set-metadata branch March 6, 2023 18:08
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.

4 participants