TALON icon indicating copy to clipboard operation
TALON copied to clipboard

TALON run fails with python >= 3.8, works with <= 3.7

Open NatPRoach opened this issue 3 years ago • 0 comments

Hello, Seems that TALON's logic fails with python installations >= 3.8. When running on the test data provided with your distribution with the commands provided the program fails with the following output at the talon step

[ 2020-11-20 15:23:34 ] Started TALON run
[ 2020-11-20 15:23:36 ] Merged input SAM/BAM files
/Users/nproach/miniconda3/envs/talon5/lib/python3.8/subprocess.py:849: RuntimeWarning: line buffering (buffering=1) isn't supported in binary mode, the default buffer size will be used
  self.stderr = io.open(errread, 'rb', bufsize)
/Users/nproach/miniconda3/envs/talon5/lib/python3.8/subprocess.py:849: RuntimeWarning: line buffering (buffering=1) isn't supported in binary mode, the default buffer size will be used
  self.stderr = io.open(errread, 'rb', bufsize)
/Users/nproach/miniconda3/envs/talon5/lib/python3.8/subprocess.py:849: RuntimeWarning: line buffering (buffering=1) isn't supported in binary mode, the default buffer size will be used
  self.stderr = io.open(errread, 'rb', bufsize)
[ 2020-11-20 15:23:37 ] Split reads into 7 intervals
[ 2020-11-20 15:23:38 ] Launching parallel annotation jobs
<talon.talon.Counter object at 0x7f8e01a58640>
[ 2020-11-20 15:23:38 ] Annotating reads in interval SIRV1:1000-11644...
[ 2020-11-20 15:23:38 ] Annotating reads in interval SIRV2:999-5911...
[ 2020-11-20 15:23:38 ] Annotating reads in interval SIRV3:998-9943...
[ 2020-11-20 15:23:38 ] Annotating reads in interval SIRV4:1000-15123...
[ 2020-11-20 15:23:38 ] Annotating reads in interval SIRV5:1001-13607...
[ 2020-11-20 15:23:38 ] Annotating reads in interval SIRV6:1000-11839...
[ 2020-11-20 15:23:38 ] Annotating reads in interval SIRV7:1000-147958...
multiprocessing.pool.RemoteTraceback:
"""
Traceback (most recent call last):
  File "/Users/nproach/miniconda3/envs/talon5/lib/python3.8/multiprocessing/pool.py", line 125, in worker
    result = (True, func(*args, **kwds))
  File "/Users/nproach/miniconda3/envs/talon5/lib/python3.8/multiprocessing/pool.py", line 51, in starmapstar
    return list(itertools.starmap(args[0], args[1]))
  File "/Users/nproach/miniconda3/envs/talon5/lib/python3.8/site-packages/talon/talon.py", line 2138, in parallel_talon
    unpack_observed(annotation_info, queue,
  File "/Users/nproach/miniconda3/envs/talon5/lib/python3.8/site-packages/talon/talon.py", line 2336, in unpack_observed
    obs_ID = observed_counter.increment()
NameError: name 'observed_counter' is not defined
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/Users/nproach/miniconda3/envs/talon5/bin/talon", line 8, in <module>
    sys.exit(main())
  File "/Users/nproach/miniconda3/envs/talon5/lib/python3.8/site-packages/talon/talon.py", line 2453, in main
    pool.starmap(parallel_talon, jobs)
  File "/Users/nproach/miniconda3/envs/talon5/lib/python3.8/multiprocessing/pool.py", line 372, in starmap
    return self._map_async(func, iterable, starmapstar, chunksize).get()
  File "/Users/nproach/miniconda3/envs/talon5/lib/python3.8/multiprocessing/pool.py", line 771, in get
    raise self._value
NameError: name 'observed_counter' is not defined

Note that while this is in a conda environment talon itself was not installed through conda. I just used that to test different python versions but used the pip install . command to install talon as recommended in the README.

NatPRoach avatar Nov 20 '20 15:11 NatPRoach