kinecosystem / agora

DEPRECATED! Please use Kinetic: https://developer.kin.org/docs/kinetic
https://developer.kin.org/docs/kinetic
MIT License
12 stars 6 forks source link

Tracking Errors in User Application #3

Open GEverding opened 3 years ago

GEverding commented 3 years ago

With the migration to solana it's become more important to be able to track specific error codes in our application. The current api for SubmitPayment only returns a simple error.

SubmitPayment(ctx context.Context, payment Payment, opts ...SolanaOption) (txHash []byte, err error)

Returning an actual error enum so it can be tracked in prometheus would be very helpful. Currently there is no list of all possible errors returned so its kind of a best effort to track errors.

chaseeb commented 3 years ago

i believe that list does exist in the go repository