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

Set state endpoint #7

Merged
merged 10 commits into from
Dec 21, 2023
Merged

Set state endpoint #7

merged 10 commits into from
Dec 21, 2023

Conversation

miiu96
Copy link
Contributor

@miiu96 miiu96 commented Dec 6, 2023

@miiu96 miiu96 self-assigned this Dec 6, 2023
@miiu96 miiu96 marked this pull request as ready for review December 11, 2023 14:56
return sf.simulator.SetKeyValueForAddress(address, keyValueMap)
}

func (sf *simulatorFacade) SetStateMultiple(stateSlice []*dtos.AddressState) error {
Copy link
Contributor

Choose a reason for hiding this comment

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

missing comment

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

},
{
"address": "erd1lllllllllllllllllllllllllllllllllllllllllllllllllllsckry7t",
"shardID": 0,
Copy link
Contributor

Choose a reason for hiding this comment

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

Not needed to repeat 3 times if you apply my suggestion :)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

# sign transaction
user_signer = UserSigner(pem.secret_key)
tx_computer = TransactionComputer()
call_transaction.signature = user_signer.sign(tx_computer.compute_bytes_for_signing(call_transaction))
Copy link
Contributor

Choose a reason for hiding this comment

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

is this needed? Should we allow the script to work also on the regular gateways?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Added the signing part for the example purpose.
Script will not work because calls extra endpoints to generate blocks

@miiu96 miiu96 merged commit f1c0be4 into main Dec 21, 2023
3 checks passed
@iulianpascalau iulianpascalau deleted the set-state-endpoint branch December 21, 2023 17:05
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