diff --git a/components/service/ldh/index.tsx b/components/service/ldh/index.tsx index 059d6cce..d63994f2 100644 --- a/components/service/ldh/index.tsx +++ b/components/service/ldh/index.tsx @@ -1,7 +1,7 @@ import { MetaNode } from '@/spec/metanode' import { GeneTerm } from '@/components/core/term' import { GeneSet } from '@/components/core/set' -import { RegulatoryElementSetInfo, RegulatoryElementSetForGeneSetInfo, setGenomicPositionsForRegulatoryElementSet, MyGeneToRegulatoryElementSetInfo } from '@/components/service/regulatoryElementInfo' +import { RegulatoryElementSetInfo, RegulatoryElementSetForGeneSetInfo, setGenomicPositionsForRegulatoryElementSet, MyGeneToRegulatoryElementSetInfo, MyRegulatoryElementSetInfo } from '@/components/service/regulatoryElementInfo' import { GeneInfo, GeneInfoFromGeneTerm } from '@/components/service/mygeneinfo' import { linkeddatahub_icon } from '@/icons' import { z } from 'zod' @@ -24,6 +24,34 @@ export async function myGeneInfoFromLinkDataHub(geneTerm: string): Promise entId ); - return await setGenomicPositionsForRegulatoryElementSet(reNamesSet); + + let reObjSet: any = response.data.ld.RegulatoryElement; + if(reObjSet == null || reObjSet.length == 0){ + throw new Error("Unable to get Regulatory Element data for gene "+props.inputs.geneInfo.symbol+" from Linked Data Hub API, please try again or wait a few minutes before the next atempt!"); + } + let reInfoSet = getREPositionDataFromLinkDataHub(reObjSet); + if(reInfoSet == null || reInfoSet.length == 0){ + throw new Error("Unable to get Regulatory Element(s) coordinates for gene "+props.inputs.geneInfo.symbol+" from Linked Data Hub API, please try again or wait a few minutes before the next atempt!"); + } + + return reInfoSet; }) .story(props => ({ abstract: `Regulatory elements in 10kbps region upstream or downstream of gene ${props.inputs ? ` ${props.inputs.geneInfo.symbol}` : ''}.` @@ -81,9 +118,14 @@ export const GetRegulatoryElementsInfoForGeneInfo = MetaNode('GetRegulatoryEleme continue; } - let reNamesSet: string[] = response.data.ld.RegulatoryElement.map(({ entId }) => entId ); - let reInfoSet = await setGenomicPositionsForRegulatoryElementSet(reNamesSet); - + let reObjSet: any = response.data.ld.RegulatoryElement; + if(reObjSet == null || reObjSet.length == 0){ + continue; + } + let reInfoSet = getREPositionDataFromLinkDataHub(reObjSet); + if(reInfoSet == null || reInfoSet.length == 0){ + continue; + } let temp = { gene: g, regulatoryElements: reInfoSet diff --git a/components/service/regulatoryElementInfo/service.tsx b/components/service/regulatoryElementInfo/service.tsx index 6845089f..bb66eaf1 100644 --- a/components/service/regulatoryElementInfo/service.tsx +++ b/components/service/regulatoryElementInfo/service.tsx @@ -81,7 +81,6 @@ export const GetGenesForRegulatoryElementInfo = MetaNode('GetGenesForRegulatoryE legend: `A list of genes in the vicinity of given regulatory element`, })).build() - export const REGeneSet = MetaNode('REGeneSet') .meta({ label: 'Genes Set For Each Regulatory Element In Set', @@ -161,7 +160,6 @@ export const GetGenesForRegulatoryElementInfo = MetaNode('GetGenesForRegulatoryE .story(props => ({ abstract: `Genes linked to the regulatory element set.` })) .build() - export const GetVariantsForRegulatoryElementInfo = MetaNode('GetVariantListForRegulatoryElementInfo') .meta({ label: 'Identify Variants Within Regulatory Element', @@ -586,7 +584,7 @@ export const RegElementSetInfoFromRegElementTerm = MetaNode('RegElementSetInfoFr export const GenomicRegionCoordinateTransformationAcrossReferences = MetaNode('GenomicRegionCoordinateTransformationAcrossReferences') .meta({ label: 'Genomic region coordinate transformation across references', - description: 'Get unique name for genomic region(s) cross refenrce: GRCh38, GRCh37 and NCBI36.', + description: 'Get coordinates for genomic region(s) cross references: GRCh38, GRCh37 and NCBI36.', icon: [linkeddatahub_icon], }) .inputs({ regulatoryElement: RegulatoryElementTerm }) @@ -637,10 +635,6 @@ export const RegElementSetInfoFromRegElementTerm = MetaNode('RegElementSetInfoFr name="Regulatory Element id" cellRenderer={row => {uniqueRegionsCrossReferenceList[row]?.regElementId}} /> - {uniqueRegionsCrossReferenceList[row]?.rePosition}} - /> { @@ -661,7 +655,7 @@ export const RegElementSetInfoFromRegElementTerm = MetaNode('RegElementSetInfoFr export const GenomicRegionCoordinateTransformationAcrossReferencesRE_Set = MetaNode('GenomicRegionCoordinateTransformationAcrossReferencesRE_Set') .meta({ label: 'Genomic region coordinate transformation across references', - description: 'Get unique name for genomic region(s) cross refenrce: GRCh38, GRCh37 and NCBI36.', + description: 'Get coordinates for genomic region(s) cross references: GRCh38, GRCh37 and NCBI36.', icon: [linkeddatahub_icon], }) .inputs({ regulatoryElementSet: RegulatoryElementSet }) diff --git a/components/service/variantinfo/externalRecords.tsx b/components/service/variantinfo/externalRecords.tsx index e93950a0..8f3dcb93 100644 --- a/components/service/variantinfo/externalRecords.tsx +++ b/components/service/variantinfo/externalRecords.tsx @@ -107,11 +107,12 @@ export const AlleleRegistryExternalRecordsTable = MetaNode('AlleleRegistryExtern } } + //id: caid+"("+variantInfoObj.communityStandardTitle[0]+")" let arExternalR = { name: 'Allele Registry', sources: [{ '@id': variantInfoObj['@id'], - id: caid+"("+variantInfoObj.communityStandardTitle[0]+")" + id: caid }] } alleleInfoExternalResources.push(arExternalR); diff --git a/docker-compose.yaml b/docker-compose.yaml index fb5738c0..88f246a2 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -30,7 +30,7 @@ services: logging: *default-logging # app serves the UI & API, it registers user interactions into the database (pg) pwb-app: - image: maayanlab/playbook-partnership:0.65.9-ui + image: maayanlab/playbook-partnership:0.65.10-ui build: context: . dockerfile: Dockerfile @@ -80,7 +80,7 @@ services: # the workers should be replicated, # they deal with creating "Resolved" entries for submitted Processes. pwb-worker: - image: maayanlab/playbook-partnership:0.65.9 + image: maayanlab/playbook-partnership:0.65.10 build: context: . dockerfile: Dockerfile @@ -113,7 +113,7 @@ services: logging: *default-logging # app-dev serves a dev version of the app app-dev: - image: maayanlab/playbook-partnership:0.65.9 + image: maayanlab/playbook-partnership:0.65.10 build: context: . dockerfile: Dockerfile @@ -152,7 +152,7 @@ services: # a playbook-partnership development environment # doesn't run in production, just for convenience dev: - image: maayanlab/playbook-partnership:0.65.9-dev + image: maayanlab/playbook-partnership:0.65.10-dev build: context: . dockerfile: Dockerfile diff --git a/package-lock.json b/package-lock.json index 9059e096..62b73153 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "playbook-workflow-builder", - "version": "0.65.9", + "version": "0.65.10", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "playbook-workflow-builder", - "version": "0.65.9", + "version": "0.65.10", "workspaces": [ "./app", "./components/**" diff --git a/package.json b/package.json index 0b36b862..433971af 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "playbook-workflow-builder", - "version": "0.65.9", + "version": "0.65.10", "description": "A repository for the playbook workflow builder collaboration.", "private": true, "workspaces": [