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
Add feature to bypass responses per demand #39
Conversation
I think this makes sense as a feature. There are some complexities in that you can pass the other parameters to bypass (i.e. body) and it wont yell at you. I think we should fix that behavior so that the bypass method is extremely restrictive on what parameters it allows. That'd be as simple as changing the bypass signature to not be a partial. Also do you think the name 'bypass' is clear enough? I wonder if something like 'allow' would more obviously state the intent. |
You are right, I'll follow your recommendations. |
I rebased and added a tox.ini to test locally with all supported python versions |
Any idea when this would be merged? Ran into an issue with my code where I'd like to pass a request in the wild instead of catching it. |
Has been rebased. this PR is now mergeable again. |
Has been rebased. this PR is now mergeable again. I will not abandon it so quickly. |
+1 :) |
@ticosax why did you closed this PR ? I do like the |
@dcramer any clue on what is missing to merge this feature ? |
I open this pull request in october 2014 and rebased it several time. |
To be honest, responses works fine. I built it to solve a problem and it solves it. I'm happy to let other people help maintain it, but it doesnt need to solve every problem in existence. If |
This one is probably controversial.
bypass
allows to bypass responses for selected requests.Since
requests
is used in many libraries including elasticsearch clients for instance.I would like in my test to NOT capture those calls in the context of
@responses.activate
that I'm using to capture calls to the web in the mean time.Yep, I'm testing spaghetti code.