Hypothesis

Latest version: v6.104.0

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

Scan your dependencies

Page 188 of 198

1.17.0

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

This is actually the same release as 1.16.1, but 1.16.1 has been pulled because
it contains the following additional change that was not intended to be in a
patch release (it's perfectly stable, but is a larger change that should have
required a minor version bump):

* Hypothesis will now perform a series of "health checks" as part of running
your tests. These detect and warn about some common error conditions that
people often run into which wouldn't necessarily have caused the test to fail
but would cause e.g. degraded performance or confusing results.

1.16.1

-------------------

Note: This release has been removed.

A small bugfix release that allows bdists for Hypothesis to be built
under 2.7 - the compat3.py file which had Python 3 syntax wasn't intended
to be loaded under Python 2, but when building a bdist it was. In particular
this would break running setup.py test.

1.16.0

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

There are no public API changes in this release but it includes a behaviour
change that I wasn't comfortable putting in a patch release.

* Functions from hypothesis.strategies will no longer raise InvalidArgument
on bad arguments. Instead the same errors will be raised when a test
using such a strategy is run. This may improve startup time in some
cases, but the main reason for it is so that errors in strategies
won't cause errors in loading, and it can interact correctly with things
like pytest.mark.skipif.
* Errors caused by accidentally invoking the legacy API are now much less
confusing, although still throw NotImplementedError.
* hypothesis.extra.django is 1.9 compatible.
* When tests are run with max_shrinks=0 this will now still rerun the test
on failure and will no longer print "Trying example:" before each run.
Additionally note() will now work correctly when used with max_shrinks=0.

1.15.0

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

A release with two new features.

* A 'characters' strategy for more flexible generation of text with particular
character ranges and types, kindly contributed by `Alexander Shorin <https://github.com/kxepal>`_.
* Add support for preconditions to the rule based stateful testing. Kindly
contributed by `Christopher Armstrong <https://github.com/radix>`_

1.14.0

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


New features:

* Add 'note' function which lets you include additional information in the
final test run's output.
* Add 'choices' strategy which gives you a choice function that emulates
random.choice.
* Add 'uuid' strategy that generates UUIDs'
* Add 'shared' strategy that lets you create a strategy that just generates a
single shared value for each test run

Bugs:

* Using strategies of the form streaming(x.flatmap(f)) with find or in stateful
testing would have caused InvalidArgument errors when the resulting values
were used (because code that expected to only be called within a test context
would be invoked).

1.13.0

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

This is quite a small release, but deprecates some public API functions
and removes some internal API functionality so gets a minor version bump.

* All calls to the 'strategy' function are now deprecated, even ones which
pass just a SearchStrategy instance (which is still a no-op).
* Never documented hypothesis.extra entry_points mechanism has now been removed (
it was previously how hypothesis.extra packages were loaded and has been deprecated
and unused for some time)
* Some corner cases that could previously have produced an OverflowError when simplifying
failing cases using hypothesis.extra.datetimes (or dates or times) have now been fixed.
* Hypothesis load time for first import has been significantly reduced - it used to be
around 250ms (on my SSD laptop) and now is around 100-150ms. This almost never
matters but was slightly annoying when using it in the console.
* hypothesis.strategies.randoms was previously missing from \_\_all\_\_.

Page 188 of 198

Links

Releases

Has known vulnerabilities

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.