near-cli
near-cli copied to clipboard
Show error if connecting to unexpected version of the node
Currently old near-shell would either show nothing or show error saying "unexpected JSON output" which is unclear to user that near-shell must be updated.
quick design discussion: do we want to have the node version as a value that's available in Near object that's returned from nearlib connect? Pros: clients can implement whatever version checking code they want. Cons: need to access status on every connect call.
I think we need to access it any way - we need to query that: a) node is alive b) what version it is (and check that this nearlib can work with it) c) ideally, check that network is the same (and we are not viewing/ sending tx on invalid chain) d) probably going to add more meta-data there, like current pricing for gas and etc.
On Wed, Jul 31, 2019 at 3:06 PM janedegtiareva [email protected] wrote:
quick design discussion: do we want to have the node version as a value that's available in Near object that's returned from nearlib connect? Pros: clients can implement whatever version checking code they want. Cons: need to access status on every connect call.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/nearprotocol/near-shell/issues/71?email_source=notifications&email_token=AABK27TQJFSR5HJI7JVTMFTQCIEHNA5CNFSM4IFQ6X32YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3IWRGQ#issuecomment-517040282, or mute the thread https://github.com/notifications/unsubscribe-auth/AABK27QXCXEUZWZSMNELIPTQCIEHNANCNFSM4IFQ6X3Q .
-- Best regards, Illia Polosukhin