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

[explorer] Updates Owned Objects to match RPC Model #1678

Merged
merged 5 commits into from
May 2, 2022
Merged

Conversation

apburnie
Copy link
Contributor

This updates the Owned Objects Component such that the Address Results now display owned objects:

image

Note that comprehensive testing is inhibited by apparent errors in the API.

@apburnie apburnie requested review from 666lcz, stella3d and Jibz1 April 29, 2022 20:32
@bwann52
Copy link
Contributor

bwann52 commented Apr 29, 2022

fungible objects should be aggregated (per previous discussion, default is aggregated view, and can expand by user action)

@666lcz 666lcz mentioned this pull request Apr 29, 2022
@666lcz
Copy link
Contributor

666lcz commented Apr 30, 2022

Error: Error fetching object info: Error: RPC Error: byte deserialization failed, cause by: Odd number of digits for id Please Wait

@Andrew47 , According to the error in the screenshot, somehow you are calling the SDK function with an invalid id called Please Wait, therefore this error is expected.

}

function GetObjectsAPI({ id }: { id: string }) {
const [objects, setObjects] = useState([{ objectId: 'Please Wait' }]);
Copy link
Contributor

Choose a reason for hiding this comment

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

import type { ObjectRef } from 'sui.js';

Suggested change
const [objects, setObjects] = useState([{ objectId: 'Please Wait' }]);
const [objects, setObjects] = useState<ObjectRef[]>([]);

This will help you get rid of the error

@666lcz 666lcz force-pushed the andrew/ownedObjects branch from ae467b0 to 52e6248 Compare May 2, 2022 01:10
@666lcz 666lcz merged commit 4a2e116 into main May 2, 2022
@666lcz 666lcz deleted the andrew/ownedObjects branch May 2, 2022 14:07
@666lcz
Copy link
Contributor

666lcz commented May 2, 2022

Merging this to main now and will address the comments in separate PRs

longbowlu pushed a commit that referenced this pull request May 12, 2022
Co-authored-by: Chris Li <666lcz@gmail.com>
punwai pushed a commit that referenced this pull request Jul 27, 2022
Co-authored-by: Chris Li <666lcz@gmail.com>
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