kiwicom / pytest-recording

A pytest plugin that allows recording network interactions via VCR.py
MIT License
445 stars 35 forks source link

Stripe library (urlfetch) just waits with `block_network` #23

Closed daaain closed 4 years ago

daaain commented 5 years ago

Hey,

Thanks a lot for this library!

I managed to get everything working, except that when I run our test suite with block_network it just waits and nothing happens.

VCR functionality does work even if I don't pass the flag so I can run the tests with recorded network communication data, but it seems for some reason the Stripe library (using urlfetch apparently) just waits when the network is blocked.

I guess maybe #16 would solve this issue?

Stranger6667 commented 5 years ago

Hello, thank you for using our library and reporting this issue :)

It heavily relies on the implementation - if, for example, there is some retry-on-error logic, then the flow could be stuck on this socket connection step and keep retrying and with some unfortunate circumstances it could last an indefinite period of time.

Could you, please, provide some minimum code sample from that Stripe library that fails with block_network? so we can have an initial direction where to look at

Stranger6667 commented 4 years ago

Feel free to reopen this issue if the problem is still there. I hope that #16 will be implemented during this year's Hacktoberfest