Skip to content

fix(python): serialize null values as None instead of empty tuple#344

Merged
dd-oleksii merged 1 commit intomainfrom
fix-python-null-as-none
Oct 13, 2025
Merged

fix(python): serialize null values as None instead of empty tuple#344
dd-oleksii merged 1 commit intomainfrom
fix-python-null-as-none

Conversation

@dd-oleksii
Copy link
Collaborator

Fixes #337.

Motivation and Context

Description

The issue was caused by serde_json::Value::Null being serialized as a unit, and serde_pyobject serializing units as empty tuples.

The fix is to implement a custom conversion to python for serde_json::Value which handles Null properly.

How has this been tested?

Added new test cases to sdk-test-data: Eppo-exp/sdk-test-data#138

@changeset-bot
Copy link

changeset-bot bot commented Oct 13, 2025

🦋 Changeset detected

Latest commit: 1f2dca5

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
Name Type
eppo_core Patch
python-sdk Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@dd-oleksii dd-oleksii merged commit 084fe1f into main Oct 13, 2025
40 of 47 checks passed
@dd-oleksii dd-oleksii deleted the fix-python-null-as-none branch October 13, 2025 14:32
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.

get_json_assignment returning empty tuples instead of None in Python

2 participants