Skip to content

Tests: Flakyness with ForkProcess #406

@amotl

Description

@amotl

Hi there,

I just wanted to report about a flakyness I observed when running tests on #401. Maybe it is related to the recent patch from #405.

Process ForkProcess-5:
 test_default_schema (crate.client.test_http.TestDefaultSchemaHeader)Traceback (most recent call last):
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/multiprocessing/process.py", line 258, in _bootstrap
    self.run()
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/multiprocessing/process.py", line 93, in run
    self._target(*self._args, **self._kwargs)
  File "/home/runner/work/crate-python/crate-python/src/crate/client/test_http.py", line 523, in run_server
    cls(server_address, request_handler_cls).serve_forever()
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/socketserver.py", line 456, in __init__
    self.server_bind()
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/http/server.py", line 136, in server_bind
    socketserver.TCPServer.server_bind(self)
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/socketserver.py", line 470, in server_bind
    self.socket.bind(self.server_address)
OSError: [Errno 98] Address already in use


Error in test test_default_schema (crate.client.test_http.TestDefaultSchemaHeader)
Traceback (most recent call last):
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/unittest/case.py", line 59, in testPartExecutor
    yield
  File "/opt/hostedtoolcache/Python/3.6.13/x64/lib/python3.6/unittest/case.py", line 605, in run
    testMethod()
  File "/home/runner/work/crate-python/crate-python/src/crate/client/test_http.py", line 590, in test_default_schema
    self.client.sql('SELECT 1')
  File "/home/runner/work/crate-python/crate-python/src/crate/client/http.py", line 396, in sql
    content = self._json_request('POST', self.path, data=data)
  File "/home/runner/work/crate-python/crate-python/src/crate/client/http.py", line 522, in _json_request
    response = self._request(method, path, data=data)
  File "/home/runner/work/crate-python/crate-python/src/crate/client/http.py", line 513, in _request
    self._drop_server(next_server, ex_message)
  File "/home/runner/work/crate-python/crate-python/src/crate/client/http.py", line 592, in _drop_server
    "exception from last server: %s") % message)
crate.client.exceptions.ConnectionError: No more Servers available, exception from last server: HTTPConnectionPool(host='127.0.0.1', port=65534): Read timed out. (read timeout=1)

With kind regards,
Andreas.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions