Skip to content

Conversation

@RomanovSci
Copy link
Member

Signed-off-by: Roman Bylbas romka.bulbas@gmail.com

Checklist

  • Code is properly formatted
  • All commits are signed
  • Tests included/updated or not needed
  • Documentation (manuals or wiki) has been updated or is not required

Signed-off-by: Roman Bylbas <romka.bulbas@gmail.com>
@RomanovSci RomanovSci requested review from ihor, mrkara and mssteuer June 24, 2022 12:56
@RomanovSci RomanovSci linked an issue Jun 24, 2022 that may be closed by this pull request
{
return array(
'node_id' => BlockHeaderSerializer::toJson($globalState->getBlockHeader()),
'address' => StoredValueSerializer::toJson($globalState->getStoredValue()),
Copy link
Member

Choose a reason for hiding this comment

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

The keys seem to be invalid

Copy link
Member

@ihor ihor left a comment

Choose a reason for hiding this comment

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

@RomanovSci please check my comments

Signed-off-by: Roman Bylbas <romka.bulbas@gmail.com>
@RomanovSci RomanovSci requested a review from ihor June 29, 2022 14:31
Copy link
Member

@ihor ihor left a comment

Choose a reason for hiding this comment

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

@RomanovSci please have a look at my comment

/**
* @throws RpcError
*/
public function getGlobalState(string $blockHash, string $key, array $path = []): GlobalState
Copy link
Member

Choose a reason for hiding this comment

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

Let's rename to getGlobalStateByBlock and add another one getGlobalStateByStateRootHash

Copy link
Member

Choose a reason for hiding this comment

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

In Python SDK they added an abstraction called GlobalStateID:

However, with only two possible values, having two separate methods will provide a simpler API for consumers

Signed-off-by: Roman Bylbas <romka.bulbas@gmail.com>
@RomanovSci RomanovSci merged commit 00ad7f8 into master Feb 8, 2023
@RomanovSci RomanovSci deleted the add_new_rpc_methods branch February 8, 2023 10:02
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.

Update PHP Client SDK Library as per updated Casper SDK Spec

2 participants