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

fix(py): Invalid serialization of float and int constants #1427

Merged
merged 1 commit into from
Aug 14, 2024

Conversation

aborgna-q
Copy link
Collaborator

Fixes #1424

I updated the roundtrip validation to compare decoded jsons rather than strings.

The values were manually compared against a rust serialization output. We cannot do better without python-side extension loading.

@aborgna-q aborgna-q requested a review from a team as a code owner August 14, 2024 10:29
@aborgna-q aborgna-q requested a review from mark-koch August 14, 2024 10:29
Copy link

codecov bot commented Aug 14, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 87.58%. Comparing base (c6473c9) to head (1e4b2fe).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1427   +/-   ##
=======================================
  Coverage   87.58%   87.58%           
=======================================
  Files         119      119           
  Lines       20751    20755    +4     
  Branches    18045    18045           
=======================================
+ Hits        18174    18178    +4     
  Misses       1789     1789           
  Partials      788      788           
Flag Coverage Δ
python 90.51% <100.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@aborgna-q aborgna-q added this pull request to the merge queue Aug 14, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to a conflict with the base branch Aug 14, 2024
@aborgna-q aborgna-q force-pushed the ab/fix-py-const-serialise branch from 7e04dbd to 1e4b2fe Compare August 14, 2024 12:44
@aborgna-q aborgna-q added this pull request to the merge queue Aug 14, 2024
Merged via the queue into main with commit b89c08f Aug 14, 2024
21 checks passed
@aborgna-q aborgna-q deleted the ab/fix-py-const-serialise branch August 14, 2024 12:52
github-merge-queue bot pushed a commit that referenced this pull request Aug 14, 2024
🤖 I have created a release *beep* *boop*
---


##
[0.7.0](hugr-py-v0.6.0...hugr-py-v0.7.0)
(2024-08-14)


### ⚠ BREAKING CHANGES

* **hugr-py:** `AsCustomOp` replaced with `AsExtOp`, so all such
operations now need to be attached to an extension.

### Features

* **hugr-py:** user facing Extension class
([#1413](#1413))
([c6473c9](c6473c9))
* **py:** Add node metadata
([#1428](#1428))
([b229be6](b229be6)),
closes [#1319](#1319)


### Bug Fixes

* Equality check between `Sum` types
([#1422](#1422))
([8dfea09](8dfea09))
* **py:** Invalid serialization of float and int constants
([#1427](#1427))
([b89c08f](b89c08f))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

---------

Co-authored-by: Agustín Borgna <[email protected]>
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.

Mismatched serialisation of Consts between rust and python
2 participants