CGATOxford / UMI-tools

Tools for handling Unique Molecular Identifiers in NGS data sets
MIT License
481 stars 190 forks source link

AssertionError: files /scratch/tmpqkgmy2lv/stdout and tests/whitelist_umi_output.sam are not the same #626

Closed vasquini closed 7 months ago

vasquini commented 7 months ago

i installed umi_tools in a conda environment along with nose and pyyaml to run the tests. 17/66 tests fail and they all belong to the scRNA barcoding portions. All the errors complain about the output file not matching the corresponding file on the tests folder.

I ran a command to write the errors to an output file and I ended up with the following. I would look into scratch but the directories seem to get deleted because they don't exist when I look for them. Fail has the failure messages and files.txt has the installed packages in my environment,

Fail.txt files.txt

IanSudbery commented 7 months ago

Hi,

There are two things going on here.

First you need to

export PYTHONHASHSEED=0

before you run the tests. This makes the tests deterministic.

The second thing is that you are probably testing against a cloned version of this repository? The code in this repository has moved on since the last conda release, and so the test files no long match the outputs that are produced by the version on conda (specifically 1.1.4 had bug in it that meant that help messages didn't work). If you want the tests to work, you'll need to install the code from the cloned repository.

vasquini commented 7 months ago

So let me clarify, I did not install umi_tools through conda. I just made a conda environment with the requirements, and then I cloned the repo and installed using the setup.py script. I can try the PYTHONHASHSEED=0 thing though. And yea. all my errors are about the output not matching exactly to files in tests

vasquini commented 7 months ago

I would like to know if there's a way to keep the intermediate files in /scratch/ folder because they seem to get deleted.

vasquini commented 7 months ago

I used the export statement and it fixed everything. Thanks!