Is there a way to override the type strategy for type
and its generic aliases? The following snippet does not seem to work:
from hypothesis import strategies as st
def type_strat(t):
raise ValueError(t)
st.register_type_strategy(type, type_strat)
print(st.from_type(type[int]), Rule()) # Does not raise a `ValueError`.