Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-32614

update_test_lifecycle may fail because datetime.strptime() is not thread safe

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • 3.6.3, 3.7.2
    • Testing Infrastructure
    • None
    • Fully Compatible
    • ALL
    • v3.6
    • TIG 2018-1-29
    • 0

    Description

      The update_test_lifecycle.py script fetches the test history in multiple threads.
      In these threads the code calls the test_failures module which uses the datetime.strptime() method.
      As filed in https://bugs.python.org/issue7980, that method does not import _strptime.py in a thread safe way.
      This can lead to the following error: AttributeError: 'module' object has no attribute '_strptime'.

      We need to implement a workaround: either calling the strptime() method or importing the _strptime module explicitly before starting the threads.

      Attachments

        Activity

          People

            yves.duhem Yves Duhem
            yves.duhem Yves Duhem
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: