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

Test failure - test_retryable_writes_insertMany_InsertMany_fails_after_multiple_network_errors

    • Type: Icon: Build Failure Build Failure
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Tests
    • Labels:
      None

      The "InsertMany fails after multiple network errors " spec test occasionally fails. I don't think it's platform, server, or python version specific. We see it pretty often though.

      [2020/07/14 04:08:11.717] FAIL [0.692s]: test_retryable_writes_insertMany_InsertMany_fails_after_multiple_network_errors (test_retryable_writes.TestAllScenarios)
      [2020/07/14 04:08:11.717] ----------------------------------------------------------------------
      [2020/07/14 04:08:11.717] Traceback (most recent call last):
      [2020/07/14 04:08:11.717]   File "C:\data\mci\448f8adc2de2acdd912016645dde0d73\src\test\__init__.py", line 444, in wrap
      [2020/07/14 04:08:11.717]     return f(*args, **kwargs)
      [2020/07/14 04:08:11.717]   File "C:\data\mci\448f8adc2de2acdd912016645dde0d73\src\test\__init__.py", line 444, in wrap
      [2020/07/14 04:08:11.717]     return f(*args, **kwargs)
      [2020/07/14 04:08:11.717]   File "C:\data\mci\448f8adc2de2acdd912016645dde0d73\src\test\__init__.py", line 444, in wrap
      [2020/07/14 04:08:11.717]     return f(*args, **kwargs)
      [2020/07/14 04:08:11.717]   File "C:\data\mci\448f8adc2de2acdd912016645dde0d73\src\test\test_retryable_writes.py", line 85, in run_scenario
      [2020/07/14 04:08:11.717]     self.run_scenario(scenario_def, test)
      [2020/07/14 04:08:11.717]   File "C:\data\mci\448f8adc2de2acdd912016645dde0d73\src\test\utils_spec_runner.py", line 671, in run_scenario
      [2020/07/14 04:08:11.717]     self.assertEqual(wrap_types(expected_c['data']), actual_data)
      [2020/07/14 04:08:11.717] AssertionError: Lists differ: [{'x': 11, '_id': 1}] != [{'x': 11, '_id': 1}, {'x': 22, '_id': 2}, {'x': 33, '_id': 3[18 chars]: 4}]
      [2020/07/14 04:08:11.717] Second list contains 3 additional elements.
      [2020/07/14 04:08:11.717] First extra element 1:
      [2020/07/14 04:08:11.717] {'x': 22, '_id': 2}
      [2020/07/14 04:08:11.717] - [{'_id': 1, 'x': 11}]
      [2020/07/14 04:08:11.717] ?                     ^
      [2020/07/14 04:08:11.718] + [{'_id': 1, 'x': 11},
      [2020/07/14 04:08:11.718] ?                     ^
      [2020/07/14 04:08:11.718] +  {'_id': 2, 'x': 22},
      [2020/07/14 04:08:11.718] +  {'_id': 3, 'x': 33},
      [2020/07/14 04:08:11.718] +  {'_id': 4, 'x': 44}]
      

      https://evergreen.mongodb.com/task/mongo_python_driver_tests_pyopenssl_windows__platform~windows_64_vsMulti_small_auth~auth_ssl~ssl_python_version_windows~3.4_pyopenssl~enabled_test_4.2_replica_set_05267fb46578640c6479928d13a07de4b83bcbf7_20_07_13_18_03_29

      From what I can gather, the server is failing our retyrable insert command twice with two onPrimaryTransactionalWrite network errors but somehow the collection still applies the write. Perhaps this is a bug in onPrimaryTransactionalWrite?

            Assignee:
            Unassigned Unassigned
            Reporter:
            shane.harvey@mongodb.com Shane Harvey
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: