Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
python 3.12 removes many long deprecated unittest features including _TextTestResult (deprecated in Python 3.2) notices as fedora 39 ships with python 3.12 Test plan: Local build with `./build/fbcode_builder/getdeps.py --allow-system-packages build --src-dir=. eden` Before: ``` FAILED: eden/integration/CMakeFiles/integration_tests.GEN_PY_EXE.util eden/integration/integration_tests_tests.cmake /home/alex/local/tmp/fridge/fbcode_builder_getdeps-ZhomeZalexZlocalZsaplingZbuildZfbcode_builder/build/eden/eden/integration/integration_tests_tests.cmake cd /home/alex/local/tmp/fridge/fbcode_builder_getdeps-ZhomeZalexZlocalZsaplingZbuildZfbcode_builder/build/eden/eden/integration && /usr/bin/cmake -D TEST_TARGET=integration_tests -D TEST_INTERPRETER=/usr/bin/python3.12 -D TEST_ENV=CMAKE_SOURCE_DIR=/home/alex/local/sapling -D TEST_EXECUTABLE=/home/alex/local/tmp/fridge/fbcode_builder_getdeps-ZhomeZalexZlocalZsaplingZbuildZfbcode_builder/build/eden/eden/integration/integration_tests -D TEST_WORKING_DIR=/home/alex/local/tmp/fridge/fbcode_builder_getdeps-ZhomeZalexZlocalZsaplingZbuildZfbcode_builder/build/eden -D TEST_LIST=integration_tests_TESTS -D TEST_PREFIX=integration_tests:: -D TEST_PROPERTIES= -D CTEST_FILE=/home/alex/local/tmp/fridge/fbcode_builder_getdeps-ZhomeZalexZlocalZsaplingZbuildZfbcode_builder/build/eden/eden/integration/integration_tests_tests.cmake -P /home/alex/local/sapling/build/fbcode_builder/CMake/FBPythonTestAddTests.cmake Traceback (most recent call last): File "<frozen runpy>", line 198, in _run_module_as_main File "<frozen runpy>", line 88, in _run_code File "/home/alex/local/tmp/fridge/fbcode_builder_getdeps-ZhomeZalexZlocalZsaplingZbuildZfbcode_builder/build/eden/eden/integration/integration_tests/__main__.py", line 197, in <module> File "/usr/lib64/python3.12/unittest/__init__.py", line 85, in __getattr__ raise AttributeError(f"module {__name__!r} has no attribute {name!r}") AttributeError: module 'unittest' has no attribute '_TextTestResult'. Did you mean: 'TextTestResult'? ``` After, works
- Loading branch information