-
-
Notifications
You must be signed in to change notification settings - Fork 359
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
Responses 0.19.0 seems to break some s3 mocks #511
Comments
Also - airlfow is quite a beast when it comes to installing it, hence all the Airlfow env and dependencies are ready-to-run in the docker image (and you can find all the python sources in But you can also browse the sources in https://github.com/apache/airflow/blob/main/airflow/providers/amazon/aws/hooks/s3.py (we are talking about |
Some of the tests failed previously with typing extensions above 4. This PR attempts to relax the limit and check if the problems still appear. Also new tests (S3) started to fail when a new `responses` library version has been released today. So this change also add limits to the responses library in order to make sure the tests pass. Issue getsentry/responses#511 has been opened to raise it to `responses` library maintainers.
Some of the tests failed previously with typing extensions above 4. This PR attempts to relax the limit and check if the problems still appear. Also new tests (S3) started to fail when a new `responses` library version has been released today. So this change also add limits to the responses library in order to make sure the tests pass. Issue getsentry/responses#511 has been opened to raise it to `responses` library maintainers.
respones 0.19.0 also break moto (versions 2.3.1 to 3.0.6) |
Yep. I think this is the root cause. |
Moto maintainer here - we've just released a fix, and moto >= 3.0.7.dev2 is the first dev-release compatible with 0.19.0. (For reference, this was the issue that was raised with us.) |
Cool I will test it in Aiflow in a moment |
@bblommers: I confirm that "3.0.7.dev3" (which appeared in the meantime) fixes the issue :) |
@bblommers : "3.0.7.dev4" released 3 minutes ago as well. (what a speed !) |
Happy to hear that - thanks for letting me know! |
Hi @bblommers, I see you override |
Yes, it is related, @beliaev-maksim. There's two underlying issues:
Guarding our own add-method was both the easiest and the most foolproof fix. |
Not sure if this is the same issue, but here’s a self-contained minimal test case that still fails with the current versions import moto, requests, responses
with responses.RequestsMock() as rsps:
with moto.mock_s3():
pass
rsps.add(responses.GET, "https://example.invalid", status=200)
print(requests.request("GET", "https://example.invalid"))
|
@andersk @beliaev-maksim This is the equivalent test that does not involve Moto:
(Moto does essentially the same thing - it starts a new instance of Both tests seem to pass after changing the reset-method, and undoing the
I don't quite understand why the patcher should be None, or why that statement makes this test fail, tbh.. |
@bblommers but we need to reset |
The For example, this also fails with 0.19.0 and succeeded with 0.18.0: import requests, responses
with responses.RequestsMock() as rsps:
rsps.reset()
print(requests.get("https://example.com")) |
@bblommers @andersk |
#516 works for me. |
Some of the tests failed previously with typing extensions above 4. This PR attempts to relax the limit and check if the problems still appear. Also new tests (S3) started to fail when a new `responses` library version has been released today. So this change also add limits to the responses library in order to make sure the tests pass. Issue getsentry/responses#511 has been opened to raise it to `responses` library maintainers. GitOrigin-RevId: 082aafd2ab20656abed5e82be60b541a56142cad
Some of the tests failed previously with typing extensions above 4. This PR attempts to relax the limit and check if the problems still appear. Also new tests (S3) started to fail when a new `responses` library version has been released today. So this change also add limits to the responses library in order to make sure the tests pass. Issue getsentry/responses#511 has been opened to raise it to `responses` library maintainers. GitOrigin-RevId: 082aafd2ab20656abed5e82be60b541a56142cad
Some of the tests failed previously with typing extensions above 4. This PR attempts to relax the limit and check if the problems still appear. Also new tests (S3) started to fail when a new `responses` library version has been released today. So this change also add limits to the responses library in order to make sure the tests pass. Issue getsentry/responses#511 has been opened to raise it to `responses` library maintainers. GitOrigin-RevId: 082aafd2ab20656abed5e82be60b541a56142cad
Some of the tests failed previously with typing extensions above 4. This PR attempts to relax the limit and check if the problems still appear. Also new tests (S3) started to fail when a new `responses` library version has been released today. So this change also add limits to the responses library in order to make sure the tests pass. Issue getsentry/responses#511 has been opened to raise it to `responses` library maintainers. GitOrigin-RevId: 082aafd2ab20656abed5e82be60b541a56142cad
Some of the tests failed previously with typing extensions above 4. This PR attempts to relax the limit and check if the problems still appear. Also new tests (S3) started to fail when a new `responses` library version has been released today. So this change also add limits to the responses library in order to make sure the tests pass. Issue getsentry/responses#511 has been opened to raise it to `responses` library maintainers. GitOrigin-RevId: 082aafd2ab20656abed5e82be60b541a56142cad
Some of the tests failed previously with typing extensions above 4. This PR attempts to relax the limit and check if the problems still appear. Also new tests (S3) started to fail when a new `responses` library version has been released today. So this change also add limits to the responses library in order to make sure the tests pass. Issue getsentry/responses#511 has been opened to raise it to `responses` library maintainers. GitOrigin-RevId: 082aafd2ab20656abed5e82be60b541a56142cad
Some of the tests failed previously with typing extensions above 4. This PR attempts to relax the limit and check if the problems still appear. Also new tests (S3) started to fail when a new `responses` library version has been released today. So this change also add limits to the responses library in order to make sure the tests pass. Issue getsentry/responses#511 has been opened to raise it to `responses` library maintainers. GitOrigin-RevId: 082aafd2ab20656abed5e82be60b541a56142cad
Some of the tests failed previously with typing extensions above 4. This PR attempts to relax the limit and check if the problems still appear. Also new tests (S3) started to fail when a new `responses` library version has been released today. So this change also add limits to the responses library in order to make sure the tests pass. Issue getsentry/responses#511 has been opened to raise it to `responses` library maintainers. GitOrigin-RevId: 082aafd2ab20656abed5e82be60b541a56142cad
Some of the tests failed previously with typing extensions above 4. This PR attempts to relax the limit and check if the problems still appear. Also new tests (S3) started to fail when a new `responses` library version has been released today. So this change also add limits to the responses library in order to make sure the tests pass. Issue getsentry/responses#511 has been opened to raise it to `responses` library maintainers. GitOrigin-RevId: 082aafd2ab20656abed5e82be60b541a56142cad
The 0.19.0 Responses seems to break some s3 mocks.
We noticed a lot of failing test cases in our CI after today's 0.19.0 upgrade. All of them are S3-mock related:
https://github.com/apache/airflow/runs/5447285682?check_suite_focus=true#step:8:18784
Environment
Apache Airflow development environment.
Which SDK and version?
Steps to Reproduce
responses
library:responses
to 0.18.0Expected Result
I expect that the 0.19.0 release will not break moto's s3 mocking :).
Actual Result
It breaks it
The text was updated successfully, but these errors were encountered: