Fix GeneEdaSubsetPlugin to insert gene IDs as separate rows #17
Open
Fix GeneEdaSubsetPlugin to insert gene IDs as separate rows #17
Conversation
…returns a JSON array The EDA tabular endpoint returns gene IDs as a JSON array in a single cell (e.g. ["PBANKA_1349800","PF3D7_1335900"]), but the code was trying to insert the whole array string as a single VARCHAR(30) value. Changed convertToTmpTableRow to convertToTmpTableRows (returning List<Object[]>) so each gene ID in the array becomes its own row in the temporary table. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
ryanrdoherty
approved these changes
Mar 11, 2026
Member
There was a problem hiding this comment.
Approved, but curious how/why you are allowing the VEUPATHDB_GENE_ID variable to be either a single ID or array of IDs. Seems like it would be better to have separate variables for ID vs IDs so clients know how to handle the data up front without examining it.
Edit: I see- EDA itself groups the values because there is more than one value per entity ID. Not a fan but I guess it's what we have to work with now..
The EDA can return multiple IDs for the same gene (canonical + aliases), all of which resolve to the same gene via apidbtuning.geneid. This caused duplicate transcript rows in the WDK cache table. Fixed by adding DISTINCT to the gene-transcript join SQL. Also added _seenGeneIds deduplication in GeneEdaSubsetPlugin to reduce unnecessary temp table insertions. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
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.
Rod malaria phenotype (plasmodb) has multiple organisms so the eda returns genes from multiple orgs as JSON array
The EDA tabular endpoint returns gene IDs as a JSON array in a single cell (e.g. ["PBANKA_1349800","PF3D7_1335900"]), but the code was trying to insert the whole array string as a single VARCHAR(30) value. Changed convertToTmpTableRow to convertToTmpTableRows (returning List<Object[]>) so each gene ID in the array becomes its own row in the temporary table.
Tested on my dev site. Other eda searches working too