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 BigInt remote object parsing #1133

Merged
merged 4 commits into from
Dec 15, 2023
Merged

Fix BigInt remote object parsing #1133

merged 4 commits into from
Dec 15, 2023

Conversation

ankur22
Copy link
Collaborator

@ankur22 ankur22 commented Dec 12, 2023

What?

This ensures that BigInt remote objects are parsed.

Why?

For an unknown reason BigInts are being set as UnserializableValue instead of the expected Value. This ensures that we correctly deal with the case of BigInt when it is a UnserializableValue.

Checklist

  • I have performed a self-review of my code
  • I have added tests for my changes
  • I have commented on my code, particularly in hard-to-understand areas

Related PR(s)/Issue(s)

Updates: #987

@ankur22 ankur22 changed the base branch from main to fix/panic-parse-remote-obj December 12, 2023 10:44
@ankur22 ankur22 requested review from inancgumus and ka3de December 12, 2023 11:38
inancgumus
inancgumus previously approved these changes Dec 13, 2023
Copy link
Member

@inancgumus inancgumus left a comment

Choose a reason for hiding this comment

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

👍

common/remote_object.go Outdated Show resolved Hide resolved
common/remote_object.go Outdated Show resolved Hide resolved
tests/remote_obj_test.go Outdated Show resolved Hide resolved
tests/remote_obj_test.go Show resolved Hide resolved
tests/remote_obj_test.go Show resolved Hide resolved
@ankur22 ankur22 force-pushed the fix/panic-parse-remote-obj branch 2 times, most recently from dbb0981 to 1a76aec Compare December 14, 2023 11:36
Base automatically changed from fix/panic-parse-remote-obj to main December 15, 2023 09:06
@ankur22 ankur22 dismissed inancgumus’s stale review December 15, 2023 09:06

The base branch was changed.

ankur22 added a commit that referenced this pull request Dec 15, 2023
@ankur22 ankur22 requested a review from inancgumus December 15, 2023 09:29
Copy link
Collaborator

@ka3de ka3de left a comment

Choose a reason for hiding this comment

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

LGTM.

ankur22 and others added 4 commits December 15, 2023 10:48
This integration test will evaluate objects which uses the existing
valueFromRemoteObject function in remote_object and not the latest
parseConsoleRemoteObject function.

In this change there are 3 commented out sub tests, 2 of which will be
fixed, and 1 will remain commented out until a fix for the linked issue
has been resolved.
For an unknown reason BigInt can't be parsed and is being set as a
UnserializableValue. To ensure that we parse it correctly to an int
we need to catch this case when dealing with other UnserializableValue.
Co-authored-by: İnanç Gümüş <[email protected]>
@ankur22 ankur22 merged commit 80603b3 into main Dec 15, 2023
16 checks passed
@ankur22 ankur22 deleted the add/array-parsing branch December 15, 2023 11:11
ankur22 added a commit that referenced this pull request Dec 15, 2023
ankur22 added a commit that referenced this pull request Dec 18, 2023
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