bnb-chain / greenfield-go-sdk

Go sdk for Greenfield

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

do API errors when push object

DarboLL opened this issue · comments

System information

Command version: gitd 482435fef91551248139de85f1d221d9c58216af
OS & Version: OSX
Commit hash : greenfield-go-sdk v0.2.3-hf.1

Expected behaviour

No errors

Actual behaviour

$ ../gitd/build/bin/gitd push origin main -f
{"level":"error","time":"2023-08-23T20:45:09+08:00","message":"do API error, url: https://0x646903f8653c671f101978569f186fefc2319f40-db-form-template.gnfd-testnet-sp1.bnbchain.org/refs/refs/heads/main, err: statusCode 406 : code : 110004 (Message: invalid payload data integrity hash)"}
PutObject err : statusCode 406 : code : 110004 (Message: invalid payload data integrity hash)
Repository push failed, error: statusCode 406 : code : 110004 (Message: invalid payload data integrity hash)

$ ../gitd/build/bin/gitd push origin main -f
{"level":"error","time":"2023-08-23T20:55:42+08:00","message":"do API error, url: https://gnfd-testnet-sp1.bnbchain.org/greenfield/admin/v1/get-approval?action=CreateObject, err: statusCode 400 : code : 20010 (Message: repeated object)"}
TxHash:
Repository push failed, error: statusCode 400 : code : 20010 (Message: repeated object)

Steps to reproduce the behaviour

Follow this tutorial, you can reproduce this issue when push to remote repo: https://docs.codexfield.com/getting-started/manage-code-through-gitd

However, we have try to use sleep between delete old objects and push the same name new object, this error will not happen, not sure is there any limitation when updating an object?

Backtrace

[backtrace]

When submitting logs: please submit them as text and not screenshots.

hello, @crypto-barbo

about invalid payload data integrity hash, this is a known issue and is already fixed in v0.2.4, please try again after the testnet reset.

About repeated object, please share more details. How do you name the new files? which functions are called?

Thanks!