From bd5ba4bba6a92325105018da2ac5708250a7f3d2 Mon Sep 17 00:00:00 2001 From: "Michael W. Hudson" Date: Tue, 24 Sep 2002 10:27:28 +0000 Subject: [PATCH] Finish up the random fixes that Raymond started yesterday. --- Lib/test/test_random.py | 2 +- Misc/NEWS | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/Lib/test/test_random.py b/Lib/test/test_random.py index 5f60f4b7b235..d508c9fa6569 100644 --- a/Lib/test/test_random.py +++ b/Lib/test/test_random.py @@ -1,4 +1,4 @@ -from test import test_support +import test_support import random # Ensure that the seed() method initializes all the hidden state. In diff --git a/Misc/NEWS b/Misc/NEWS index 99704c8b54d1..a1ff3316ec52 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -52,6 +52,13 @@ Extension modules Library +- random.gauss() uses a piece of hidden state used by nothing else, + and the .seed() and .whseed() methods failed to reset it. In other + words, setting the seed didn't completely determine the sequence of + results produced by random.gauss(). It does now. Programs repeatedly + mixing calls to a seed method with calls to gauss() may see different + results now. + - Some fixes in the copy module: when an object is copied through its __reduce__ method, there was no check for a __setstate__ method on the result [SF patch 565085]; deepcopy should treat instances of -- 2.47.3