Hypothesis

Latest version: v6.104.0

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

Scan your dependencies

Page 190 of 198

1.10.6

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

Fix support for fixtures on Django 1.7.

1.10.4

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

Tiny bug fix release:

* If the database_file setting is set to None, this would have resulted in
an error when running tests. Now it does the same as setting database to
None.

1.10.3

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

Another small bug fix release.

* lists(elements, unique_by=some_function, min_size=n) would have raised a
ValidationError if n > Settings.default.average_list_length because it would
have wanted to use an average list length shorter than the minimum size of
the list, which is impossible. Now it instead defaults to twice the minimum
size in these circumstances.
* basic() strategy would have only ever produced at most ten distinct values
per run of the test (which is bad if you e.g. have it inside a list). This
was obviously silly. It will now produce a much better distribution of data,
both duplicated and non duplicated.

1.10.2

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

This is a small bug fix release:

* star imports from hypothesis should now work correctly.
* example quality for examples using flatmap will be better, as the way it had
previously been implemented was causing problems where Hypothesis was
erroneously labelling some examples as being duplicates.

1.10.0

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

This is just a bugfix and performance release, but it changes some
semi-public APIs, hence the minor version bump.

* Significant performance improvements for strategies which are one\_of()
many branches. In particular this included recursive() strategies. This
should take the case where you use one recursive() strategy as the base
strategy of another from unusably slow (tens of seconds per generated
example) to reasonably fast.
* Better handling of just() and sampled_from() for values which have an
incorrect \_\_repr\_\_ implementation that returns non-ASCII unicode
on Python 2.
* Better performance for flatmap from changing the internal morpher API
to be significantly less general purpose.
* Introduce a new semi-public BuildContext/cleanup API. This allows
strategies to register cleanup activities that should run once the
example is complete. Note that this will interact somewhat weirdly with
find.
* Better simplification behaviour for streaming strategies.
* Don't error on lambdas which use destructuring arguments in Python 2.
* Add some better reprs for a few strategies that were missing good ones.
* The Random instances provided by randoms() are now copyable.
* Slightly more debugging information about simplify when using a debug
verbosity level.
* Support using given for functions with varargs, but not passing arguments
to it as positional.

1.9.0

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

Codename: The great bundling.

This release contains two fairly major changes.

The first is the deprecation of the hypothesis-extra mechanism. From
now on all the packages that were previously bundled under it other
than hypothesis-pytest (which is a different beast and will remain
separate). The functionality remains unchanged and you can still import
them from exactly the same location, they just are no longer separate
packages.

The second is that this introduces a new way of building strategies
which lets you build up strategies recursively from other strategies.

It also contains the minor change that calling .example() on a
strategy object will give you examples that are more representative of
the actual data you'll get. There used to be some logic in there to make
the examples artificially simple but this proved to be a bad idea.

Page 190 of 198

Links

Releases

Has known vulnerabilities

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.