UWPR / Comet

An tandem mass spectrometry (MS/MS) sequence database search tool.
https://uwpr.github.io/Comet/
Apache License 2.0
42 stars 13 forks source link

Debug mode for Visual Studio solution is broken and several exceptions/crashes #61

Open cbielow opened 2 months ago

cbielow commented 2 months ago

When opening the Comet.sln in VS2019, compiling for Release works, but Debug config is out of date. Its missing some include directories (cannot find "expat.h" etc) and some precursor defs (to disable sqlite, which is not included in the sources).

When running Comet.exe on Windows, several issues prevent a search to run to the end, e.g. (not necessarily in this order)

  1. a stack overflow (not sure where that came from, VS won't give a proper trace).

  2. some issues in parameter handling, e.g. when param.txt contains lines like:

    peff_obo =
    precursor_NL_ions =

    which may not be valid param.txt, but Comet should not throw exceptions; in Release mode, this is also undefined behaviour and may have weird consequences, but luckily nothing happens, so far.

  3. A crash in this line (invalid handle) https://github.com/UWPR/Comet/blob/v2024.01.0/CometSearch/ThreadPool.h#L217 (does not happen in Release, but maybe it's just ignored).

jke000 commented 2 months ago

I had ignored the broken Debug config for ages but just commited a fix to address that as well as the parameter handling so thanks for reporting both. I am seeing a crash in the Debug binary but at a different point than you noted. I'm currently still clueless as to why it dies where it does, upon entering CometSearch::RunSearch().