elastic / elasticsearch-py

Official Python client for Elasticsearch
https://ela.st/es-python
Apache License 2.0
4.23k stars 1.18k forks source link

7.14.0: pytest is failing #1705

Closed kloczek closed 3 years ago

kloczek commented 3 years ago

I'm trying to package your module as an rpm package. So I'm using the typical build, install and test cycle used on building packages from non-root account.

I have impression that test suite requires running elasticsearch service. If that is true pytest should start/stop that et the beginning/end of the testing session.

---------------------------------------------------------------------------- Captured log setup ----------------------------------------------------------------------------
WARNING  elasticsearch:base.py:293 GET https://localhost:9200/ [status:N/A request:0.002s]
Traceback (most recent call last):
  File "/usr/lib64/python3.8/site-packages/aiohttp/connector.py", line 969, in _wrap_create_connection
    return await self._loop.create_connection(*args, **kwargs)  # type: ignore  # noqa
  File "/usr/lib64/python3.8/asyncio/base_events.py", line 1025, in create_connection
    raise exceptions[0]
  File "/usr/lib64/python3.8/asyncio/base_events.py", line 1010, in create_connection
    sock = await self._connect_sock(
  File "/usr/lib64/python3.8/asyncio/base_events.py", line 924, in _connect_sock
    await self.sock_connect(sock, address)
  File "/usr/lib64/python3.8/asyncio/selector_events.py", line 496, in sock_connect
    return await fut
  File "/usr/lib64/python3.8/asyncio/selector_events.py", line 528, in _sock_connect_cb
    raise OSError(err, f'Connect call failed {address}')
ConnectionRefusedError: [Errno 111] Connect call failed ('127.0.0.1', 9200)

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/elasticsearch/_async/http_aiohttp.py", line 291, in perform_request
    async with self.session.request(
  File "/usr/lib64/python3.8/site-packages/aiohttp/client.py", line 1117, in __aenter__
    self._resp = await self._coro
  File "/usr/lib64/python3.8/site-packages/aiohttp/client.py", line 520, in _request
    conn = await self._connector.connect(
  File "/usr/lib64/python3.8/site-packages/aiohttp/connector.py", line 535, in connect
    proto = await self._create_connection(req, traces, timeout)
  File "/usr/lib64/python3.8/site-packages/aiohttp/connector.py", line 892, in _create_connection
    _, proto = await self._create_direct_connection(req, traces, timeout)
  File "/usr/lib64/python3.8/site-packages/aiohttp/connector.py", line 1051, in _create_direct_connection
    raise last_exc
  File "/usr/lib64/python3.8/site-packages/aiohttp/connector.py", line 1020, in _create_direct_connection
    transp, proto = await self._wrap_create_connection(
  File "/usr/lib64/python3.8/site-packages/aiohttp/connector.py", line 975, in _wrap_create_connection
    raise client_error(req.connection_key, exc) from exc
aiohttp.client_exceptions.ClientConnectorError: Cannot connect to host localhost:9200 ssl:default [Connect call failed ('127.0.0.1', 9200)]
WARNING  elasticsearch:base.py:293 GET https://localhost:9200/ [status:N/A request:0.000s]
Traceback (most recent call last):
  File "/usr/lib64/python3.8/site-packages/aiohttp/connector.py", line 969, in _wrap_create_connection
    return await self._loop.create_connection(*args, **kwargs)  # type: ignore  # noqa
  File "/usr/lib64/python3.8/asyncio/base_events.py", line 1025, in create_connection
    raise exceptions[0]
  File "/usr/lib64/python3.8/asyncio/base_events.py", line 1010, in create_connection
    sock = await self._connect_sock(
  File "/usr/lib64/python3.8/asyncio/base_events.py", line 924, in _connect_sock
    await self.sock_connect(sock, address)
  File "/usr/lib64/python3.8/asyncio/selector_events.py", line 496, in sock_connect
    return await fut
  File "/usr/lib64/python3.8/asyncio/selector_events.py", line 528, in _sock_connect_cb
    raise OSError(err, f'Connect call failed {address}')
ConnectionRefusedError: [Errno 111] Connect call failed ('127.0.0.1', 9200)

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/elasticsearch/_async/http_aiohttp.py", line 291, in perform_request
    async with self.session.request(
  File "/usr/lib64/python3.8/site-packages/aiohttp/client.py", line 1117, in __aenter__
    self._resp = await self._coro
  File "/usr/lib64/python3.8/site-packages/aiohttp/client.py", line 520, in _request
    conn = await self._connector.connect(
  File "/usr/lib64/python3.8/site-packages/aiohttp/connector.py", line 535, in connect
    proto = await self._create_connection(req, traces, timeout)
  File "/usr/lib64/python3.8/site-packages/aiohttp/connector.py", line 892, in _create_connection
    _, proto = await self._create_direct_connection(req, traces, timeout)
  File "/usr/lib64/python3.8/site-packages/aiohttp/connector.py", line 1051, in _create_direct_connection
    raise last_exc
  File "/usr/lib64/python3.8/site-packages/aiohttp/connector.py", line 1020, in _create_direct_connection
    transp, proto = await self._wrap_create_connection(
  File "/usr/lib64/python3.8/site-packages/aiohttp/connector.py", line 975, in _wrap_create_connection
    raise client_error(req.connection_key, exc) from exc
aiohttp.client_exceptions.ClientConnectorError: Cannot connect to host localhost:9200 ssl:default [Connect call failed ('127.0.0.1', 9200)]

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/test_elasticsearch/test_async/test_server/conftest.py", line 43, in async_client
    await client.cluster.health(wait_for_status="yellow")
  File "/home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/elasticsearch/_async/client/cluster.py", line 66, in health
    return await self.transport.perform_request(
  File "/home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/elasticsearch/_async/transport.py", line 340, in perform_request
    await self._do_verify_elasticsearch(headers=headers, timeout=timeout)
  File "/home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/elasticsearch/_async/transport.py", line 492, in _do_verify_elasticsearch
    raise error
  File "/home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/elasticsearch/_async/transport.py", line 455, in _do_verify_elasticsearch
    _, info_headers, info_response = await conn.perform_request(
  File "/home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/elasticsearch/_async/http_aiohttp.py", line 324, in perform_request
    raise ConnectionError("N/A", str(e), e)
elasticsearch.exceptions.ConnectionError: ConnectionError(Cannot connect to host localhost:9200 ssl:default [Connect call failed ('127.0.0.1', 9200)]) caused by: ClientConnectorError(Cannot connect to host localhost:9200 ssl:default [Connect call failed ('127.0.0.1', 9200)])

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3.8/site-packages/urllib3/connection.py", line 169, in _new_conn
    conn = connection.create_connection(
  File "/usr/lib/python3.8/site-packages/urllib3/util/connection.py", line 96, in create_connection
    raise err
  File "/usr/lib/python3.8/site-packages/urllib3/util/connection.py", line 86, in create_connection
    sock.connect(sa)
ConnectionRefusedError: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/elasticsearch/connection/http_urllib3.py", line 251, in perform_request
    response = self.pool.urlopen(
  File "/usr/lib/python3.8/site-packages/urllib3/connectionpool.py", line 755, in urlopen
    retries = retries.increment(
  File "/usr/lib/python3.8/site-packages/urllib3/util/retry.py", line 507, in increment
    raise six.reraise(type(error), error, _stacktrace)
  File "/usr/lib/python3.8/site-packages/urllib3/packages/six.py", line 770, in reraise
    raise value
  File "/usr/lib/python3.8/site-packages/urllib3/connectionpool.py", line 699, in urlopen
    httplib_response = self._make_request(
  File "/usr/lib/python3.8/site-packages/urllib3/connectionpool.py", line 382, in _make_request
    self._validate_conn(conn)
  File "/usr/lib/python3.8/site-packages/urllib3/connectionpool.py", line 1010, in _validate_conn
    conn.connect()
  File "/usr/lib/python3.8/site-packages/urllib3/connection.py", line 353, in connect
    conn = self._new_conn()
  File "/usr/lib/python3.8/site-packages/urllib3/connection.py", line 181, in _new_conn
    raise NewConnectionError(
urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x7f8d0ae5a940>: Failed to establish a new connection: [Errno 111] Connection refused
============================================================================= warnings summary =============================================================================
test_elasticsearch/test_server/test_rest_api_spec.py:562
  /home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/test_elasticsearch/test_server/test_rest_api_spec.py:562: UserWarning: Could not load REST API tests: Elasticsearch failed to start.
    warnings.warn("Could not load REST API tests: %s" % (str(e),))

test_elasticsearch/test_serializer.py::TestJSONSerializer::test_serializes_numpy_floats
test_elasticsearch/test_serializer.py::TestJSONSerializer::test_serializes_numpy_floats
test_elasticsearch/test_serializer.py::TestJSONSerializer::test_serializes_numpy_floats
  /home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/test_elasticsearch/test_serializer.py:103: DeprecationWarning: Please use assertRegex instead.
    self.assertRegexpMatches(

test_elasticsearch/test_transport.py::TestTransport::test_client_meta_header
  /home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/test_elasticsearch/test_transport.py:214: DeprecationWarning: Please use assertRegex instead.
    self.assertRegexpMatches(

test_elasticsearch/test_transport.py::TestTransport::test_client_meta_header
  /home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/test_elasticsearch/test_transport.py:227: DeprecationWarning: Please use assertRegex instead.
    self.assertRegexpMatches(

test_elasticsearch/test_async/test_server/test_helpers.py: 31 warnings
test_elasticsearch/test_async/test_server/test_clients.py: 4 warnings
  /home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/elasticsearch/connection/http_urllib3.py:209: UserWarning: Connecting to https://localhost:9200 using SSL with verify_certs=False is insecure.
    warnings.warn(

-- Docs: https://docs.pytest.org/en/stable/warnings.html
========================================================================= short test summary info ==========================================================================
SKIPPED [1] test_elasticsearch/test_server/test_rest_api_spec.py:567: got empty parameter set ['test_spec'], function test_rest_api_spec at /home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/test_elasticsearch/test_server/test_rest_api_spec.py:566
SKIPPED [32] ../../../../../usr/lib/python3.8/site-packages/_pytest/unittest.py:355: No client is available
SKIPPED [1] test_elasticsearch/test_client/test_utils.py:129: Only relevant for py2
SKIPPED [1] test_elasticsearch/test_helpers.py:60: unconditional skip
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_clear_scroll - elasticsearch.exceptions.ConnectionError: ConnectionError(<urllib3.connect...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_scan_auth_kwargs_favor_scroll_kwargs_option - elasticsearch.exceptions.ConnectionError: C...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_order_can_be_preserved - elasticsearch.exceptions.ConnectionError: ConnectionError(<urlli...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_logger - elasticsearch.exceptions.ConnectionError: ConnectionError(<urllib3.connection.HT...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_all_documents_are_read - elasticsearch.exceptions.ConnectionError: ConnectionError(<urlli...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_scan_auth_kwargs_forwarded[kwargs0] - elasticsearch.exceptions.ConnectionError: Connectio...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_scan_auth_kwargs_forwarded[kwargs2] - elasticsearch.exceptions.ConnectionError: Connectio...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_no_scroll_id_fast_route - elasticsearch.exceptions.ConnectionError: ConnectionError(<urll...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_initial_search_error - elasticsearch.exceptions.ConnectionError: ConnectionError(<urllib3...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_scroll_error - elasticsearch.exceptions.ConnectionError: ConnectionError(<urllib3.connect...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_scan_auth_kwargs_forwarded[kwargs1] - elasticsearch.exceptions.ConnectionError: Connectio...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestParentChildReindex::test_children_are_reindexed_correctly - elasticsearch.exceptions.ConnectionError...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestReindex::test_all_documents_get_moved - elasticsearch.exceptions.ConnectionError: ConnectionError(<u...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestReindex::test_reindex_passes_kwargs_to_scan_and_bulk - elasticsearch.exceptions.ConnectionError: Con...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestReindex::test_reindex_accepts_a_query - elasticsearch.exceptions.ConnectionError: ConnectionError(<u...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_all_documents_get_inserted - elasticsearch.exceptions.ConnectionError: Connectio...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_all_errors_from_chunk_are_raised_on_failure - elasticsearch.exceptions.Connectio...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_rejected_documents_are_retried - elasticsearch.exceptions.ConnectionError: Conne...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_documents_data_types - elasticsearch.exceptions.ConnectionError: ConnectionError...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_different_op_types - elasticsearch.exceptions.ConnectionError: ConnectionError(<...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_actions_remain_unchanged - elasticsearch.exceptions.ConnectionError: ConnectionE...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_transport_error_is_raised_with_max_retries - elasticsearch.exceptions.Connection...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_transport_error_can_becaught - elasticsearch.exceptions.ConnectionError: Connect...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_rejected_documents_are_retried_at_most_max_retries_times - elasticsearch.excepti...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_stats_only_reports_numbers - elasticsearch.exceptions.ConnectionError: ConnectionError(<u...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_all_documents_get_inserted - elasticsearch.exceptions.ConnectionError: ConnectionError(<u...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_ignore_error_if_raised - elasticsearch.exceptions.ConnectionError: ConnectionError(<urlli...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_errors_are_collected_properly - elasticsearch.exceptions.ConnectionError: ConnectionError...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_error_is_raised - elasticsearch.exceptions.ConnectionError: ConnectionError(<urllib3.conn...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_errors_are_reported_correctly - elasticsearch.exceptions.ConnectionError: ConnectionError...
ERROR test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_bulk_works_with_single_item - elasticsearch.exceptions.ConnectionError: ConnectionError(<...
ERROR test_elasticsearch/test_async/test_server/test_clients.py::TestBulk::test_bulk_works_with_string_body - elasticsearch.exceptions.ConnectionError: ConnectionError(<...
ERROR test_elasticsearch/test_async/test_server/test_clients.py::TestBulk::test_bulk_works_with_bytestring_body - elasticsearch.exceptions.ConnectionError: ConnectionErr...
ERROR test_elasticsearch/test_async/test_server/test_clients.py::TestUnicode::test_indices_analyze - elasticsearch.exceptions.ConnectionError: ConnectionError(<urllib3.c...
ERROR test_elasticsearch/test_async/test_server/test_clients.py::TestYarlMissing::test_aiohttp_connection_works_without_yarl - elasticsearch.exceptions.ConnectionError: ...
========================================================= 288 passed, 35 skipped, 41 warnings, 35 errors in 47.07s =========================================================
kloczek commented 3 years ago

After deselecting all failing units still there are some warnings:

+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-elasticsearch-7.14.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-elasticsearch-7.14.0-2.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra --deselect test_elasticsearch/test_async/test_server/test_clients.py::TestBulk::test_bulk_works_with_bytestring_body --deselect test_elasticsearch/test_async/test_server/test_clients.py::TestBulk::test_bulk_works_with_string_body --deselect test_elasticsearch/test_async/test_server/test_clients.py::TestUnicode::test_indices_analyze --deselect test_elasticsearch/test_async/test_server/test_clients.py::TestYarlMissing::test_aiohttp_connection_works_without_yarl --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_all_documents_get_inserted --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_bulk_works_with_single_item --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_error_is_raised --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_errors_are_collected_properly --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_errors_are_reported_correctly --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_ignore_error_if_raised --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestBulk::test_stats_only_reports_numbers --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestParentChildReindex::test_children_are_reindexed_correctly --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestReindex::test_all_documents_get_moved --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestReindex::test_reindex_accepts_a_query --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestReindex::test_reindex_passes_kwargs_to_scan_and_bulk --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_all_documents_are_read --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_clear_scroll --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_initial_search_error --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_logger --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_no_scroll_id_fast_route --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_order_can_be_preserved --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_scan_auth_kwargs_favor_scroll_kwargs_option --deselect 'test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_scan_auth_kwargs_forwarded[kwargs0]' --deselect 'test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_scan_auth_kwargs_forwarded[kwargs1]' --deselect 'test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_scan_auth_kwargs_forwarded[kwargs2]' --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestScan::test_scroll_error --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_actions_remain_unchanged --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_all_documents_get_inserted --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_all_errors_from_chunk_are_raised_on_failure --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_different_op_types --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_documents_data_types --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_rejected_documents_are_retried --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_rejected_documents_are_retried_at_most_max_retries_times --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_transport_error_can_becaught --deselect test_elasticsearch/test_async/test_server/test_helpers.py::TestStreamingBulk::test_transport_error_is_raised_with_max_retries
=========================================================================== test session starts ============================================================================
platform linux -- Python 3.8.11, pytest-6.2.5, py-1.10.0, pluggy-0.13.1
benchmark: 3.4.1 (defaults: timer=time.perf_counter disable_gc=False min_rounds=5 min_time=0.000005 max_time=1.0 calibration_precision=10 warmup=False warmup_iterations=100000)
Using --randomly-seed=611976949
rootdir: /home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0, configfile: setup.cfg
plugins: forked-1.3.0, shutil-1.7.0, virtualenv-1.7.0, expect-1.1.0, flake8-1.0.7, timeout-1.4.2, betamax-0.8.1, freezegun-0.4.2, aspectlib-1.5.2, toolbox-0.5, rerunfailures-9.1.1, requests-mock-1.9.3, cov-2.12.1, flaky-3.7.0, benchmark-3.4.1, xdist-2.3.0, pylama-7.7.1, datadir-1.3.1, regressions-2.2.0, cases-3.6.3, xprocess-0.18.1, black-0.3.12, anyio-3.3.0, asyncio-0.15.1, trio-0.7.0, subtests-0.5.0, isort-2.0.0, hypothesis-6.14.6, mock-3.6.1, profiling-1.7.0, randomly-3.8.0, Faker-8.12.1, nose2pytest-1.0.8, pyfakefs-4.5.1, tornado-0.8.1, twisted-1.13.3
collected 358 items / 35 deselected / 323 selected

test_elasticsearch/test_server/test_clients.py sss                                                                                                                   [  0%]
test_elasticsearch/test_helpers.py ..........s                                                                                                                       [  4%]
test_elasticsearch/test_exceptions.py ..                                                                                                                             [  4%]
test_elasticsearch/test_server/test_helpers.py sssssssssssssssssssssssssssss                                                                                         [ 13%]
test_elasticsearch/test_transport.py ...............................................................                                                                 [ 33%]
test_elasticsearch/test_connection.py ................................................................                                                               [ 53%]
test_elasticsearch/test_client/test_overrides.py ...............                                                                                                     [ 57%]
test_elasticsearch/test_client/test_cluster.py ...                                                                                                                   [ 58%]
test_elasticsearch/test_connection_pool.py ..............                                                                                                            [ 63%]
test_elasticsearch/test_server/test_rest_api_spec.py s                                                                                                               [ 63%]
test_elasticsearch/test_client/test_utils.py ...s..........                                                                                                          [ 67%]
test_elasticsearch/test_utils.py ...                                                                                                                                 [ 68%]
test_elasticsearch/test_client/test_indices.py .....                                                                                                                 [ 70%]
test_elasticsearch/test_serializer.py ........................                                                                                                       [ 77%]
test_elasticsearch/test_async/test_transport.py ...........................................                                                                          [ 91%]
test_elasticsearch/test_cases.py ...                                                                                                                                 [ 91%]
test_elasticsearch/test_async/test_connection.py ..........................                                                                                          [100%]

============================================================================= warnings summary =============================================================================
test_elasticsearch/test_server/test_rest_api_spec.py:562
  /home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/test_elasticsearch/test_server/test_rest_api_spec.py:562: UserWarning: Could not load REST API tests: Elasticsearch failed to start.
    warnings.warn("Could not load REST API tests: %s" % (str(e),))

test_elasticsearch/test_transport.py::TestTransport::test_client_meta_header
  /home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/test_elasticsearch/test_transport.py:214: DeprecationWarning: Please use assertRegex instead.
    self.assertRegexpMatches(

test_elasticsearch/test_transport.py::TestTransport::test_client_meta_header
  /home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/test_elasticsearch/test_transport.py:227: DeprecationWarning: Please use assertRegex instead.
    self.assertRegexpMatches(

test_elasticsearch/test_serializer.py::TestJSONSerializer::test_serializes_numpy_floats
test_elasticsearch/test_serializer.py::TestJSONSerializer::test_serializes_numpy_floats
test_elasticsearch/test_serializer.py::TestJSONSerializer::test_serializes_numpy_floats
  /home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/test_elasticsearch/test_serializer.py:103: DeprecationWarning: Please use assertRegex instead.
    self.assertRegexpMatches(

-- Docs: https://docs.pytest.org/en/stable/warnings.html
========================================================================= short test summary info ==========================================================================
SKIPPED [32] ../../../../../usr/lib/python3.8/site-packages/_pytest/unittest.py:355: No client is available
SKIPPED [1] test_elasticsearch/test_helpers.py:60: unconditional skip
SKIPPED [1] test_elasticsearch/test_server/test_rest_api_spec.py:567: got empty parameter set ['test_spec'], function test_rest_api_spec at /home/tkloczko/rpmbuild/BUILD/elasticsearch-py-7.14.0/test_elasticsearch/test_server/test_rest_api_spec.py:566
SKIPPED [1] test_elasticsearch/test_client/test_utils.py:129: Only relevant for py2
======================================================= 288 passed, 35 skipped, 35 deselected, 6 warnings in 32.02s ========================================================
pytest-xprocess reminder::Be sure to terminate the started process by running 'pytest --xkill' if you have not explicitly done so in your fixture with 'xprocess.getinfo(<process_name>).terminate()'.
sethmlarson commented 3 years ago

You're correct that you need an Elasticsearch service running however it's always been the case that you need to start your own to choose the version and other options. This is documented in CONTRIBUTING.md.

kloczek commented 3 years ago

That is fine. Will check that. Thx. What about those DeprecationWarning warnings?

sethmlarson commented 3 years ago

:shrug: On main we've moved completely over to pytest so I'm not as worried about them.

kloczek commented 3 years ago

Just humble question: so you have some plan to make new release? (just asking to coordinate tat possibility wit h other points from my bug/todo list).

Thx to let me know.

sethmlarson commented 3 years ago

New stable releases follow the Elastic Stack so 7.14.1 will be next.