vesoft-inc / nebula-python

Client API of Nebula Graph in Python
191 stars 75 forks source link

fix(SessinPoolExample.py): change port #272

Closed LaoshuBaby closed 1 year ago

LaoshuBaby commented 1 year ago

What type of PR is this?

What problem(s) does this PR solve?

Issue(s) number:

None

Current code will cause this error:

PS D:\Git\Playground\nebula-python\example> py SessinPoolExample.py
Traceback (most recent call last):
  File "C:\Environment\Python\Python311\Lib\site-packages\nebula3\fbthrift\transport\TSocket.py", line 286, in open
    handle.connect(address)
TimeoutError: timed out

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "D:\Git\Playground\nebula-python\example\SessinPoolExample.py", line 27, in <module>
    conn.open(ip, port, 1000)
  File "C:\Environment\Python\Python311\Lib\site-packages\nebula3\gclient\net\Connection.py", line 52, in open
    self.open_SSL(ip, port, timeout, None)
  File "C:\Environment\Python\Python311\Lib\site-packages\nebula3\gclient\net\Connection.py", line 89, in open_SSL
    header_transport.open()
  File "C:\Environment\Python\Python311\Lib\site-packages\nebula3\fbthrift\transport\THeaderTransport.py", line 247, in open
    return self.getTransport().open()
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Environment\Python\Python311\Lib\site-packages\nebula3\fbthrift\transport\TTransport.py", line 173, in open
    return self.__trans.open()
           ^^^^^^^^^^^^^^^^^^^
  File "C:\Environment\Python\Python311\Lib\site-packages\nebula3\fbthrift\transport\TSocket.py", line 301, in open
    raise TTransportException(TTransportException.NOT_OPEN, msg)
nebula3.fbthrift.transport.TTransport.TTransportException: socket error connecting to host 127.0.0.1, port 3699 (('127.0.0.1', 3699)): TimeoutError('timed out')

Description:

Nebula's default port had been changed to 9669 since 2.0.1-RC. Latest version still using 9669 port.

How do you solve it?

Change port variable's value

CLAassistant commented 1 year ago

CLA assistant check
All committers have signed the CLA.

codecov-commenter commented 1 year ago

Codecov Report

Patch and project coverage have no change.

Comparison is base (e96af4f) 77.62% compared to head (337d91e) 77.62%.

:mega: This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #272 +/- ## ======================================= Coverage 77.62% 77.62% ======================================= Files 18 18 Lines 2409 2409 ======================================= Hits 1870 1870 Misses 539 539 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

wey-gu commented 1 year ago

Thanks @LaoshuBaby for the contribution and welcome to the community!