ibest / ARC

Assembly by Reduced Complexity (ARC)
Apache License 2.0
41 stars 5 forks source link

Do a better job of detecting corrupted read indexes #46

Closed samhunter closed 8 years ago

samhunter commented 9 years ago

If a user kills ARC during read indexing (e.g. with cntrl+c) the read index (a SQLite database) will only contain a subset of the reads in the Fastq file. At this point the user should delete the partial indexes before running ARC again. However, if ARC is then run a second time without deleting the partial indexes, ARC improperly detects that the FastQ has already been indexed and skips re-index in order to save time. When read splitting takes place reads exist in the fastq which are not in the index, causing a crash. This problem has come up frequently enough that it would be nice to fix it. One option that immediately comes to mind is to modify app.py so that each indexing step is wrapped in a try/except/finally block which explicitly deletes the index file.

samhunter commented 8 years ago

This appears to work properly.