fix: replace dispEM (removed from RAVEN) with error+ravenList - #454
Merged
Conversation
RAVEN deleted dispEM entirely in RAVEN#659 (merged 2026-06-18, already
on develop3), replacing all of its own call sites with native
warning/error plus a new ravenList formatter. Four GECKO functions
still called the now-nonexistent dispEM, crashing with "Undefined
function 'dispEM'" instead of reporting their intended error whenever
that branch was reached:
- readDLKcatOutput.m (unmatched substrates, unmatched reactions)
- loadDatabases.m (duplicate UniProt entries)
- addNewRxnsToEC.m (grRule genes missing from newEnzymes)
- getSubsetEcModel.m (smallGEM/bigEcModel reaction mismatch)
Every call site here used throwErrors=true, so each becomes a plain
error('%s', ravenList(...)) -- matching this codebase's own existing
convention of unidentified error() calls (no 'GECKO:...' id anywhere
in the source) rather than adopting RAVEN's internal error IDs.
Each is covered by a new regression test (tc0035-tc0038), verified to
fail against the pre-fix code (each one actually hits the dispEM
crash, not a coincidental different failure) and pass against the fix.
Closes #453.
Unit test results40 tests 40 ✅ 9s ⏱️ Results for commit 885273c. ♻️ This comment has been updated with latest results. |
…d-from-raven # Conflicts: # test/unit_tests/geckoCoreFunctionTests.m
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.
Summary
RAVEN deleted `dispEM` entirely in SysBioChalmers/RAVEN#659 (merged 2026-06-18, already on `develop3`), replacing all 317 of its own call sites with native `warning`/`error` plus a new `ravenList` formatter. Four GECKO functions still called the now-nonexistent `dispEM`, so each crashed with `Undefined function 'dispEM'` instead of reporting its intended error whenever that branch was reached — i.e. exactly when something was already wrong and the function was trying to say so:
Every one of these call sites used `throwErrors=true`, so each becomes a plain `error('%s', ravenList(...))` — matching this codebase's own existing convention of unidentified `error()` calls (no `'GECKO:...'` id anywhere in the source) rather than adopting RAVEN's own internal error IDs.
Found while writing a regression test for an unrelated fix (#449/#452) — reverting that fix to confirm the new test failed correctly surfaced this crash as a side effect.
Test plan
testReadDLKcatOutputUnrecognizedSubstrateErrorsCleanly_tc0035,testLoadDatabasesDuplicateUniprotEntriesErrorsCleanly_tc0036,testAddNewRxnsToECMissingGeneErrorsCleanly_tc0037,testGetSubsetEcModelMismatchedReactionsErrorsCleanly_tc0038togeckoCoreFunctionTests.m.dispEMcrash (message contains'dispEM'), not a coincidental different failure — and passes against the fix.Closes #453.