Hypothesis

Latest version: v6.99.13

Safety actively analyzes 613755 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 112 of 194

4.17.0

Not secure
-------------------

This release adds the strategy :func:`~hypothesis.extra.numpy.broadcastable_shapes`,
which generates array shapes that are `broadcast-compatible <https://www.pythonlikeyoumeanit.com/Module3_IntroducingNumpy/Broadcasting.html#Rules-of-Broadcasting>`_
with a provided shape.

4.16.0

Not secure
-------------------

This release allows :func:`~hypothesis.strategies.register_type_strategy` to be used
with :obj:`python:typing.NewType` instances. This may be useful to e.g. provide
only positive integers for :func:`from_type(UserId) <hypothesis.strategies.from_type>`
with a ``UserId = NewType('UserId', int)`` type.

Thanks to PJCampi for suggesting and writing the patch!

4.15.0

Not secure
-------------------

This release supports passing a :class:`~python:datetime.timedelta` as the
:obj:`~hypothesis.settings.deadline` setting, so you no longer have to remember
that the number is in milliseconds (:issue:`1900`).

Thanks to Damon Francisco for this change!

4.14.7

Not secure
-------------------

This patch makes the type annotations on ``hypothesis.extra.dateutil``
compatible with :pypi:`mypy` 0.700.

4.14.6

Not secure
-------------------

This release fixes a bug introduced in :ref:`Hypothesis 4.14.3 <v4.14.3>`
that would sometimes cause
:func:`sampled_from(...).filter(...) <hypothesis.strategies.sampled_from>`
to encounter an internal assertion failure when there are three or fewer
elements, and every element is rejected by the filter.

4.14.5

Not secure
-------------------

This patch takes the previous efficiency improvements to
:func:`sampled_from(...).filter(...) <hypothesis.strategies.sampled_from>`
strategies that reject most elements, and generalises them to also apply to
``sampled_from(...).filter(...).filter(...)`` and longer chains of filters.

Page 112 of 194

Links

Releases

Has known vulnerabilities

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.