Skip to content

Commit

Permalink
DOC: Add warning to UBG
Browse files Browse the repository at this point in the history
Add a warning

closes #389
  • Loading branch information
bashtage committed Oct 11, 2024
1 parent 7f2acc4 commit f8a4c40
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions randomgen/wrapper.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,16 @@ cdef class UserBitGenerator(BitGenerator):
a single input. If not provided, getting the ``state`` property
will raise NotImplementedError.
Notes
-----
There is one key caveat when using a UserBitGenerator. The callable must run without
exceptions.
.. warning::
It is essential that the callable function runs without producing an Exception.
Exceptions will be silently ignored and the generator will produce incorrect
results.
Examples
--------
A generator that rotates across 4 values from random.org.
Expand Down

0 comments on commit f8a4c40

Please sign in to comment.