Show More
@@ -25,7 +25,6 b' from .. import (' | |||||
25 | encoding, |
|
25 | encoding, | |
26 | error, |
|
26 | error, | |
27 | node, |
|
27 | node, | |
28 | pycompat, |
|
|||
29 | util, |
|
28 | util, | |
30 | ) |
|
29 | ) | |
31 |
|
30 | |||
@@ -65,10 +64,7 b' if stable_docket_file:' | |||||
65 | low_part = (int_seed & low_mask) << 28 |
|
64 | low_part = (int_seed & low_mask) << 28 | |
66 | int_seed = high_part + low_part + i |
|
65 | int_seed = high_part + low_part + i | |
67 | r = random.Random() |
|
66 | r = random.Random() | |
68 | if pycompat.ispy3: |
|
|||
69 |
|
|
67 | r.seed(int_seed, version=1) | |
70 | else: |
|
|||
71 | r.seed(int_seed) |
|
|||
72 | # once we drop python 3.8 support we can simply use r.randbytes |
|
68 | # once we drop python 3.8 support we can simply use r.randbytes | |
73 | raw = r.getrandbits(id_size * 4) |
|
69 | raw = r.getrandbits(id_size * 4) | |
74 | assert id_size == 8 |
|
70 | assert id_size == 8 |
General Comments 0
You need to be logged in to leave comments.
Login now