Flaky test: `test_sync_settings_with_picto_svg`
marcantoinedupre opened this issue · 0 comments
marcantoinedupre commented
Ce test n'est pas déterministe. Il peut échouer alors sur la CI alors qu'il n'y a pas de changement lié.
Constaté le 07/05/2024 en version 2.105.0
.
stacktrace
======================================================================
ERROR: test_sync_settings_with_picto_svg (geotrek.api.tests.test_mobile.test_sync_mobile.SyncMobileSettingsTest)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/lib/python3.8/unittest/case.py", line 60, in testPartExecutor
yield
File "/usr/lib/python3.8/unittest/case.py", line 676, in run
self._callTestMethod(testMethod)
File "/usr/lib/python3.8/unittest/case.py", line 633, in _callTestMethod
method()
File "/__w/Geotrek-admin/Geotrek-admin/geotrek/api/tests/test_mobile/test_sync_mobile.py", line 328, in test_sync_settings_with_picto_svg
management.call_command('sync_mobile', self.sync_directory, url='http://localhost:8000',
File "/__w/Geotrek-admin/Geotrek-admin/venv/lib/python3.8/site-packages/django/core/management/__init__.py", line 181, in call_command
return command.execute(*args, **defaults)
File "/__w/Geotrek-admin/Geotrek-admin/venv/lib/python3.8/site-packages/django/core/management/base.py", line 398, in execute
output = self.handle(*args, **options)
File "/__w/Geotrek-admin/Geotrek-admin/geotrek/api/management/commands/sync_mobile.py", line 561, in handle
self.rename_root()
File "/__w/Geotrek-admin/Geotrek-admin/geotrek/api/management/commands/sync_mobile.py", line 496, in rename_root
shutil.rmtree(tmp_root2)
File "/usr/lib/python3.8/shutil.py", line 712, in rmtree
onerror(os.rmdir, path, sys.exc_info())
File "/usr/lib/python3.8/shutil.py", line 710, in rmtree
os.rmdir(path)
FileNotFoundError: [Errno 2] No such file or directory: '/__w/Geotrek-admin/Geotrek-admin/var/tmp/tests/deprecated_sync_mobile'