Closed sj175 closed 7 years ago
Good catch.
AFAIK this behavior is not intentional, seems more like a bug to me.
Just pushed a new version, that hopefully fixes this issue, can you take some time to test it?
Sure, all my tests pass at the moment but it's still fairly early in my development process.
Actually, it looks like Redis is now a dependency, it wasn't before. If that was intentional, that's fine. Otherwise, my tests are now broken.
Redis is an optional dependency, in case you enable the Redis backing. You should be able to use it without it though.
I get ImportError: CircuitRedisStorage can only be used if the required dependencies exist
as soon as I import pybreaker, using Python 3.6.
This is a bug; redis should not be required to use pybreaker.
I'll see what I can do. /cc @phillbaker
Ouch. Sorry about that. I'll take a look tonight.
@sj175 can you please try 0.3.3 to see if the last PR fixes the issue? Feel free to reopen this in case it didn't.
That's fixed. Brilliant, thank you!
When the circuit breaker's state is closed and the call to the wrapped function fails the listener.failure function is not called because an exception is thrown in CircuitClosedState.on_failure. Is this behaviour intentional?
The block below is from the CircuitBreakerState class: