From 5ecc076f411f680687ec4fdaa7d82b314eeb3805 Mon Sep 17 00:00:00 2001 From: Nayib Gloria <55710092+nayib-jose-gloria@users.noreply.github.com> Date: Mon, 23 Sep 2024 19:45:45 -0400 Subject: [PATCH 1/5] chore: isolate dev env for schema 5.2 test migration (#7342) --- .github/workflows/build-images-and-create-deployment.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-images-and-create-deployment.yml b/.github/workflows/build-images-and-create-deployment.yml index fbe35ab94cdd7..9a3ae1a7cffc8 100644 --- a/.github/workflows/build-images-and-create-deployment.yml +++ b/.github/workflows/build-images-and-create-deployment.yml @@ -45,7 +45,7 @@ jobs: uses: avakar/create-deployment@v1 # To stop deployment to a specific DEPLOYMENT_STAGE remove it from condition below. # The DEPLOYMENT_STAGE that should be present are dev, stage, prod. - if: env.DEPLOYMENT_STAGE == 'prod' || env.DEPLOYMENT_STAGE == 'stage' || env.DEPLOYMENT_STAGE == 'dev' + if: env.DEPLOYMENT_STAGE == 'prod' || env.DEPLOYMENT_STAGE == 'stage' with: auto_merge: false environment: ${{ env.DEPLOYMENT_STAGE }} From 5e98d1df659eebdf35de6844b45e51c871c40893 Mon Sep 17 00:00:00 2001 From: Mim Hastie Date: Thu, 26 Sep 2024 12:44:19 -0700 Subject: [PATCH 2/5] feat: 5.2.0 dev stage UI (#7345) --- .../common/Filter/common/constants.ts | 140 ++++------ frontend/tests/features/filter/constants.ts | 240 ++++++++++++++++++ .../features/filter/useCategoryFilter.test.ts | 76 ++---- frontend/tests/features/filter/utils.test.ts | 14 +- 4 files changed, 306 insertions(+), 164 deletions(-) create mode 100644 frontend/tests/features/filter/constants.ts diff --git a/frontend/src/components/common/Filter/common/constants.ts b/frontend/src/components/common/Filter/common/constants.ts index 18176c3862008..147494e7b3204 100644 --- a/frontend/src/components/common/Filter/common/constants.ts +++ b/frontend/src/components/common/Filter/common/constants.ts @@ -26,78 +26,56 @@ export const DEVELOPMENT_STAGE_ONTOLOGY_TERM_SET: OntologyTermSet = { { label: "Embryonic human (0–56 days)", ontology_term_id: "HsapDv:0000002", + }, + { + label: "Fetal (>56 days–birth)", + ontology_term_id: "HsapDv:0000037", + }, + ], + }, + { + label: "Postnatal human", + ontology_term_id: "HsapDv:0010000", + children: [ + { + label: "Pediatric (0-15 years)", + ontology_term_id: "HsapDv:0000264", children: [ { - label: "Carnegie (CS1)", - ontology_term_id: "HsapDv:0000003", - }, - { - label: "Cleavage (CS2)", - ontology_term_id: "HsapDv:0000004", - }, - { - label: "Blastula (CS3–5)", - ontology_term_id: "HsapDv:0000006", + label: "Newborn human (0-28 days)", + ontology_term_id: "HsapDv:0000262", }, { - label: "Gastrula (CS6)", - ontology_term_id: "HsapDv:0000010", + label: "Infant (28 days-1 year)", + ontology_term_id: "HsapDv:0000261", }, { - label: "Neurula (CS7–8)", - ontology_term_id: "HsapDv:0000012", + label: "Child (1-5 years)", + ontology_term_id: "HsapDv:0000265", }, { - label: "Organogenesis (CS9–23)", - ontology_term_id: "HsapDv:0000015", + label: "Juvenile (5-15 years)", + ontology_term_id: "HsapDv:0000271", }, ], }, - { - label: "Fetal (>56 days–birth)", - ontology_term_id: "HsapDv:0000037", - }, ], }, { - label: "Immature (0–12 years)", - ontology_term_id: "HsapDv:0000080", + label: "Adult (15+ years)", + ontology_term_id: "HsapDv:0000258", children: [ { - label: "Newborn human (0–1 month)", - ontology_term_id: "HsapDv:0000082", - }, - { - label: "Infant (1–23 months)", - ontology_term_id: "HsapDv:0000083", + label: "Young adult (15-40 years)", + ontology_term_id: "HsapDv:0000266", }, { - label: "Child (2–12 years)", - ontology_term_id: "HsapDv:0000081", - }, - ], - }, - { - label: "Mature (13+ years)", - ontology_term_id: "HsapDv:0000204", - children: [ - { - label: "Adolescent (13–19 years)", - ontology_term_id: "HsapDv:0000086", + label: "Middle aged (40-60 years)", + ontology_term_id: "HsapDv:0000267", }, { - label: "Human adult (19+ years)", - ontology_term_id: "HsapDv:0000087", - children: [ - { - label: "Early adulthood (19–45 years)", - ontology_term_id: "HsapDv:0000088", - }, - { - label: "Late adulthood (45+ years)", - ontology_term_id: "HsapDv:0000091", - }, - ], + label: "Late adult (60+ years)", + ontology_term_id: "HsapDv:0000227", }, ], }, @@ -110,32 +88,6 @@ export const DEVELOPMENT_STAGE_ONTOLOGY_TERM_SET: OntologyTermSet = { { label: "Embryonic mouse", ontology_term_id: "MmusDv:0000002", - children: [ - { - label: "Thelier stage 1 (TS1)", - ontology_term_id: "MmusDv:0000003", - }, - { - label: "Cleavage (TS2–3)", - ontology_term_id: "MmusDv:0000004", - }, - { - label: "Blastula (TS4–8)", - ontology_term_id: "MmusDv:0000007", - }, - { - label: "Gastrula (TS9–10)", - ontology_term_id: "MmusDv:0000013", - }, - { - label: "Thelier stage 11 (TS11)", - ontology_term_id: "MmusDv:0000017", - }, - { - label: "Organogenesis (TS11–22)", - ontology_term_id: "MmusDv:0000018", - }, - ], }, { label: "Fetal (TS23–26)", @@ -144,34 +96,34 @@ export const DEVELOPMENT_STAGE_ONTOLOGY_TERM_SET: OntologyTermSet = { ], }, { - label: "Post-partum (Birth+)", + label: "Postnatal mouse", ontology_term_id: "MmusDv:0000092", children: [ { - label: "Immature (0–6 weeks)", + label: "Immature (0-6 weeks)", ontology_term_id: "MmusDv:0000043", - children: [ - { - label: "Thelier stage 27 (0–3 days)", - ontology_term_id: "MmusDv:0000036", - }, - { - label: "Premature (3 days–6 weeks)", - ontology_term_id: "MmusDv:0000112", - }, - ], }, { label: "Mature (6+ weeks)", ontology_term_id: "MmusDv:0000110", children: [ { - label: "Early adulthood (6 weeks–7 months)", - ontology_term_id: "MmusDv:0000061", + label: "Prime adult (6 weeks-18 months)", + ontology_term_id: "MmusDv:0000136", + children: [ + { + label: "Young adult (6 weeks-10 months)", + ontology_term_id: "MmusDv:0000153", + }, + { + label: "Middle aged (10-18 months)", + ontology_term_id: "MmusDv:0000135", + }, + ], }, { - label: "Late adulthood (7+ months)", - ontology_term_id: "MmusDv:0000097", + label: "Late adult (18+ months)", + ontology_term_id: "MmusDv:0000134", }, ], }, diff --git a/frontend/tests/features/filter/constants.ts b/frontend/tests/features/filter/constants.ts new file mode 100644 index 0000000000000..5550d98ea15f5 --- /dev/null +++ b/frontend/tests/features/filter/constants.ts @@ -0,0 +1,240 @@ +import { + OntologyTermSet, + ONTOLOGY_VIEW_KEY, +} from "src/components/common/Filter/common/entities"; + +/** + * Test-specific ontology term set optimized for testing completeness; should not + * be updated on schema update. Ontology values do not matter here, only ontology + * structure/heirarchy. + */ +export const TEST_ONTOLOGY_TERM_SET: OntologyTermSet = { + [ONTOLOGY_VIEW_KEY.HsapDv]: [ + { + label: "Prenatal (conception–birth)", + ontology_term_id: "HsapDv:0000045", + children: [ + { + label: "Embryonic human (0–56 days)", + ontology_term_id: "HsapDv:0000002", + children: [ + { + label: "Carnegie (CS1)", + ontology_term_id: "HsapDv:0000003", + }, + { + label: "Cleavage (CS2)", + ontology_term_id: "HsapDv:0000004", + }, + { + label: "Blastula (CS3–5)", + ontology_term_id: "HsapDv:0000006", + }, + { + label: "Gastrula (CS6)", + ontology_term_id: "HsapDv:0000010", + }, + { + label: "Neurula (CS7–8)", + ontology_term_id: "HsapDv:0000012", + }, + { + label: "Organogenesis (CS9–23)", + ontology_term_id: "HsapDv:0000015", + }, + ], + }, + { + label: "Fetal (>56 days–birth)", + ontology_term_id: "HsapDv:0000037", + }, + ], + }, + { + label: "Immature (0–12 years)", + ontology_term_id: "HsapDv:0000080", + children: [ + { + label: "Newborn human (0–1 month)", + ontology_term_id: "HsapDv:0000082", + }, + { + label: "Infant (1–23 months)", + ontology_term_id: "HsapDv:0000083", + }, + { + label: "Child (2–12 years)", + ontology_term_id: "HsapDv:0000081", + }, + ], + }, + { + label: "Mature (13+ years)", + ontology_term_id: "HsapDv:0000204", + children: [ + { + label: "Adolescent (13–19 years)", + ontology_term_id: "HsapDv:0000086", + }, + { + label: "Human adult (19+ years)", + ontology_term_id: "HsapDv:0000087", + children: [ + { + label: "Early adulthood (19–45 years)", + ontology_term_id: "HsapDv:0000088", + }, + { + label: "Late adulthood (45+ years)", + ontology_term_id: "HsapDv:0000091", + }, + ], + }, + ], + }, + ], + [ONTOLOGY_VIEW_KEY.MmusDv]: [ + { + label: "Prenatal", + ontology_term_id: "MmusDv:0000042", + children: [ + { + label: "Embryonic mouse", + ontology_term_id: "MmusDv:0000002", + children: [ + { + label: "Thelier stage 1 (TS1)", + ontology_term_id: "MmusDv:0000003", + }, + { + label: "Cleavage (TS2–3)", + ontology_term_id: "MmusDv:0000004", + }, + { + label: "Blastula (TS4–8)", + ontology_term_id: "MmusDv:0000007", + }, + { + label: "Gastrula (TS9–10)", + ontology_term_id: "MmusDv:0000013", + }, + { + label: "Thelier stage 11 (TS11)", + ontology_term_id: "MmusDv:0000017", + }, + { + label: "Organogenesis (TS11–22)", + ontology_term_id: "MmusDv:0000018", + }, + ], + }, + { + label: "Fetal (TS23–26)", + ontology_term_id: "MmusDv:0000031", + }, + ], + }, + { + label: "Post-partum (Birth+)", + ontology_term_id: "MmusDv:0000092", + children: [ + { + label: "Immature (0–6 weeks)", + ontology_term_id: "MmusDv:0000043", + children: [ + { + label: "Thelier stage 27 (0–3 days)", + ontology_term_id: "MmusDv:0000036", + }, + { + label: "Premature (3 days–6 weeks)", + ontology_term_id: "MmusDv:0000112", + }, + ], + }, + { + label: "Mature (6+ weeks)", + ontology_term_id: "MmusDv:0000110", + children: [ + { + label: "Early adulthood (6 weeks–7 months)", + ontology_term_id: "MmusDv:0000061", + }, + { + label: "Late adulthood (7+ months)", + ontology_term_id: "MmusDv:0000097", + }, + ], + }, + ], + }, + ], + [ONTOLOGY_VIEW_KEY.UBERON]: [ + { + label: "Embryo", + ontology_term_id: "UBERON:0000068", + children: [ + { + label: "Zygote", + ontology_term_id: "UBERON:0000106", + }, + { + label: "Cleavage", + ontology_term_id: "UBERON:0000107", + }, + { + label: "Blastula", + ontology_term_id: "UBERON:0000108", + }, + { + label: "Gastrula", + ontology_term_id: "UBERON:0000109", + }, + { + label: "Neurula", + ontology_term_id: "UBERON:0000110", + }, + { + label: "Organogenesis", + ontology_term_id: "UBERON:0000111", + }, + { + label: "Late embryonic", + ontology_term_id: "UBERON:0007220", + }, + ], + }, + { + label: "Post embryonic", + ontology_term_id: "UBERON:0000092", + children: [ + { + label: "Larval", + ontology_term_id: "UBERON:0000069", + }, + { + label: "Pupal", + ontology_term_id: "UBERON:0000070", + }, + { + label: "Nursing", + ontology_term_id: "UBERON:0018685", + }, + { + label: "Fully formed", + ontology_term_id: "UBERON:0000066", + children: [ + { + label: "Sexually immature", + ontology_term_id: "UBERON:0000112", + }, + { + label: "Post-juvenile adult", + ontology_term_id: "UBERON:0000113", + }, + ], + }, + ], + }, + ], +}; diff --git a/frontend/tests/features/filter/useCategoryFilter.test.ts b/frontend/tests/features/filter/useCategoryFilter.test.ts index 961fae27ed5d7..28cf9ff69b130 100644 --- a/frontend/tests/features/filter/useCategoryFilter.test.ts +++ b/frontend/tests/features/filter/useCategoryFilter.test.ts @@ -68,7 +68,6 @@ import { import { CategoryValueId, CATEGORY_FILTER_ID, - CuratedOntologyCategoryFilterConfig, DatasetRow, MultiPanelCategoryFilterUIState, MultiPanelOntologyCategoryView, @@ -80,6 +79,7 @@ import { SelectCategoryValueView, } from "src/components/common/Filter/common/entities"; import { test } from "tests/common/test"; +import { TEST_ONTOLOGY_TERM_SET } from "./constants"; const { describe } = test; @@ -2926,6 +2926,8 @@ describe("useCategoryFilter", () => { // Newborn human - HsapDv:0000082 // Infant - HsapDv:0000083 // Child - HsapDv:0000081 + // + // Note, this tree matches the test ontology term test and not the current pinned ontology. const CATEGORY_VALUE_KEYS = new Set([ ONTOLOGY_ID_HUMAN_PRENATAL, ONTOLOGY_ID_HUMAN_EMBRYONIC_HUMAN, @@ -2960,11 +2962,7 @@ describe("useCategoryFilter", () => { idToDeselect, filters, CATEGORY_VALUE_KEYS, - ( - CATEGORY_FILTER_CONFIGS_BY_ID[ - CATEGORY_FILTER_ID.DEVELOPMENT_STAGE - ] as CuratedOntologyCategoryFilterConfig - ).source + TEST_ONTOLOGY_TERM_SET ); expect(nextFilters.length).toEqual(0); }); @@ -2993,11 +2991,7 @@ describe("useCategoryFilter", () => { idToDeselect, filters, CATEGORY_VALUE_KEYS, - ( - CATEGORY_FILTER_CONFIGS_BY_ID[ - CATEGORY_FILTER_ID.DEVELOPMENT_STAGE - ] as CuratedOntologyCategoryFilterConfig - ).source + TEST_ONTOLOGY_TERM_SET ); expect(nextFilters.length).toEqual(1); expect( @@ -3031,11 +3025,7 @@ describe("useCategoryFilter", () => { idToDeselect, filters, CATEGORY_VALUE_KEYS, - ( - CATEGORY_FILTER_CONFIGS_BY_ID[ - CATEGORY_FILTER_ID.DEVELOPMENT_STAGE - ] as CuratedOntologyCategoryFilterConfig - ).source + TEST_ONTOLOGY_TERM_SET ); expect(nextFilters.length).toEqual(0); }); @@ -3068,11 +3058,7 @@ describe("useCategoryFilter", () => { idToDeselect, filters, CATEGORY_VALUE_KEYS, - ( - CATEGORY_FILTER_CONFIGS_BY_ID[ - CATEGORY_FILTER_ID.DEVELOPMENT_STAGE - ] as CuratedOntologyCategoryFilterConfig - ).source + TEST_ONTOLOGY_TERM_SET ); expect(nextFilters.length).toEqual(1); expect(nextFilters.includes(ONTOLOGY_ID_HUMAN_FETAL)).toBeTruthy(); @@ -3092,11 +3078,7 @@ describe("useCategoryFilter", () => { idToSelect, [], // No filters selected CATEGORY_VALUE_KEYS, - ( - CATEGORY_FILTER_CONFIGS_BY_ID[ - CATEGORY_FILTER_ID.DEVELOPMENT_STAGE - ] as CuratedOntologyCategoryFilterConfig - ).source + TEST_ONTOLOGY_TERM_SET ); expect(nextFilters.length).toEqual(1); expect(nextFilters[0]).toEqual(idToSelect); @@ -3122,11 +3104,7 @@ describe("useCategoryFilter", () => { }, ], CATEGORY_VALUE_KEYS, - ( - CATEGORY_FILTER_CONFIGS_BY_ID[ - CATEGORY_FILTER_ID.DEVELOPMENT_STAGE - ] as CuratedOntologyCategoryFilterConfig - ).source + TEST_ONTOLOGY_TERM_SET ); expect(nextFilters.length).toEqual(2); expect(nextFilters.includes(ONTOLOGY_ID_HUMAN_NEWBORN)).toBeTruthy(); @@ -3153,11 +3131,7 @@ describe("useCategoryFilter", () => { }, ], CATEGORY_VALUE_KEYS, - ( - CATEGORY_FILTER_CONFIGS_BY_ID[ - CATEGORY_FILTER_ID.DEVELOPMENT_STAGE - ] as CuratedOntologyCategoryFilterConfig - ).source + TEST_ONTOLOGY_TERM_SET ); expect(nextFilters.length).toEqual(4); expect(nextFilters.includes(ONTOLOGY_ID_HUMAN_NEWBORN)).toBeTruthy(); @@ -3186,11 +3160,7 @@ describe("useCategoryFilter", () => { }, ], CATEGORY_VALUE_KEYS, - ( - CATEGORY_FILTER_CONFIGS_BY_ID[ - CATEGORY_FILTER_ID.DEVELOPMENT_STAGE - ] as CuratedOntologyCategoryFilterConfig - ).source + TEST_ONTOLOGY_TERM_SET ); expect(nextFilters.length).toEqual(5); expect(nextFilters.includes(ONTOLOGY_ID_HUMAN_PRENATAL)).toBeTruthy(); @@ -3221,11 +3191,7 @@ describe("useCategoryFilter", () => { ONTOLOGY_ID_HUMAN_EMBRYONIC_HUMAN, [], // No filters CATEGORY_VALUE_KEYS, - ( - CATEGORY_FILTER_CONFIGS_BY_ID[ - CATEGORY_FILTER_ID.DEVELOPMENT_STAGE - ] as CuratedOntologyCategoryFilterConfig - ).source + TEST_ONTOLOGY_TERM_SET ); expect(nextFilters.length).toEqual(3); expect( @@ -3259,11 +3225,7 @@ describe("useCategoryFilter", () => { }, ], CATEGORY_VALUE_KEYS, - ( - CATEGORY_FILTER_CONFIGS_BY_ID[ - CATEGORY_FILTER_ID.DEVELOPMENT_STAGE - ] as CuratedOntologyCategoryFilterConfig - ).source + TEST_ONTOLOGY_TERM_SET ); expect(nextFilters.length).toEqual(3); expect( @@ -3299,11 +3261,7 @@ describe("useCategoryFilter", () => { }, ], CATEGORY_VALUE_KEYS, - ( - CATEGORY_FILTER_CONFIGS_BY_ID[ - CATEGORY_FILTER_ID.DEVELOPMENT_STAGE - ] as CuratedOntologyCategoryFilterConfig - ).source + TEST_ONTOLOGY_TERM_SET ); expect(nextFilters.length).toEqual(5); expect(nextFilters.includes(ONTOLOGY_ID_HUMAN_PRENATAL)).toBeTruthy(); @@ -3345,11 +3303,7 @@ describe("useCategoryFilter", () => { }, ], CATEGORY_VALUE_KEYS, - ( - CATEGORY_FILTER_CONFIGS_BY_ID[ - CATEGORY_FILTER_ID.DEVELOPMENT_STAGE - ] as CuratedOntologyCategoryFilterConfig - ).source + TEST_ONTOLOGY_TERM_SET ); expect(nextFilters.length).toEqual(2); expect( diff --git a/frontend/tests/features/filter/utils.test.ts b/frontend/tests/features/filter/utils.test.ts index c9ae0f4fd07ad..d3b330f42b6e2 100644 --- a/frontend/tests/features/filter/utils.test.ts +++ b/frontend/tests/features/filter/utils.test.ts @@ -3,7 +3,6 @@ */ import test, { expect } from "@playwright/test"; -import { DEVELOPMENT_STAGE_ONTOLOGY_TERM_SET } from "src/components/common/Filter/common/constants"; import { findOntologyNodeById, findOntologyParentNode, @@ -12,6 +11,7 @@ import { SYMBOL_MILLION, SYMBOL_THOUSAND, } from "src/components/common/Filter/common/utils"; +import { TEST_ONTOLOGY_TERM_SET } from "./constants"; const { describe } = test; @@ -156,8 +156,7 @@ describe("filter", () => { ].forEach((ontologyId) => { test(`finds ontology node with ID ${ontologyId}`, () => { const ontologyKey = getOntologySpeciesKey(ontologyId); - const ontologyRootNodes = - DEVELOPMENT_STAGE_ONTOLOGY_TERM_SET[ontologyKey]; + const ontologyRootNodes = TEST_ONTOLOGY_TERM_SET[ontologyKey]; expect(ontologyRootNodes).toBeTruthy(); const ontologyNode = findOntologyNodeById( // eslint-disable-next-line @typescript-eslint/no-non-null-assertion -- truthy check above @@ -174,8 +173,7 @@ describe("filter", () => { test(`finds parent of ${ONTOLOGY_ID_HUMAN_EMBRYONIC_HUMAN}`, () => { const ontologyId = ONTOLOGY_ID_HUMAN_EMBRYONIC_HUMAN; const ontologyKey = getOntologySpeciesKey(ontologyId); - const ontologyRootNodes = - DEVELOPMENT_STAGE_ONTOLOGY_TERM_SET[ontologyKey]; + const ontologyRootNodes = TEST_ONTOLOGY_TERM_SET[ontologyKey]; expect(ontologyRootNodes).toBeTruthy(); const ontologyNode = findOntologyNodeById( // eslint-disable-next-line @typescript-eslint/no-non-null-assertion -- truthy check above @@ -195,8 +193,7 @@ describe("filter", () => { test(`finds parent of ${ONTOLOGY_ID_HUMAN_CARNEGIE_CS1}`, () => { const ontologyId = ONTOLOGY_ID_HUMAN_CARNEGIE_CS1; const ontologyKey = getOntologySpeciesKey(ontologyId); - const ontologyRootNodes = - DEVELOPMENT_STAGE_ONTOLOGY_TERM_SET[ontologyKey]; + const ontologyRootNodes = TEST_ONTOLOGY_TERM_SET[ontologyKey]; expect(ontologyRootNodes).toBeTruthy(); const ontologyNode = findOntologyNodeById( // eslint-disable-next-line @typescript-eslint/no-non-null-assertion -- truthy check above @@ -218,8 +215,7 @@ describe("filter", () => { test(`doesn't find parent of ${ONTOLOGY_ID_HUMAN_PRENATAL}`, () => { const ontologyId = ONTOLOGY_ID_HUMAN_PRENATAL; const ontologyKey = getOntologySpeciesKey(ontologyId); - const ontologyRootNodes = - DEVELOPMENT_STAGE_ONTOLOGY_TERM_SET[ontologyKey]; + const ontologyRootNodes = TEST_ONTOLOGY_TERM_SET[ontologyKey]; expect(ontologyRootNodes).toBeTruthy(); const ontologyNode = findOntologyNodeById( // eslint-disable-next-line @typescript-eslint/no-non-null-assertion -- truthy check above From a12556f997d9caa1cfbd52453446c5c4af460df3 Mon Sep 17 00:00:00 2001 From: Trent Smith <1429913+Bento007@users.noreply.github.com> Date: Fri, 27 Sep 2024 11:38:43 -0700 Subject: [PATCH 3/5] chore: resolve deprecation warning and update requirements (#7275) ## Reason for Change - resolving deprecation errors. - keeping requirements up to date. ## Changes - renamed `assertEquals` to `assertEqual` to resolve deprecated assertEquals - rename `method_whitelist` to `allowed_methods` to resolve DeprecationWarning: Using 'method_whitelist' with Retry is deprecated and will be removed in v2.0. Use 'allowed_methods' instead - use backend/server/requirements in backend portal container. This means we can remove the duplicate requirements in backend/requirements.txt - Update requirements for the backend portal api. - migrate to authlib 1.x.x --- Dockerfile.backend | 2 +- backend/api_server/index.html | 4 ++-- backend/common/auth0_manager.py | 2 +- backend/common/census_cube/utils.py | 8 ++++---- backend/common/server/config.py | 6 ++++-- backend/portal/api/app/v1/authentication.py | 3 +-- .../backend/common/server/requirements.txt | 6 +++--- python_dependencies/backend/requirements.txt | 17 ++++------------- .../unit/backend/layers/api/test_portal_api.py | 2 +- tests/unit/backend/wmg/test_query.py | 4 ++-- 10 files changed, 23 insertions(+), 31 deletions(-) diff --git a/Dockerfile.backend b/Dockerfile.backend index 1563bf75e66c8..22596d9642eef 100644 --- a/Dockerfile.backend +++ b/Dockerfile.backend @@ -22,7 +22,7 @@ RUN python3 -m pip install --upgrade pip setuptools # TODO: Determine if cmake is really needed for ddtrace # see ticket: https://github.com/chanzuckerberg/single-cell-data-portal/issues/5821 RUN python3 -m pip install cmake -RUN python3 -m pip install -r requirements.txt +RUN python3 -m pip install -r requirements.txt -r ./common/server/requirements.txt RUN if [ "$INSTALL_DEV" = "true" ]; then python3 -m pip install -r requirements-dev.txt; fi # Install awscli to download wmg snapshot to the local disk RUN python3 -m pip install awscli diff --git a/backend/api_server/index.html b/backend/api_server/index.html index 148b2d3d43c72..b9a9a13eb505b 100644 --- a/backend/api_server/index.html +++ b/backend/api_server/index.html @@ -9,8 +9,8 @@ />