fix: getKEGGModelForOrganism parse error; add repo-wide syntax test - #672
Merged
Conversation
getKEGGModelForOrganism.m has not parsed since #636. That commit removed the `if useConcatLib` opener of the tblout-parsing block but left its closing `end`, which terminated the function early and orphaned everything after it: >> checkcode getKEGGModelForOrganism.m L 559 (C 1): Parse error at END: usage might be invalid MATLAB syntax. The whole KEGG homology path was therefore dead, and the KEGG 118 HMM libraries, the raven-data plumbing and the K15 cutoff fix have never executed. The function's only test is an unconditional assumeFail, so nothing caught it. Delete the orphan `end`. This also clears three spurious "value assigned might be unused" warnings at lines 163, 167 and 309 that were artifacts of the truncated scope, confirming the body was being cut in half. Remove the rest of the same commit's residue while here: - useConcatLib, written at two sites and never read. - listFiles, a subfunction with no remaining callers. - A truncated dataDir docstring sentence ("... if not already present. May also / This parameter should ALWAYS be provided."), which also named the wrong release; the library is fetched from raven-data, not RAVEN. Add tSyntax, which runs checkcode over every source file and fails on any SYNER (parse error). It needs no data, solver or network and covers the tree in under four seconds. Vendored software/ (GLPKmex, libSBML) is excluded. Verified to fail on a planted parse error, not just to pass on a clean tree.
Function test results241 tests 219 ✅ 1m 5s ⏱️ Results for commit bdbbf17. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Main improvements in this PR:
getKEGGModelForOrganismdid not parse, leaving the KEGG homology path unusable.tSyntax.m: repo-widecheckcodesyntax test.Instructions on merging this PR:
develop3as target branch, and will be resolved with a squash-merge.