mdorofeev / ton-client-kotlin

Kotlin bindings for TON Client Library
Apache License 2.0
9 stars 6 forks source link

update for readme example required #33

Closed asnov closed 2 years ago

asnov commented 2 years ago

Hey Maxim! Thank you for your support of Everscale SDK binding for kotlin!

I noticed one issue with the code example in README.md - It seems outdated. At least it gives me the next errors:

Suspend function 'ed25519Keypair' should be called only from a coroutine or another suspend function
Suspend function 'processMessage' should be called only from a coroutine or another suspend function
Suspend function 'query' should be called only from a coroutine or another suspend function

I know the meaning of this but it would be nice if you update the examples so that even beginners can use it as is. Thank you!

P.S. Also it would be great if you include imports in your examples so it could be copy/pasted and just work, something like:

import ee.nx01.tonclient.NetworkConfig
import ee.nx01.tonclient.TonClient
import ee.nx01.tonclient.TonClientConfig
import ee.nx01.tonclient.TonUtils
import ee.nx01.tonclient.abi.CallSet
import ee.nx01.tonclient.abi.KeyPair
import ee.nx01.tonclient.abi.ParamsOfEncodeMessage
import ee.nx01.tonclient.abi.Signer
import ee.nx01.tonclient.process.ParamsOfProcessMessage
import ee.nx01.tonclient.process.ResultOfProcessMessage
import ee.nx01.tonclient.types.AccountFilterInput
import ee.nx01.tonclient.types.StringFilterInput

Thank you again!

mdorofeev commented 2 years ago

Thanks for information. Little bit improved readme file, I hope it will help