Uploaded image for project: 'Python Driver'
  1. Python Driver
  2. PYTHON-1701

Test failure test_unpin_for_non_transaction_operation

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • 3.9
    • Tests
    • None

    Description

      Tests described here: https://github.com/mongodb/specifications/blob/master/source/transactions/tests/README.rst#mongos-pinning-prose-tests

       FAILURE: 1 not greater than 1 (AssertionError)
       Traceback (most recent call last):
         File "C:\data\mci\e18af017061bedcaba5cfc235a5173e8\src\test\__init__.py", line 411, in wrap
           return f(*args, **kwargs)
         File "C:\data\mci\e18af017061bedcaba5cfc235a5173e8\src\test\__init__.py", line 411, in wrap
           return f(*args, **kwargs)
         File "C:\data\mci\e18af017061bedcaba5cfc235a5173e8\src\test\test_transactions.py", line 228, in test_unpin_for_non_transaction_operation
           self.assertGreater(len(addresses), 1)
       AssertionError: 1 not greater than 1
      

      Failed here: https://evergreen.mongodb.com/task/mongo_python_driver_42dev_tests_windows_vs2015_python_version_27plus__auth_ssl~auth_ssl_windows_vs2015_python_version~3.6_test_latest_sharded_cluster_ecc852c3221447e79a3105aa949869d26a708d16_18_12_06_23_28_58

      I think the issue is that in this particularly unlucky test suite all 20 operations ran against the same mongos as the original transaction. With 2 mongoses, 20 attempts yields a 1 in 1048576 chance of a false positive so we got very unlucky here. Increasing to 50 attempts yields a 1 in 1125899906842624 false positive chance. We should increase the number of operations to ensure this test doesn't flake in the future.

      Attachments

        Activity

          People

            shane.harvey@mongodb.com Shane Harvey
            shane.harvey@mongodb.com Shane Harvey
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: