-
-
Notifications
You must be signed in to change notification settings - Fork 182
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
2.12.3: pytest fails #1108
Comments
Something should be started on localhost before start testing? 🤔 Here is pytest summary output:================================================================================== short test summary info ==================================================================================
XFAIL tests/test_basic_s3.py::test_put_object_sha256[False-https] - moto does not yet support Checksum: https://github.com/spulec/moto/issues/5719
XFAIL tests/test_basic_s3.py::test_put_object_sha256[False-https] - moto does not yet support Checksum: https://github.com/spulec/moto/issues/5719
ERROR tests/test_basic_s3.py::test_can_get_bucket_location - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:58557/ybtodjnqwzlaichpefvxsumgkr"
ERROR tests/test_basic_s3.py::test_can_get_bucket_location - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:58557/ybtodjnqwzlaichpefvxsumgkr?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_can_delete_urlencoded_object - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:34151/ohmfxlgawkruqzipnejybdvcst"
ERROR tests/test_basic_s3.py::test_can_delete_urlencoded_object - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:34151/ohmfxlgawkruqzipnejybdvcst?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_can_paginate - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:50193/cakuiyqdfvpbwghlzmeosrnxtj"
ERROR tests/test_basic_s3.py::test_can_paginate - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:50193/cakuiyqdfvpbwghlzmeosrnxtj?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_can_paginate_with_page_size - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:42695/eljwkdtgorpymhnzcvfquxsbai"
ERROR tests/test_basic_s3.py::test_can_paginate_with_page_size - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:42695/eljwkdtgorpymhnzcvfquxsbai?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_can_search_paginate - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:44009/ybwrvqdtnfazjimhkcpoxlsueg"
ERROR tests/test_basic_s3.py::test_can_search_paginate - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:44009/ybwrvqdtnfazjimhkcpoxlsueg?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_can_paginate_iterator - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:48513/dczrubqnwetoyiskvmghpxjalf"
ERROR tests/test_basic_s3.py::test_can_paginate_iterator - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:48513/dczrubqnwetoyiskvmghpxjalf?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_result_key_iters - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:42873/cxdybsrfqtapvehjunkiglwmoz"
ERROR tests/test_basic_s3.py::test_result_key_iters - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:42873/cxdybsrfqtapvehjunkiglwmoz?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_can_get_and_put_object - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:53283/huwprtjdaqxigolsezbfncmvky"
ERROR tests/test_basic_s3.py::test_can_get_and_put_object - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:53283/huwprtjdaqxigolsezbfncmvky?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_adaptive_retry - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:55537/yiphswuqmjaonefbxzcvdrtklg"
ERROR tests/test_basic_s3.py::test_adaptive_retry - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:55537/yiphswuqmjaonefbxzcvdrtklg?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_get_object_stream_wrapper - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:38019/keucinvgxbjosatzqdrhwpylmf"
ERROR tests/test_basic_s3.py::test_get_object_stream_wrapper - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:38019/keucinvgxbjosatzqdrhwpylmf?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_get_object_stream_context - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:40089/hsdptiynbwumrflcvxgakeozjq"
ERROR tests/test_basic_s3.py::test_get_object_stream_context - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:40089/hsdptiynbwumrflcvxgakeozjq?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_paginate_max_items - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:39889/jatxezksfcdwunqlyvhrobmipg"
ERROR tests/test_basic_s3.py::test_paginate_max_items - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:39889/jatxezksfcdwunqlyvhrobmipg?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_paginate_within_page_boundaries - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:39313/xdytrasozkmgivbnlqufhpcejw"
ERROR tests/test_basic_s3.py::test_paginate_within_page_boundaries - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:39313/xdytrasozkmgivbnlqufhpcejw?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_non_normalized_key_paths - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:40289/ciqtwpluxjbrvzefhymgsnakod"
ERROR tests/test_basic_s3.py::test_non_normalized_key_paths - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:40289/ciqtwpluxjbrvzefhymgsnakod?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_copy_with_quoted_char - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:52523/thsozalrnxicfejqywmpudbkvg"
ERROR tests/test_basic_s3.py::test_copy_with_quoted_char - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:52523/thsozalrnxicfejqywmpudbkvg?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_copy_with_query_string - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:53915/lqtjnpdfuowigkmvyrsbcahzex"
ERROR tests/test_basic_s3.py::test_copy_with_query_string - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:53915/lqtjnpdfuowigkmvyrsbcahzex?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_can_copy_with_dict_form - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:44801/nxkaotfjqwdyvbrzmhcilgeups"
ERROR tests/test_basic_s3.py::test_can_copy_with_dict_form - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:44801/nxkaotfjqwdyvbrzmhcilgeups?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_can_copy_with_dict_form_with_version - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:53651/yshgivkjlnprwequtzfcdambox"
ERROR tests/test_basic_s3.py::test_can_copy_with_dict_form_with_version - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:53651/yshgivkjlnprwequtzfcdambox?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_copy_with_s3_metadata - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:50131/nrcphykoiutdsvgzfwqxjaelbm"
ERROR tests/test_basic_s3.py::test_copy_with_s3_metadata - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:50131/nrcphykoiutdsvgzfwqxjaelbm?versions&prefix=&encoding-type=url"
ERROR tests/test_basic_s3.py::test_head_object_keys[s3v4] - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:57279/hknxbczrgtyiwsomluqejpadfv"
ERROR tests/test_basic_s3.py::test_head_object_keys[s3v4] - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:57279/hknxbczrgtyiwsomluqejpadfv?versions&prefix=&encoding-type=url"
ERROR tests/test_dynamodb.py::test_get_item[v4] - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:37679/"
ERROR tests/test_dynamodb.py::test_get_item[v4] - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:37679/"
ERROR tests/test_dynamodb.py::test_batch_write_scan[v4] - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:39433/"
ERROR tests/test_dynamodb.py::test_batch_write_scan[v4] - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:39433/"
ERROR tests/test_sns.py::test_topic_attributes - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:36799/"
ERROR tests/test_sns.py::test_topic_attributes - botocore.exceptions.ParamValidationError: Parameter validation failed:
ERROR tests/test_sns.py::test_creating_subscription - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:47047/"
ERROR tests/test_sns.py::test_creating_subscription - botocore.exceptions.ParamValidationError: Parameter validation failed:
ERROR tests/test_sns.py::test_publish_to_http - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:43591/"
ERROR tests/test_sns.py::test_publish_to_http - botocore.exceptions.ParamValidationError: Parameter validation failed:
ERROR tests/test_sqs.py::test_list_queues - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:36499/"
ERROR tests/test_sqs.py::test_get_queue_name - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:33881/"
ERROR tests/test_sqs.py::test_put_pull_delete_test - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:48055/"
ERROR tests/test_sqs.py::test_put_pull_wait - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:47327/"
FAILED tests/test_basic_s3.py::test_can_make_request - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:41419/"
FAILED tests/test_basic_s3.py::test_can_make_request_no_verify[False] - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:40971/"
FAILED tests/test_batch.py::test_batch - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:57597/v1/describejobqueues"
FAILED tests/test_dynamodb.py::test_create_waiter[v4] - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:39859/"
FAILED tests/test_dynamodb.py::test_delete_table[v4] - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:40409/"
FAILED tests/test_dynamodb.py::test_waiter_table_exists_failure[v4] - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:53991/"
FAILED tests/test_dynamodb.py::test_waiter_table_exists[v4] - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:43203/"
FAILED tests/test_ec2.py::test_ec2_snapshot - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:60839/"
FAILED tests/test_lambda.py::test_run_lambda - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:48791/"
FAILED tests/test_monitor.py::test_monitor_response_received - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:53401/"
FAILED tests/test_patches.py::test_patches - assert False
FAILED tests/test_sns.py::test_get_missing_endpoint_attributes - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:46935/"
FAILED tests/test_sns.py::test_platform_applications - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:53159/"
FAILED tests/test_waiter.py::test_sqs - botocore.exceptions.EndpointConnectionError: Could not connect to the endpoint URL: "http://127.0.0.1:35737/"
=============================================== 14 failed, 141 passed, 22 deselected, 2 xfailed, 126 warnings, 54 errors in 702.50s (0:11:42) =============================================== And in attachment ful pytest output python-aiobotocore.FAIL.txt |
I got similar test failures. It seems the actual error is here:
The |
It seems moto 5.x only allows auto detection of used AWS services from URLs (see diff --git a/tests/moto_server.py b/tests/moto_server.py
index 7807401..8ce738a 100644
--- a/tests/moto_server.py
+++ b/tests/moto_server.py
@@ -28,6 +28,17 @@ def get_free_tcp_port(release_socket: bool = False):
return sckt, port
+class DomainDispatcherApplication(moto.server.DomainDispatcherApplication):
+ def __init__(self, create_app, service):
+ super().__init__(create_app)
+ self.service = service
+
+ def get_backend_for_host(self, host):
+ if self.service:
+ return self.service
+
+ return super().get_backend_for_host(host)
+
class MotoService:
"""Will Create MotoService.
Service is ref-counted so there will only be one per process. Real Service will
@@ -94,7 +105,7 @@ class MotoService:
await self._stop()
def _server_entry(self):
- self._main_app = moto.server.DomainDispatcherApplication(
+ self._main_app = DomainDispatcherApplication(
moto.server.create_backend_app, service=self._service_name
)
self._main_app.debug = True |
Looks like there is some progress with moto 5.x 1b66a7a. Thank you! |
ya there are a bunch of errors still to go through. if you have time help appreciated! |
Describe the bug
A clear and concise description of what the bug is.
Checklist
pip check
passes without errorspip freeze
resultsI'm packaging your module as an rpm package so I'm using the typical PEP517 based build, install and test cycle used on building packages from non-root account.
python3 -sBm build -w --no-isolation
build
with--no-isolation
I'm using during all processes only locally installed modulesinstaller
modulecut off from access to the public network
(pytest is executed with-m "not network"
)List of installed modules in build env:
Please let me know if you need more details or want me to perform some diagnostics.
The text was updated successfully, but these errors were encountered: