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

DelegateResource function return txId not is real hash #93

Open
daihaoxiaofei opened this issue Aug 23, 2023 · 2 comments
Open

DelegateResource function return txId not is real hash #93

daihaoxiaofei opened this issue Aug 23, 2023 · 2 comments

Comments

@daihaoxiaofei
Copy link

func TestDelegate(t *testing.T) {
t.Skip() // Only in testnet nile
tx, err := conn.DelegateResource(testnetNileAddressExample, testnetNileAddressDelegateExample, core.ResourceCode_BANDWIDTH, 1000000, false)

require.Nil(t, err)
require.NotNil(t, tx.GetTxid())

}
tx.GetTxid() doesn't match what's queried in the block browser

How do I get the real transaction hash

@fbsobreira
Copy link
Owner

it should match, are you changing anything prior sign the TX? Like extra data or permission id?
If so you can use

func (g *GrpcClient) UpdateHash(tx *api.TransactionExtention) error {

@daihaoxiaofei
Copy link
Author

it should match, are you changing anything prior sign the TX? Like extra data or permission id? If so you can use

func (g *GrpcClient) UpdateHash(tx *api.TransactionExtention) error {

yes, i change my permission id !! You're awesome
Thank you so much for solving my problem

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

No branches or pull requests

2 participants