Comment 3 for bug 2028175

Revision history for this message
clayg (clay-gerrard) wrote :

LOL, so i was going to explore the random space and see if there was a specific seed that would reliably trigger the failure:

```
diff --git a/test/probe/test_container_merge_policy_index.py b/test/probe/test_container_merge_policy_index.py
index 441380590..26477ef18 100644
--- a/test/probe/test_container_merge_policy_index.py
+++ b/test/probe/test_container_merge_policy_index.py
@@ -16,6 +16,7 @@ import time
 import uuid
 import random
 import unittest
+import os

 from swift.common.manager import Manager
 from swift.common.internal_client import InternalClient
@@ -33,6 +34,8 @@ from swiftclient import ClientException

 TIMEOUT = 60

+if 'SWIFT_TEST_RANDOM_SEED' in os.environ:
+ random.seed(os.environ['SWIFT_TEST_RANDOM_SEED'])

 class TestContainerMergePolicyIndex(ReplProbeTest):

```

And then the FIRST one failed!
```
FAILED swift/test/probe/test_container_merge_policy_index.py::TestReservedNamespaceMergePolicyIndex::test_reconciler_move_object_twice - AssertionError: Found unexpected object {'bytes': 0, 'hash': '1698853396.75432_3', 'name': '0:/AUTH_test/\x00container\x002d56235d-f039-483f-a741-271fbe878c53/\x00object\x009bdd4...
```

I assumed it would fail reliably with SWIFT_TEST_RANDOM_SEED=1 but it wasn't repeatable.