Custom RNGs #153
Labels
No labels
breaking
bug
dependencies
good first issue
help wanted
unstable
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
gh-uuid-rs/uuid#153
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
According to the docs, it should be possible to use the
rand::Randtrait'srand()method to generate a v4 UUID using a custom RNG:However, as of
github.com/uuid-rs/uuid@addaecd0fc,Uuidno longer implementsrand::Randeven if v4 support is enabled. Is there some other mechanism to specify a custom RNG?I think we will need to do a little research on this. Perhaps we will provide a temporary fix until
randis stabilized and we can makeranda public dependency.Actually no. The implementation still exists, however its just not exposed to the library user.
I have the same problem as @dicej. My use case is to seed the RNG with a fixed value in order to keep my tests deterministic where the tested code generates a lot of UUIDv4 (#100).
This is impacting servo, which uses a custom RNG (https://github.com/servo/servo/blob/master/components/rand/lib.rs) which we use among other things to generate uuids. AFAICT there's now no way to do this.