Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add changes from test into stage. #1352

Closed
wants to merge 17 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
17 commits
Select commit Hold shift + click to select a range
cd57b98
Merge pull request #1325 from alliance-genome/test
motenko May 17, 2024
f88d8b2
Merge pull request #1336 from alliance-genome/test
oblodgett Jun 12, 2024
e2b32b8
Merge pull request #1340 from alliance-genome/test
VarunReddy1111 Jun 19, 2024
36186c8
Merge pull request #1342 from alliance-genome/test
VarunReddy1111 Jun 26, 2024
0bdc448
Include extension in module path specifiers to allow correct resoluti…
mluypaert Jul 25, 2024
c304f1e
Merge pull request #1345 from alliance-genome/KANBAN-584_pavi-integra…
mluypaert Jul 29, 2024
b25790a
Removed hardcoded Alliance version for jBrowse URLs and retrieve it d…
mluypaert Jul 29, 2024
6560428
Added Jbrowse AGR release overwrite variable REACT_APP_JBROWSE_AGR_RE…
mluypaert Jul 29, 2024
9ee46c0
Unified uirun targets to use single command
mluypaert Jul 29, 2024
e968244
Fix unit tests by making getReleaseVersion symchronous
mluypaert Jul 30, 2024
7372938
Align make install target with install options used for production
mluypaert Jul 30, 2024
3e39d0c
Use ReleaseContextProvider for SequencePanel release info.
mluypaert Jul 30, 2024
ae59d34
Default make test to run once without watching
mluypaert Jul 30, 2024
330a2cf
GH Actions dependency version bumps
mluypaert Jul 30, 2024
cb44741
Merge pull request #1347 from alliance-genome/release_constant_removal
mluypaert Jul 30, 2024
9839231
KANBAN-531: Add community resource links for AD portal
motenko Aug 9, 2024
629c621
Merge pull request #1349 from alliance-genome/KANBAN-531
motenko Aug 9, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/github-actions-PR-validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ jobs:
echo "Repository ${{ github.repository }}."
echo "Trigger ref ${{ github.ref }}, base-ref ${{ github.base_ref }}, head_ref ${{ github.head_ref }}."
- name: Check out repository code
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Report files updated in PR
run: |
git fetch -q origin ${{ github.base_ref }} ${{ github.head_ref }}
git diff --name-only origin/${{ github.base_ref }} origin/${{ github.head_ref }}
- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: 18
- name: Report runtime details
Expand Down
12 changes: 7 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ endif
all: install build test

install:
npm install
npm install --legacy-peer-deps
build:
npm run build
test:
npm test
npm test -- --watchAll=false
run:
npm start

Expand All @@ -42,13 +42,15 @@ prod-ui-deploy:
npx aws-cdk deploy agr-ui-production

uirun:
npm start
REACT_APP_JBROWSE_AGR_RELEASE=${REACT_APP_JBROWSE_AGR_RELEASE} API_URL=${API_URL} npm start

uirunstage: API_URL=https://stage.alliancegenome.org
uirunstage:
API_URL=https://stage.alliancegenome.org npm start
@$(MAKE) --no-print-directory uirun API_URL=${API_URL}

uiruntest: API_URL=https://test.alliancegenome.org
uiruntest:
API_URL=https://test.alliancegenome.org npm start
@$(MAKE) --no-print-directory uirun API_URL=${API_URL}

docker-build-nginx:
docker build -t ${REG}/agr_ui_server:${DOCKER_BUILD_TAG} --build-arg REG=${REG} --build-arg DOCKER_PULL_TAG=${DOCKER_PULL_TAG} .
Expand Down
22 changes: 10 additions & 12 deletions src/constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -256,8 +256,6 @@ export const DEFAULT_TABLE_STATE = {
filters: {},
};

const RELEASE = '7.0.0';

export const SPECIES = [
{
taxonId: 'NCBITaxon:9606',
Expand All @@ -266,7 +264,7 @@ export const SPECIES = [
apolloName: 'human',
apolloTrack: '/All%20Genes/',
jBrowseName: 'Homo sapiens',
jBrowsenclistbaseurl: `https://s3.amazonaws.com/agrjbrowse/docker/${RELEASE}/human/`,
jBrowsenclistbaseurltemplate: `https://s3.amazonaws.com/agrjbrowse/docker/{release}/human/`,
jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz',
jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001405.40_GRCh38.p14_genomic.fna.gz',
jBrowsetracks: '_all_genes,_ht_variants',
Expand All @@ -282,7 +280,7 @@ export const SPECIES = [
apolloName: 'mouse',
apolloTrack: '/All%20Genes/',
jBrowseName: 'Mus musculus',
jBrowsenclistbaseurl: `https://s3.amazonaws.com/agrjbrowse/docker/${RELEASE}/MGI/mouse/`,
jBrowsenclistbaseurltemplate: `https://s3.amazonaws.com/agrjbrowse/docker/{release}/MGI/mouse/`,
jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz',
jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001635.27_GRCm39_genomic.fna.gz',
jBrowsetracks: '_all_genes,_ht_variants,_variants,_multiple-variant_alleles',
Expand All @@ -298,7 +296,7 @@ export const SPECIES = [
apolloName: 'rat',
apolloTrack: '/All%20Genes/',
jBrowseName: 'Rattus norvegicus',
jBrowsenclistbaseurl: `https://s3.amazonaws.com/agrjbrowse/docker/${RELEASE}/RGD/rat/`,
jBrowsenclistbaseurltemplate: `https://s3.amazonaws.com/agrjbrowse/docker/{release}/RGD/rat/`,
jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz',
jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_015227675.2_mRatBN7.2_genomic.fna.gz',
jBrowsetracks: '_all_genes,_ht_variants,_variants',
Expand All @@ -314,7 +312,7 @@ export const SPECIES = [
apolloName: 'x_laevis',
apolloTrack: '/All%20Genes/',
jBrowseName: 'Xenopus laevis',
jBrowsenclistbaseurl: `https://s3.amazonaws.com/agrjbrowse/docker/${RELEASE}/XenBase/x_laevis/`,
jBrowsenclistbaseurltemplate: `https://s3.amazonaws.com/agrjbrowse/docker/{release}/XenBase/x_laevis/`,
jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz',
jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/XENLA_9.2_genome.fa.gz',
jBrowsetracks: '_all_genes',
Expand All @@ -330,7 +328,7 @@ export const SPECIES = [
apolloName: 'x_tropicalis',
apolloTrack: '/All%20Genes/',
jBrowseName: 'Xenopus tropicalis',
jBrowsenclistbaseurl: `https://s3.amazonaws.com/agrjbrowse/docker/${RELEASE}/XenBase/x_tropicalis/`,
jBrowsenclistbaseurltemplate: `https://s3.amazonaws.com/agrjbrowse/docker/{release}/XenBase/x_tropicalis/`,
jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz',
jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/XENTR_9.1_genome.fa.gz',
jBrowsetracks: '_all_genes',
Expand All @@ -346,7 +344,7 @@ export const SPECIES = [
apolloName: 'zebrafish',
apolloTrack: '/All%20Genes/',
jBrowseName: 'Danio rerio',
jBrowsenclistbaseurl: `https://s3.amazonaws.com/agrjbrowse/docker/${RELEASE}/zfin/zebrafish-11/`,
jBrowsenclistbaseurltemplate: `https://s3.amazonaws.com/agrjbrowse/docker/{release}/zfin/zebrafish-11/`,
jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz',
jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002035.6_GRCz11_genomic.fna.gz',
jBrowsetracks: '_all_genes,_ht_variants,_variants',
Expand All @@ -362,7 +360,7 @@ export const SPECIES = [
apolloName: 'fly',
apolloTrack: '/All%20Genes/',
jBrowseName: 'Drosophila melanogaster',
jBrowsenclistbaseurl: `https://s3.amazonaws.com/agrjbrowse/docker/${RELEASE}/FlyBase/fruitfly/`,
jBrowsenclistbaseurltemplate: `https://s3.amazonaws.com/agrjbrowse/docker/{release}/FlyBase/fruitfly/`,
jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz',
jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001215.4_Release_6_plus_ISO1_MT_genomic.fna.gz',
jBrowsetracks: '_all_genes,_ht_variants,_variants,_multiple-variant_alleles',
Expand All @@ -378,7 +376,7 @@ export const SPECIES = [
apolloName: 'worm',
apolloTrack: '/All%20Genes/',
jBrowseName: 'Caenorhabditis elegans',
jBrowsenclistbaseurl: `https://s3.amazonaws.com/agrjbrowse/docker/${RELEASE}/WormBase/c_elegans_PRJNA13758/`,
jBrowsenclistbaseurltemplate: `https://s3.amazonaws.com/agrjbrowse/docker/{release}/WormBase/c_elegans_PRJNA13758/`,
jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz',
jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000002985.6_WBcel235_genomic.fna.gz',
jBrowsetracks: '_all_genes,_ht_variants,_variants',
Expand All @@ -394,7 +392,7 @@ export const SPECIES = [
apolloName: 'yeast',
apolloTrack: '/All%20Genes/',
jBrowseName: 'Saccharomyces cerevisiae',
jBrowsenclistbaseurl: `https://s3.amazonaws.com/agrjbrowse/docker/${RELEASE}/SGD/yeast/`,
jBrowsenclistbaseurltemplate: `https://s3.amazonaws.com/agrjbrowse/docker/{release}/SGD/yeast/`,
jBrowseurltemplate: 'tracks/All_Genes/{refseq}/trackData.jsonz',
jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000146045.2_R64_genomic.fna.gz',
jBrowsetracks: '_all_genes,_ht_variants',
Expand All @@ -410,7 +408,7 @@ export const SPECIES = [
apolloName: 'SARS-CoV-2',
apolloTrack: '/Mature%20peptides/',
jBrowseName: 'SARS-CoV-2',
jBrowsenclistbaseurl: `https://s3.amazonaws.com/agrjbrowse/docker/3.2.0/SARS-CoV-2/`,
jBrowsenclistbaseurltemplate: `https://s3.amazonaws.com/agrjbrowse/docker/3.2.0/SARS-CoV-2/`,
jBrowseurltemplate: 'tracks/All Genes/{refseq}/trackData.jsonz',
jBrowsefastaurl: 'https://s3.amazonaws.com/agrjbrowse/fasta/GCF_000001405.40_GRCh38.p14_genomic.fna.gz',
jBrowsetracks: '_all_genes',
Expand Down
2 changes: 1 addition & 1 deletion src/containers/alzheimersPage/PapersSection.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const PapersSection = () => {
<div className={style.contentContainer}>
<div className='row'>
<div className='col-lg-12'>
<p>Recent Papers</p>
<h2>Recent Papers</h2>
</div>
</div>
</div>
Expand Down
20 changes: 19 additions & 1 deletion src/containers/alzheimersPage/ResourcesSection.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,31 @@
import React from 'react';
import style from './style.module.scss';
import ExternalLink from '../../components/ExternalLink';


const ResourcesSection = () => {
const resourceLinks = [
{title: "Alzhemiers.gov", url: 'https://www.alzheimers.gov/'},
{title: "Alzhemier's Association", url: 'https://www.alz.org/'},
{title: "Alzhemier's Foundation of America", url: 'https://alzfdn.org/'},
{title: "National Institute on Aging", url: 'https://www.nia.nih.gov/'},
];

return (
<section className={style.section}>
<div className={style.contentContainer}>
<div className='row'>
<div className='col-lg-12'>
<p>Community Resoures</p>
<h2>Community Resoures</h2>
<div>
{resourceLinks.map((resourceLink) => {
return (
<div>
<ExternalLink href={resourceLink.url}>{resourceLink.title}</ExternalLink>
</div>
)
})}
</div>
</div>
</div>
</div>
Expand Down
57 changes: 34 additions & 23 deletions src/containers/genePage/sequencePanelWrapper.js
Original file line number Diff line number Diff line change
@@ -1,39 +1,50 @@
import React, {Component} from 'react';
import React from 'react';
import PropTypes from 'prop-types';

import { GenericGeneSeqPanel } from 'generic-sequence-panel';
import { getSpecies } from '../../lib/utils';
import { Buffer } from 'buffer';

import { useRelease } from '../../hooks/ReleaseContextProvider';

window.Buffer = Buffer

class SequencePanel extends Component {
const SequencePanel = ({species, gene, refseq, start, end}) => {

constructor(props) {
super(props);
const useGetReleaseVersion = () => {
const release = useRelease();

this.jBrowsenclistbaseurl = getSpecies(this.props.species).jBrowsenclistbaseurl;
this.jBrowseurltemplate = getSpecies(this.props.species).jBrowseurltemplate;
this.jBrowsefastaurl = getSpecies(this.props.species).jBrowsefastaurl;
if( !release.isLoading && !release.isError ){
return release.data.releaseVersion
}
else{
return 'unknown'
}
}

render() {
var refseq = this.props.refseq;
if((this.props.species === 'NCBITaxon:559292' || this.props.species === 'NCBITaxon:8355') && !this.props.refseq.startsWith('chr') && !this.props.refseq.toLowerCase().startsWith('scaffold')){
refseq = 'chr' + refseq;
}
return (
<GenericGeneSeqPanel
refseq={refseq}
start={this.props.start}
end={this.props.end}
gene={this.props.gene}
nclistbaseurl={this.jBrowsenclistbaseurl}
urltemplate={this.jBrowseurltemplate}
fastaurl={this.jBrowsefastaurl}
/>
);
const contextReleaseVersion = useGetReleaseVersion()
const releaseVersion = process.env.REACT_APP_JBROWSE_AGR_RELEASE || contextReleaseVersion
console.info(`sequencePanelWrapper releaseVersion: ${releaseVersion}`)

const jBrowsenclistbaseurl = getSpecies(species).jBrowsenclistbaseurltemplate.replace('{release}', releaseVersion)
const jBrowseurltemplate = getSpecies(species).jBrowseurltemplate;
const jBrowsefastaurl = getSpecies(species).jBrowsefastaurl;

if((species === 'NCBITaxon:559292' || species === 'NCBITaxon:8355') && !refseq.startsWith('chr') && !refseq.toLowerCase().startsWith('scaffold')){
refseq = 'chr' + refseq;
}

return (
<GenericGeneSeqPanel
refseq={refseq}
start={start}
end={end}
gene={gene}
nclistbaseurl={jBrowsenclistbaseurl}
urltemplate={jBrowseurltemplate}
fastaurl={jBrowsefastaurl}
/>
);
}

SequencePanel.propTypes = {
Expand Down
4 changes: 2 additions & 2 deletions src/lib/utils.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { STRINGENCY_HIGH, STRINGENCY_MED } from '../components/homology/constants';
import { DEFAULT_TABLE_STATE, SPECIES } from '../constants';
import { STRINGENCY_HIGH, STRINGENCY_MED } from '../components/homology/constants.js';
import { DEFAULT_TABLE_STATE, SPECIES } from '../constants.js';
import { stringify } from 'qs';

export function makeId(string) {
Expand Down