python=3.10 issue with split() function
aschuerch opened this issue · comments
My newest conda environment with rfplasmid pulled python=3.10 which gave me this error:
Finished processing 1 of 1 (100.00%) bins.
Finished parsing hits for 1 of 1 (100.00%) bins.
Finished processing 1 of 1 (100.00%) bins.
Finished processing 1 of 1 (100.00%) bins.
Finished parsing hits for 1 of 1 (100.00%) bins.
Traceback (most recent call last):
File "/home/aschuerch/anaconda3/envs/plasmidEC_rfplasmid/lib/python3.10/site-packages/RFPlasmid/rfplasmid.py", line 157, in <module>
df1['contig'], df1['gene'] = df1['contig_gene'].str.split('_', 1).str
File "/home/aschuerch/anaconda3/envs/plasmidEC_rfplasmid/lib/python3.10/site-packages/pandas/core/strings/accessor.py", line 128, in wrapper
return func(self, *args, **kwargs)
TypeError: StringMethods.split() takes from 1 to 2 positional arguments but 3 were given
A new conda environment with specifically requesting python=3.7 removed the error.
@LindavdGvB do you have an idea? this should work in 3.7 and 3.10
We don't get the error with 3.10, but we do get a future warning. Are you using 3.11? Can we get your file that is causing the problem?
Dear @aldertzomer ,
I am having the same issue. Installed rfplasmid with conda (today):
conda create -n rfplasmid -c conda-forge -c bioconda rfplasmid
Python version: 3.10.12
(rfplasmid) segalim@5CD140JTK8:/mnt/c/Users/u0889moc/Documents/PROYECTOS/NETRAM$ python --version Python 3.10.12
(rfplasmid) segalim@5CD140JTK8:/mnt/c/Users/u0889moc/Documents/PROYECTOS/NETRAM$ rfplasmid --species Campylobacter --input genomes --jelly --threads 8 --out rfplasmid
Start RFPlasmid, version 0.0.18
copy original contig names
cleanup contig names
start Checkm
Finished processing 103 of 103 (100.00%) bins.
Finished parsing hits for 103 of 103 (100.00%) bins.
Finished processing 103 of 103 (100.00%) bins.
Finished processing 103 of 103 (100.00%) bins.
Finished parsing hits for 103 of 103 (100.00%) bins.
Checkm done
start blast plasmiddb
Traceback (most recent call last):
File "/home/segalim/anaconda3/envs/rfplasmid/lib/python3.10/site-packages/RFPlasmid/rfplasmid.py", line 157, in <module>
df1['contig'], df1['gene'] = df1['contig_gene'].str.split('_', 1).str
File "/home/segalim/anaconda3/envs/rfplasmid/lib/python3.10/site-packages/pandas/core/strings/accessor.py", line 129, in wrapper
return func(self, *args, **kwargs)
TypeError: StringMethods.split() takes from 1 to 2 positional arguments but 3 were given
I tried to upload several genome fasta files to https://klif.uu.nl/rfplasmid/rfplasmidweb.py and it worked fine.
Please find attached one of the fasta files I use (changed the extension to .txt so I can upload it here):
Thank you! :)
@LindavdGvB we have an example file now. Shall we check again?
Dear Aldert, hope you are doing well. This is just a follow-up message. Have you had a chance to look into it?
Thank you! :)
I get the same error. Any fixes? Downloaded via conda, v0.0.18.