numexpr icon indicating copy to clipboard operation
numexpr copied to clipboard

`test_max_threads_unset` fails on 12-thread CPU

Open mgorny opened this issue 1 year ago • 0 comments

I suppose it's related to #479:

$ python -c 'import numexpr; numexpr.test()'
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Numexpr version:   2.10.1
NumPy version:     2.0.0
Python version:    3.12.4 (main, Jun 12 2024, 18:58:22) [GCC 14.1.1 20240516]
Platform:          linux-x86_64-#1 SMP PREEMPT_DYNAMIC Sun Jun 16 15:26:05 -00 2024
CPU vendor:        
CPU model:         
CPU clock speed:    MHz
VML available?     False
Number of threads used by default: 12 (out of 12 detected cores)
Maximum number of threads: 64
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
.........................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................Traceback (most recent call last):
  File "<string>", line 5, in <module>
AssertionError
E...../usr/lib/python3.12/multiprocessing/popen_fork.py:66: DeprecationWarning: This process (pid=1015669) is multi-threaded, use of fork() may lead to deadlocks in the child.
  self.pid = os.fork()
...
======================================================================
ERROR: test_max_threads_unset (numexpr.tests.test_numexpr.test_threading_config.test_max_threads_unset)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/tmp/numexpr/numexpr/tests/test_numexpr.py", line 1134, in test_max_threads_unset
    subprocess.check_call([sys.executable, '-c', script])
  File "/usr/lib/python3.12/subprocess.py", line 413, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/tmp/numexpr/.venv/bin/python', '-c', "import os\nif 'NUMEXPR_MAX_THREADS' in os.environ: os.environ.pop('NUMEXPR_MAX_THREADS')\nif 'OMP_NUM_THREADS' in os.environ: os.environ.pop('OMP_NUM_THREADS')\nimport numexpr\nassert(numexpr.nthreads <= 8)\nexit(0)"]' returned non-zero exit status 1.

----------------------------------------------------------------------
Ran 5538 tests in 4.424s

FAILED (errors=1)

mgorny avatar Jun 21 '24 15:06 mgorny