learnforpractice / pyeoskit

Python Toolkit for Eos
MIT License
16 stars 9 forks source link

how to set the connection to mainnet? #3

Closed softbug123 closed 4 years ago

softbug123 commented 4 years ago

when i run the push command,the python tell me:

WARNING:urllib3.connectionpool:Retrying (Retry(total=4, connect=None, read=None, redirect=0, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.HTTPConnection object at 0x0000028F4D9F9198>: Failed to establish a new connection: [WinError 10061] 由于目标计算机积极拒绝,无法连接。',)': /v1/chain/get_info

so,i found it connect the 127.0.0.1:8888,

how can i set the connectin info?

learnforpractice commented 4 years ago

from pyeoskit import eosapi eosapi.set_nodes(['http://127.0.0.1:8888'])

Change ['http://127.0.0.1:8888'] to ip addresses what ever you want.

There are some examples in:

https://github.com/learnforpractice/pyeoskit/blob/master/Docs/eosapi.ipynb https://github.com/learnforpractice/pyeoskit/blob/master/Docs/eosapi.ipynb

On Nov 5, 2019, at 9:16 AM, softbug123 notifications@github.com wrote:

when i run the push command,the python tell me:

WARNING:urllib3.connectionpool:Retrying (Retry(total=4, connect=None, read=None, redirect=0, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.HTTPConnection object at 0x0000028F4D9F9198>: Failed to establish a new connection: [WinError 10061] 由于目标计算机积极拒绝,无法连接。',)': /v1/chain/get_info

so,i found it connect the 127.0.0.1:8888,

how can i set the connectin info?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/learnforpractice/pyeoskit/issues/3?email_source=notifications&email_token=AHPJSPRLTIIZYCI4KJDXBCLQSDCNHA5CNFSM4JI4G3C2YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HWYKORQ, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHPJSPTO2X5UGNDIQYCAYLTQSDCNHANCNFSM4JI4G3CQ.

softbug123 commented 4 years ago

thanks! btw, in the pycharm,i can not see the auto hint for pyeoskit's class. do we have a sdk api refenerce list? i can not see the eosapi.set_nodes funciton if i dont ask u.

learnforpractice commented 4 years ago

This is an ongoing project. Any help will be appreciated.

Feel free to submit a pull request if you can.

On Nov 5, 2019, at 11:35 AM, softbug123 notifications@github.com wrote:

thanks! btw, in the pycharm,i can not see the auto hint for pyeoskit's class. do we have a sdk api refenerce list? i can not see the eosapi.set_nodes funciton if i dont ask u.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/learnforpractice/pyeoskit/issues/3?email_source=notifications&email_token=AHPJSPRBP23FRA7L3ROBQ43QSDSYPA5CNFSM4JI4G3C2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEDBPT7I#issuecomment-549648893, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHPJSPTOK6ZNWYD4R4GSLMDQSDSYPANCNFSM4JI4G3CQ.