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: respect custom JSON unmarshaler logic in protobuf resource specs #491

Merged

Conversation

utkuozdemir
Copy link
Member

If a protobuf spec implements json.Unmarshaler, use that function to unmarshal it from JSON, as the default protojson.UnmarshalOptions ignores it.

Add a test for both JSON and YAML custom unmarshaling logic.

If a protobuf spec implements `json.Unmarshaler`, use that function to unmarshal it from JSON, as the default `protojson.UnmarshalOptions` ignores it.

Add a test for both JSON and YAML custom unmarshaling logic.

Co-authored-by: Artem Chernyshev <[email protected]>
Signed-off-by: Utku Ozdemir <[email protected]>
@utkuozdemir utkuozdemir force-pushed the respect-custom-json-unmarshal branch from 2ef4774 to 8911486 Compare September 10, 2024 12:43
@utkuozdemir
Copy link
Member Author

/m

@talos-bot talos-bot merged commit 8911486 into cosi-project:main Sep 10, 2024
14 checks passed
@utkuozdemir utkuozdemir deleted the respect-custom-json-unmarshal branch September 10, 2024 13:05
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.

3 participants