From 00f2abe436fcc2d999a53e32f5ba045f358abc31 Mon Sep 17 00:00:00 2001 From: Jenny Date: Fri, 26 Aug 2022 16:21:00 -0400 Subject: [PATCH 01/57] Documentation: Add documentation for the staging and production instance (#317) * Add documentation for staging and prod * Modify README.md * code formatting * Grammatical fixes * Add Keycloak related info --- README.md | 107 +------------------------------------------ docs/local-dev.md | 110 +++++++++++++++++++++++++++++++++++++++++++++ docs/production.md | 9 ++++ docs/staging.md | 9 ++++ 4 files changed, 129 insertions(+), 106 deletions(-) create mode 100644 docs/local-dev.md create mode 100644 docs/production.md create mode 100644 docs/staging.md diff --git a/README.md b/README.md index 868b2b5e..88c56a26 100644 --- a/README.md +++ b/README.md @@ -2,109 +2,4 @@ The One-Sided Matching Portal (OSMP) enables researchers to query patient variant and phenotype data from many different sources simultaneously. Acting as a hub connecting disparate data sources, the portal processes user queries, routes them to their respective endpoints with appropriate authorization, and amalgamates their results into a single, easily-searchable collection displayed in a user-friendly interface. By allowing researchers to search patient data from several research institutions with a single query, the OSMP can significantly speed up the process of rare disease “matching” across institutions and datasets. -## Front End - -The front end is a React.js SPA bootstrapped with [create-react-app](https://github.com/facebook/create-react-app) and written in [Typescript](https://www.typescriptlang.org/). [Styled-components](https://styled-components.com/docs) is used for theming and styling. Additional component tooling provided by [storybook](https://storybook.js.org/). - -### Building and editing the front end code - -- from the root project directory copy the sample .env file and enter the appropriate values - - ```bash - cp .env.sample .env - ``` -- if this is your first time bringing up the app, install dependencies: - - ```bash - docker-compose run --rm react yarn install - ``` -- bring up the react app using [docker-compose](https://docs.docker.com/compose/): - - - ```bash - docker-compose up react - ``` - - note that this will enable hot reloading. - -- (optional) start the storybook server - - ```bash - docker-compose exec -i react yarn storybook - ``` - -## Server - -The back end is a node.js server built with [express](https://expressjs.com/), [Typescript](https://www.typescriptlang.org/), and [graphql](https://graphql.org/). - -### Building and editing the back end code - -- make sure the `.env` file exists (see above) -- if this is your first time bringing up the app, install dependencies: - - ```bash - docker-compose run --rm server yarn install - ``` -- bring up the server using [docker-compose](https://docs.docker.com/compose/): - - - ```bash - docker-compose up server - ``` - - note that this will recompile the typescript and restart the server when changes are detected. - -- to run the tests: - - ```bash - docker-compose run --rm server yarn test - ``` - -### Connecting to Phenotips - -The Phenotips staging instance's API endpoint is specified by the `G4RD_URL` env var. The OSMP server uses the OSMP machine account specified by `G4RD_USERNAME` and `G4RD_PASSWORD` to authenticate to the endpoint. The Phenotips staging site can be accessed in the browser by navigating to the URL specified by the `G4RD_URL` env var, using the OSMP machine account. - -Phenotips API documentation can be found [here](https://help.phenotips.com/hc/en-us/articles/360048543632-Variant-Store-Add-on-REST-API). - -### Building the remote test server - -Apart from Phenotips, another data source for the staging instance is a Node/Express server that queries a MySQL database that has been populated wtih variants from the STAGER application database. - -- make sure the `.env` file exists (see above) -- if this is your first time bringing up the app, install dependencies: - - ```bash - docker-compose run --rm test-node yarn install - ``` -- bring up the server using [docker-compose](https://docs.docker.com/compose/): - - - ```bash - docker-compose up test-node - ``` - -- to populate MySQL database with variants from STAGER, download this [script](https://sickkidsca.sharepoint.com/:u:/r/sites/thecenterforcomputationalmedicineworkspace/Shared%20Documents/SSMP/data/stager-local-20210716.sql?csf=1&web=1&e=fVzHIB) and run the script using one of these two options: - - MySQLWorkbench - - ```bash - docker exec -i mysql -u --password="" < .sql - ``` - where the `.sql` script is on the host machine. - -## Keycloak - -The app uses [keycloak](https://www.keycloak.org/) as an identity provider and identity broker. Essentially, keycloak stores all user information and the app is a keycloak client. The implementation is currently in its earliest phases and documentation will be updated as the project evolves. - -In the dev environment, the app uses keycloak's default h2 database for storage, though in production we'll want to use MySQL or Postgres. To set up the app client and a test user, you can use the following command on your host machine with the keycloak container running: - -```bash -docker-compose exec keycloak /usr/local/bin/bootstrap-keycloak.sh -``` - -The keycloak admin portal can be accessed in the browser by navigating to localhost and the port specified by the `KEYCLOAK_PORT` env var, e.g., `localhost:9821` - -## Mongo - -Annotations can be imported into mongo using the following command. Note that that the headers should not be included in the csv and the order of the fields passed to the `fields` argument should match the order of the fields in the csv. - -```bash -mongoimport --collection=annotations --type=csv \ - --columnsHaveTypes \ - --fields="pos.int32(),ref.string(),alt.string(),chrom.string(),nhomalt.int32(),an.int32(),af.double(),assembly.string()" \ - --file=.csv \ - --uri=mongodb://:@mongo/?authSource=admin -``` - -Then make sure to create the following indexes: - -``` -db.annotations.createIndexes([ {"pos": 1}, {"assembly":1}, {"alt": 1, "chrom": 1, "pos": 1, "ref": 1 } ]) -``` +The instructions for setting up the local development environment and a description of the staging and production instance can be found in the `docs` folder. diff --git a/docs/local-dev.md b/docs/local-dev.md new file mode 100644 index 00000000..35c63fef --- /dev/null +++ b/docs/local-dev.md @@ -0,0 +1,110 @@ +# Local Development Environment + +## Front End + +The front end is a React.js SPA bootstrapped with [create-react-app](https://github.com/facebook/create-react-app) and written in [Typescript](https://www.typescriptlang.org/). [Styled-components](https://styled-components.com/docs) is used for theming and styling. Additional component tooling is provided by [storybook](https://storybook.js.org/). + +### Building and editing the front end code + +- from the root project directory, copy the sample `.env` file and enter the appropriate values: + - ```bash + cp .env.sample .env + ``` +- if this is your first time bringing up the app, install the dependencies: + - ```bash + docker-compose run --rm react yarn install + ``` +- bring up the react app using [docker-compose](https://docs.docker.com/compose/): + + - ```bash + docker-compose up react + ``` + - note that this will enable hot reloading. + +- (optional) start the storybook server: + - ```bash + docker-compose exec -i react yarn storybook + ``` + +## Server + +The back end is a node.js server built with [express](https://expressjs.com/), [Typescript](https://www.typescriptlang.org/), and [graphql](https://graphql.org/). + +### Building and editing the back end code + +- make sure the `.env` file exists (see above) +- if this is your first time bringing up the app, install the dependencies: + - ```bash + docker-compose run --rm server yarn install + ``` +- bring up the server using [docker-compose](https://docs.docker.com/compose/): + + - ```bash + docker-compose up server + ``` + - note that this will recompile the typescript and restart the server when changes are detected. + +- to run the tests: + - ```bash + docker-compose run --rm server yarn test + ``` + +### Connecting to Phenotips + +The Phenotips staging instance's API endpoint is specified by the `G4RD_URL` env var. The OSMP server uses the OSMP machine account specified by `G4RD_USERNAME` and `G4RD_PASSWORD` to authenticate to the endpoint. The Phenotips staging site can be accessed in the browser by navigating to the URL specified by the `G4RD_URL` env var, using the OSMP machine account. + +Phenotips API documentation can be found [here](https://help.phenotips.com/hc/en-us/articles/360048543632-Variant-Store-Add-on-REST-API). + +### Building the remote test server + +Apart from Phenotips, another data source for the staging instance is a Node/Express server that queries a MySQL database that has been populated wtih variants from the STAGER application database. + +- make sure the `.env` file exists (see above) +- if this is your first time bringing up the app, install the dependencies: + - ```bash + docker-compose run --rm test-node yarn install + ``` +- bring up the server using [docker-compose](https://docs.docker.com/compose/): + + - ```bash + docker-compose up test-node + ``` + +- to populate the MySQL database with variants from STAGER, download this [script](https://sickkidsca.sharepoint.com/:u:/r/sites/thecenterforcomputationalmedicineworkspace/Shared%20Documents/SSMP/data/stager-local-20210716.sql?csf=1&web=1&e=fVzHIB) and run the script using one of these two options: + - MySQLWorkbench + - ```bash + docker exec -i mysql -u --password="" < .sql + ``` + where the `.sql` script is on the host machine. + +## Keycloak + +The app uses [keycloak](https://www.keycloak.org/) as an identity provider and identity broker. Essentially, keycloak stores all user information and the app is a keycloak client. The implementation is currently in its earliest phases and documentation will be updated as the project evolves. + +In the dev environment, the app uses keycloak's default h2 database for storage, though in production we'll want to use MySQL or Postgres. To set up the app client and a test user, you can use the following command on your host machine with the keycloak container running: + +```bash +docker-compose exec keycloak /usr/local/bin/bootstrap-keycloak.sh +``` + +The keycloak admin portal can be accessed in the browser by navigating to localhost and the port specified by the `KEYCLOAK_PORT` env var, e.g., `localhost:9821` + +## Mongo + +gnomAD annotations are performed on-the-fly using MongoDB. The staging VM and production VM are connected to the MongoDB instance in the CHEO-RI tenancy. Since dev VMs are not in the CHEO-RI tenancy, they cannot connect to the MongoDB instance in the CHEO-RI tenancy. Instead, in local development, we can connect to [mongodb.ccm.sickkids.ca](mongodb.ccm.sickkids.ca) which currently only supports GRCh37 annotations and a small subset of GRCh38 annotations. + +Annotations were imported into mongo using the following command. Note that that the headers should not be included in the csv and the order of the fields passed to the `fields` argument should match the order of the fields in the csv. + +```bash +mongoimport --collection=annotations --type=csv \ + --columnsHaveTypes \ + --fields="pos.int32(),ref.string(),alt.string(),chrom.string(),nhomalt.int32(),an.int32(),af.double(),assembly.string()" \ + --file=.csv \ + --uri=mongodb://:@mongo/?authSource=admin +``` + +Then make sure to create the following indexes to optimize the query: + +``` +db.annotations.createIndexes([ {"pos": 1}, {"assembly":1}, {"alt": 1, "chrom": 1, "pos": 1, "ref": 1 } ]) +``` diff --git a/docs/production.md b/docs/production.md new file mode 100644 index 00000000..b2af21f1 --- /dev/null +++ b/docs/production.md @@ -0,0 +1,9 @@ +# Production + +OSMP is deployed via Docker Compose at [https://osmp.genomics4rd.ca](https://osmp.genomics4rd.ca). The key differences between the staging and production are the removal of the test node and increased memory and CPU resource allocations for the `server` container. The OSMP production instance is connected to the [production instance of G4RD Phenotips](https://phenotips.genomics4rd.ca). Similar to the staging stack, to deploy the frontend, compiled static bundles are uploaded to a designated MinIO bucket. The routing between the frontend and backend is handled by the HAProxy reverse proxy. User accounts are managed in [Keycloak](https://keycloak.genomics4rd.ca). + +## Continuous deployment through Github Actions + +On each commit to the `production` branch, if the changes affect the backend, a Github Actions workflow [Build, test, and deploy backend to production](https://github.com/ccmbioinfo/osmp/blob/develop/.github/workflows/node-prod.yml) is run. After the Docker image build and test stages pass, we move to the deployment stage. This stage runs on a self-hosted Actions runner that is networked with the production host, and deploys the backend to the production host. + +If the changes affect the frontend, a different workflow [Build react app and deploy to production](https://github.com/ccmbioinfo/osmp/blob/develop/.github/workflows/react-prod.yml) builds the frontend, incorporating environment-specific configurations as needed, and uploads the compiled static bundles to a designated S3 (MinIO) bucket. diff --git a/docs/staging.md b/docs/staging.md new file mode 100644 index 00000000..4fbd8de6 --- /dev/null +++ b/docs/staging.md @@ -0,0 +1,9 @@ +# Staging + +OSMP is deployed via Docker Compose at [https://osmp.ccmdev.ca/](https://osmp.ccmdev.ca/). For G4RD data source, the OSMP staging instance is connected to the [staging instance of G4RD Phenotips](https://staging.phenotips.genomics4rd.ca). To deploy the frontend, compiled static bundles are uploaded to a designated MinIO bucket. The routing between the frontend and backend is handled by the HAProxy reverse proxy. User accounts are managed in [Keycloak](https://keycloak.ccmdev.ca). + +## Continuous deployment through Github Actions + +On each commit to the `develop` branch, if the changes affect the backend, a Github Actions workflow [Build, test, and deploy backend to staging](https://github.com/ccmbioinfo/osmp/blob/develop/.github/workflows/node.yml) is run. After the Docker image build and test stages pass, we move to the deployment stage. This stage runs on a self-hosted Actions runner that is networked with the staging host, and deploys the backend to the staging host. + +If the changes affect the frontend, a different workflow [Build react app and deploy to staging](https://github.com/ccmbioinfo/osmp/blob/develop/.github/workflows/react.yml) builds the frontend, incorporating environment-specific configurations as needed, and uploads the compiled static bundles to a designated S3 (MinIO) bucket. From 0617c89b1908513f6ace7b1a86674d0d62986259 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Wed, 18 Jan 2023 14:20:22 -0500 Subject: [PATCH 02/57] Merge outstanding dependency updates (#331) * Bump mongoose from 6.2.11 to 6.4.6 in /server Bumps [mongoose](https://github.com/Automattic/mongoose) from 6.2.11 to 6.4.6. - [Release notes](https://github.com/Automattic/mongoose/releases) - [Changelog](https://github.com/Automattic/mongoose/blob/master/CHANGELOG.md) - [Commits](https://github.com/Automattic/mongoose/compare/6.2.11...6.4.6) --- updated-dependencies: - dependency-name: mongoose dependency-type: direct:production ... Signed-off-by: dependabot[bot] * Bump jose from 2.0.5 to 2.0.6 in /test-node Bumps [jose](https://github.com/panva/jose) from 2.0.5 to 2.0.6. - [Release notes](https://github.com/panva/jose/releases) - [Changelog](https://github.com/panva/jose/blob/v2.0.6/CHANGELOG.md) - [Commits](https://github.com/panva/jose/compare/v2.0.5...v2.0.6) --- updated-dependencies: - dependency-name: jose dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump loader-utils from 1.4.0 to 1.4.2 in /react Bumps [loader-utils](https://github.com/webpack/loader-utils) from 1.4.0 to 1.4.2. - [Release notes](https://github.com/webpack/loader-utils/releases) - [Changelog](https://github.com/webpack/loader-utils/blob/v1.4.2/CHANGELOG.md) - [Commits](https://github.com/webpack/loader-utils/compare/v1.4.0...v1.4.2) --- updated-dependencies: - dependency-name: loader-utils dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump deep-object-diff from 1.1.7 to 1.1.9 in /react Bumps [deep-object-diff](https://github.com/mattphillips/deep-object-diff) from 1.1.7 to 1.1.9. - [Release notes](https://github.com/mattphillips/deep-object-diff/releases) - [Commits](https://github.com/mattphillips/deep-object-diff/commits) --- updated-dependencies: - dependency-name: deep-object-diff dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump decode-uri-component from 0.2.0 to 0.2.2 in /react Bumps [decode-uri-component](https://github.com/SamVerschueren/decode-uri-component) from 0.2.0 to 0.2.2. - [Release notes](https://github.com/SamVerschueren/decode-uri-component/releases) - [Commits](https://github.com/SamVerschueren/decode-uri-component/compare/v0.2.0...v0.2.2) --- updated-dependencies: - dependency-name: decode-uri-component dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump json5 from 1.0.1 to 1.0.2 in /server Bumps [json5](https://github.com/json5/json5) from 1.0.1 to 1.0.2. - [Release notes](https://github.com/json5/json5/releases) - [Changelog](https://github.com/json5/json5/blob/main/CHANGELOG.md) - [Commits](https://github.com/json5/json5/compare/v1.0.1...v1.0.2) --- updated-dependencies: - dependency-name: json5 dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump json5 from 1.0.1 to 1.0.2 in /test-node Bumps [json5](https://github.com/json5/json5) from 1.0.1 to 1.0.2. - [Release notes](https://github.com/json5/json5/releases) - [Changelog](https://github.com/json5/json5/blob/main/CHANGELOG.md) - [Commits](https://github.com/json5/json5/compare/v1.0.1...v1.0.2) --- updated-dependencies: - dependency-name: json5 dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump json5 from 1.0.1 to 1.0.2 in /react Bumps [json5](https://github.com/json5/json5) from 1.0.1 to 1.0.2. - [Release notes](https://github.com/json5/json5/releases) - [Changelog](https://github.com/json5/json5/blob/main/CHANGELOG.md) - [Commits](https://github.com/json5/json5/compare/v1.0.1...v1.0.2) --- updated-dependencies: - dependency-name: json5 dependency-type: indirect ... Signed-off-by: dependabot[bot] Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- react/yarn.lock | 30 ++++++------- server/package.json | 2 +- server/yarn.lock | 102 ++++++++++++++++++++++---------------------- test-node/yarn.lock | 18 ++++---- 4 files changed, 76 insertions(+), 76 deletions(-) diff --git a/react/yarn.lock b/react/yarn.lock index 73857b4b..e98fd416 100644 --- a/react/yarn.lock +++ b/react/yarn.lock @@ -5932,9 +5932,9 @@ decimal.js@^10.2.1: integrity sha512-V0pfhfr8suzyPGOx3nmq4aHqabehUZn6Ch9kyFpV79TGDTWFmHqUqXdabR7QHqxzrYolF4+tVmJhUG4OURg5dQ== decode-uri-component@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545" - integrity sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU= + version "0.2.2" + resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.2.tgz#e69dbe25d37941171dd540e024c444cd5188e1e9" + integrity sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ== dedent@^0.7.0: version "0.7.0" @@ -5959,9 +5959,9 @@ deep-is@^0.1.3, deep-is@~0.1.3: integrity sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ== deep-object-diff@^1.1.0: - version "1.1.7" - resolved "https://registry.yarnpkg.com/deep-object-diff/-/deep-object-diff-1.1.7.tgz#348b3246f426427dd633eaa50e1ed1fc2eafc7e4" - integrity sha512-QkgBca0mL08P6HiOjoqvmm6xOAl2W6CT2+34Ljhg0OeFan8cwlcdq8jrLKsBBuUFAZLsN5b6y491KdKEoSo9lg== + version "1.1.9" + resolved "https://registry.yarnpkg.com/deep-object-diff/-/deep-object-diff-1.1.9.tgz#6df7ef035ad6a0caa44479c536ed7b02570f4595" + integrity sha512-Rn+RuwkmkDwCi2/oXOFS9Gsr5lJZu/yTGpK7wAaAIE75CC+LCGEZHpY6VQJa/RoJcrmaA/docWJZvYohlNkWPA== deepmerge@^4.2.2: version "4.2.2" @@ -9314,9 +9314,9 @@ json-stable-stringify-without-jsonify@^1.0.1: integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE= json5@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/json5/-/json5-1.0.1.tgz#779fb0018604fa854eacbf6252180d83543e3dbe" - integrity sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow== + version "1.0.2" + resolved "https://registry.yarnpkg.com/json5/-/json5-1.0.2.tgz#63d98d60f21b313b77c4d6da18bfa69d80e1d593" + integrity sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA== dependencies: minimist "^1.2.0" @@ -9482,9 +9482,9 @@ loader-utils@2.0.0: json5 "^2.1.2" loader-utils@^1.2.3: - version "1.4.0" - resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-1.4.0.tgz#c579b5e34cb34b1a74edc6c1fb36bfa371d5a613" - integrity sha512-qH0WSMBtn/oHuwjy/NucEgbx5dbxxnxup9s4PVXJUDHZBQY+s0NWA9rJf53RBnQZxfch7euUui7hpoAPvALZdA== + version "1.4.2" + resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-1.4.2.tgz#29a957f3a63973883eb684f10ffd3d151fec01a3" + integrity sha512-I5d00Pd/jwMD2QCduo657+YM/6L3KZu++pmX9VFncxaxvHcru9jx1lBaFft+r4Mt2jK0Yhp41XlRAihzPxHNCg== dependencies: big.js "^5.2.2" emojis-list "^3.0.0" @@ -9904,9 +9904,9 @@ minimatch@^5.0.1: brace-expansion "^2.0.1" minimist@^1.1.1, minimist@^1.2.0, minimist@^1.2.5, minimist@^1.2.6: - version "1.2.6" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" - integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q== + version "1.2.7" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.7.tgz#daa1c4d91f507390437c6a8bc01078e7000c4d18" + integrity sha512-bzfL1YUZsP41gmu/qjrEk0Q6i2ix/cVeAhbCbqH9u3zYutS1cLg00qhrD0M2MVdCcx4Sc0UpP2eBWo9rotpq6g== minipass-collect@^1.0.2: version "1.0.2" diff --git a/server/package.json b/server/package.json index 51b3f5bd..6874108a 100644 --- a/server/package.json +++ b/server/package.json @@ -27,7 +27,7 @@ "jwt-decode": "^3.1.2", "keycloak-connect": "17.0.0", "memorystore": "^1.6.7", - "mongoose": "^6.0.8", + "mongoose": "^6.4.6", "node-cache": "^5.1.2", "subscriptions-transport-ws": "^0.11.0", "winston": "^3.3.3" diff --git a/server/yarn.lock b/server/yarn.lock index a92552bd..8a189d64 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -1830,10 +1830,10 @@ bser@2.1.1: dependencies: node-int64 "^0.4.0" -bson@^4.2.2, bson@^4.6.1: - version "4.6.2" - resolved "https://registry.yarnpkg.com/bson/-/bson-4.6.2.tgz#3241c79d23d225b86ab6d2bc268b803d8a5fd444" - integrity sha512-VeJKHShcu1b/ugl0QiujlVuBepab714X9nNyBdA1kfekuDGecxgpTA2Z6nYbagrWFeiIyzSWIOzju3lhj+RNyQ== +bson@^4.6.2, bson@^4.6.3: + version "4.7.0" + resolved "https://registry.yarnpkg.com/bson/-/bson-4.7.0.tgz#7874a60091ffc7a45c5dd2973b5cad7cded9718a" + integrity sha512-VrlEE4vuiO1WTpfof4VmaVolCVYkYTgB9iWgYNOrVlnifpME/06fhFRmONgBhClD5pFC1t9ZWqFUQEQAzY43bA== dependencies: buffer "^5.6.0" @@ -3302,10 +3302,10 @@ ip-regex@^4.1.0: resolved "https://registry.yarnpkg.com/ip-regex/-/ip-regex-4.3.0.tgz#687275ab0f57fa76978ff8f4dddc8a23d5990db5" integrity sha512-B9ZWJxHHOHUhUjCPrMpLD4xEq35bUTClHM1S6CBU5ixQnkZmwipwgc96vAd7AAGM9TGHvJR+Uss+/Ak6UphK+Q== -ip@^1.1.5: - version "1.1.5" - resolved "https://registry.yarnpkg.com/ip/-/ip-1.1.5.tgz#bdded70114290828c0a039e72ef25f5aaec4354a" - integrity sha1-vd7XARQpCCjAoDnnLvJfWq7ENUo= +ip@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/ip/-/ip-2.0.0.tgz#4cf4ab182fee2314c75ede1276f8c80b479936da" + integrity sha512-WKa+XuLG1A1R0UWhl2+1XQSi+fZWMsYKffMZTTYsiZaUD8k2yDAj5atimTUD2TZkyCkNEeYE5NhFZmupOGtjYQ== ipaddr.js@1.9.1: version "1.9.1" @@ -4018,9 +4018,9 @@ json5@2.x, json5@^2.2.1: integrity sha512-1hqLFMSrGHRHxav9q9gNjJ5EXznIxGVO09xQRrwplcS8qs28pZ8s8hupZAmqDwZUmVZ2Qb2jnyPOWcDH8m8dlA== json5@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/json5/-/json5-1.0.1.tgz#779fb0018604fa854eacbf6252180d83543e3dbe" - integrity sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow== + version "1.0.2" + resolved "https://registry.yarnpkg.com/json5/-/json5-1.0.2.tgz#63d98d60f21b313b77c4d6da18bfa69d80e1d593" + integrity sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA== dependencies: minimist "^1.2.0" @@ -4038,10 +4038,10 @@ jwt-decode@^3.1.2: resolved "https://registry.yarnpkg.com/jwt-decode/-/jwt-decode-3.1.2.tgz#3fb319f3675a2df0c2895c8f5e9fa4b67b04ed59" integrity sha512-UfpWE/VZn0iP50d8cz9NrZLM9lSWhcJ+0Gt/nm4by88UL+J1SiKN8/5dkjMmbEzwL2CAe+67GsegCbIKtbp75A== -kareem@2.3.5: - version "2.3.5" - resolved "https://registry.yarnpkg.com/kareem/-/kareem-2.3.5.tgz#111fe9dbab754c8ed88b7a2360e2680cec1420ca" - integrity sha512-qxCyQtp3ioawkiRNQr/v8xw9KIviMSSNmy+63Wubj7KmMn3g7noRXIZB4vPCAP+ETi2SR8eH6CvmlKZuGpoHOg== +kareem@2.4.1: + version "2.4.1" + resolved "https://registry.yarnpkg.com/kareem/-/kareem-2.4.1.tgz#7d81ec518204a48c1cb16554af126806c3cd82b0" + integrity sha512-aJ9opVoXroQUPfovYP5kaj2lM7Jn02Gw13bL0lg9v0V7SaUc0qavPs0Eue7d2DcC3NjqI6QAUElXNsuZSeM+EA== keycloak-connect@17.0.0: version "17.0.0" @@ -4296,57 +4296,57 @@ minimatch@^3.0.4, minimatch@^3.1.2: brace-expansion "^1.1.7" minimist@^1.2.0, minimist@^1.2.5, minimist@^1.2.6: - version "1.2.6" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" - integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q== + version "1.2.7" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.7.tgz#daa1c4d91f507390437c6a8bc01078e7000c4d18" + integrity sha512-bzfL1YUZsP41gmu/qjrEk0Q6i2ix/cVeAhbCbqH9u3zYutS1cLg00qhrD0M2MVdCcx4Sc0UpP2eBWo9rotpq6g== mkdirp@^1.0.4: version "1.0.4" resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-1.0.4.tgz#3eb5ed62622756d79a5f0e2a221dfebad75c2f7e" integrity sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw== -mongodb-connection-string-url@^2.4.1: - version "2.5.2" - resolved "https://registry.yarnpkg.com/mongodb-connection-string-url/-/mongodb-connection-string-url-2.5.2.tgz#f075c8d529e8d3916386018b8a396aed4f16e5ed" - integrity sha512-tWDyIG8cQlI5k3skB6ywaEA5F9f5OntrKKsT/Lteub2zgwSUlhqEN2inGgBTm8bpYJf8QYBdA/5naz65XDpczA== +mongodb-connection-string-url@^2.5.2: + version "2.5.3" + resolved "https://registry.yarnpkg.com/mongodb-connection-string-url/-/mongodb-connection-string-url-2.5.3.tgz#c0c572b71570e58be2bd52b33dffd1330cfb6990" + integrity sha512-f+/WsED+xF4B74l3k9V/XkTVj5/fxFH2o5ToKXd8Iyi5UhM+sO9u0Ape17Mvl/GkZaFtM0HQnzAG5OTmhKw+tQ== dependencies: "@types/whatwg-url" "^8.2.1" whatwg-url "^11.0.0" -mongodb@4.3.1: - version "4.3.1" - resolved "https://registry.yarnpkg.com/mongodb/-/mongodb-4.3.1.tgz#e346f76e421ec6f47ddea5c8f5140e6181aaeb94" - integrity sha512-sNa8APSIk+r4x31ZwctKjuPSaeKuvUeNb/fu/3B6dRM02HpEgig7hTHM8A/PJQTlxuC/KFWlDlQjhsk/S43tBg== +mongodb@4.7.0: + version "4.7.0" + resolved "https://registry.yarnpkg.com/mongodb/-/mongodb-4.7.0.tgz#99f7323271d93659067695b60e7b4efee2de9bf0" + integrity sha512-HhVar6hsUeMAVlIbwQwWtV36iyjKd9qdhY+s4wcU8K6TOj4Q331iiMy+FoPuxEntDIijTYWivwFJkLv8q/ZgvA== dependencies: - bson "^4.6.1" + bson "^4.6.3" denque "^2.0.1" - mongodb-connection-string-url "^2.4.1" - socks "^2.6.1" + mongodb-connection-string-url "^2.5.2" + socks "^2.6.2" optionalDependencies: saslprep "^1.0.3" -mongoose@*, mongoose@^6.0.8: - version "6.2.11" - resolved "https://registry.yarnpkg.com/mongoose/-/mongoose-6.2.11.tgz#2d1f5987948469ff742463cca28b20c7942676bc" - integrity sha512-YqYAFTOqKthsFduM1IZCArIAwScFJKWoE3pEwmnR7UMw9mynEnOc6c4gBvAon+NtPdB0RAP6ppd3aOvLrVth2g== +mongoose@*, mongoose@^6.4.6: + version "6.4.6" + resolved "https://registry.yarnpkg.com/mongoose/-/mongoose-6.4.6.tgz#57bc7ae68de56abcc5e890284f2d10acac863aa2" + integrity sha512-ZAfNCWgXhwev6k/+rMzjHIJ/+wLkundQU/i+aUTqmCgGoYqc+B5e4EC4Y3E1XaLzNXiWID1/vocSM6zs5IAGvA== dependencies: - bson "^4.2.2" - kareem "2.3.5" - mongodb "4.3.1" - mpath "0.8.4" - mquery "4.0.2" + bson "^4.6.2" + kareem "2.4.1" + mongodb "4.7.0" + mpath "0.9.0" + mquery "4.0.3" ms "2.1.3" sift "16.0.0" -mpath@0.8.4: - version "0.8.4" - resolved "https://registry.yarnpkg.com/mpath/-/mpath-0.8.4.tgz#6b566d9581621d9e931dd3b142ed3618e7599313" - integrity sha512-DTxNZomBcTWlrMW76jy1wvV37X/cNNxPW1y2Jzd4DZkAaC5ZGsm8bfGfNOthcDuRJujXLqiuS6o3Tpy0JEoh7g== +mpath@0.9.0: + version "0.9.0" + resolved "https://registry.yarnpkg.com/mpath/-/mpath-0.9.0.tgz#0c122fe107846e31fc58c75b09c35514b3871904" + integrity sha512-ikJRQTk8hw5DEoFVxHG1Gn9T/xcjtdnOKIU1JTmGjZZlg9LST2mBLmcX3/ICIbgJydT2GOc15RnNy5mHmzfSew== -mquery@4.0.2: - version "4.0.2" - resolved "https://registry.yarnpkg.com/mquery/-/mquery-4.0.2.tgz#a13add5ecd7c2e5a67e0f814b3c7acdfb6772804" - integrity sha512-oAVF0Nil1mT3rxty6Zln4YiD6x6QsUWYz927jZzjMxOK2aqmhEz5JQ7xmrKK7xRFA2dwV+YaOpKU/S+vfNqKxA== +mquery@4.0.3: + version "4.0.3" + resolved "https://registry.yarnpkg.com/mquery/-/mquery-4.0.3.tgz#4d15f938e6247d773a942c912d9748bd1965f89d" + integrity sha512-J5heI+P08I6VJ2Ky3+33IpCdAvlYGTSUjwTPxkAr8i8EoduPMBX2OY/wa3IKZIQl7MU4SbFk8ndgSKyB/cl1zA== dependencies: debug "4.x" @@ -5043,12 +5043,12 @@ smart-buffer@^4.2.0: resolved "https://registry.yarnpkg.com/smart-buffer/-/smart-buffer-4.2.0.tgz#6e1d71fa4f18c05f7d0ff216dd16a481d0e8d9ae" integrity sha512-94hK0Hh8rPqQl2xXc3HsaBoOXKV20MToPkcXvwbISWLEs+64sBq5kFgn2kJDHb1Pry9yrP0dxrCI9RRci7RXKg== -socks@^2.6.1: - version "2.6.2" - resolved "https://registry.yarnpkg.com/socks/-/socks-2.6.2.tgz#ec042d7960073d40d94268ff3bb727dc685f111a" - integrity sha512-zDZhHhZRY9PxRruRMR7kMhnf3I8hDs4S3f9RecfnGxvcBHQcKcIH/oUcEWffsfl1XxdYlA7nnlGbbTvPz9D8gA== +socks@^2.6.2: + version "2.7.0" + resolved "https://registry.yarnpkg.com/socks/-/socks-2.7.0.tgz#f9225acdb841e874dca25f870e9130990f3913d0" + integrity sha512-scnOe9y4VuiNUULJN72GrM26BNOjVsfPXI+j+98PkyEfsIXroa5ofyjT+FzGvn/xHs73U2JtoBYAVx9Hl4quSA== dependencies: - ip "^1.1.5" + ip "^2.0.0" smart-buffer "^4.2.0" source-map-support@^0.5.12, source-map-support@^0.5.17, source-map-support@^0.5.6: diff --git a/test-node/yarn.lock b/test-node/yarn.lock index a0511b65..34549f7c 100644 --- a/test-node/yarn.lock +++ b/test-node/yarn.lock @@ -1368,9 +1368,9 @@ isexe@^2.0.0: integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= jose@^2.0.5: - version "2.0.5" - resolved "https://registry.yarnpkg.com/jose/-/jose-2.0.5.tgz#29746a18d9fff7dcf9d5d2a6f62cb0c7cd27abd3" - integrity sha512-BAiDNeDKTMgk4tvD0BbxJ8xHEHBZgpeRZ1zGPPsitSyMgjoMWiLGYAE7H7NpP5h0lPppQajQs871E8NHUrzVPA== + version "2.0.6" + resolved "https://registry.yarnpkg.com/jose/-/jose-2.0.6.tgz#894ba19169af339d3911be933f913dd02fc57c7c" + integrity sha512-FVoPY7SflDodE4lknJmbAHSUjLCzE2H1F6MS0RYKMQ8SR+lNccpMf8R4eqkNYyyUjR5qZReOzZo5C5YiHOCjjg== dependencies: "@panva/asn1.js" "^1.0.0" @@ -1403,9 +1403,9 @@ json-stable-stringify-without-jsonify@^1.0.1: integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE= json5@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/json5/-/json5-1.0.1.tgz#779fb0018604fa854eacbf6252180d83543e3dbe" - integrity sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow== + version "1.0.2" + resolved "https://registry.yarnpkg.com/json5/-/json5-1.0.2.tgz#63d98d60f21b313b77c4d6da18bfa69d80e1d593" + integrity sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA== dependencies: minimist "^1.2.0" @@ -1623,9 +1623,9 @@ minimatch@^3.0.4, minimatch@^3.1.2: brace-expansion "^1.1.7" minimist@^1.2.0, minimist@^1.2.5, minimist@^1.2.6: - version "1.2.6" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.6.tgz#8637a5b759ea0d6e98702cfb3a9283323c93af44" - integrity sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q== + version "1.2.7" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.7.tgz#daa1c4d91f507390437c6a8bc01078e7000c4d18" + integrity sha512-bzfL1YUZsP41gmu/qjrEk0Q6i2ix/cVeAhbCbqH9u3zYutS1cLg00qhrD0M2MVdCcx4Sc0UpP2eBWo9rotpq6g== mkdirp@^1.0.4: version "1.0.4" From c964ccc03a35251b5ff0e0fa31b670b2d5dfacc1 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Fri, 24 Feb 2023 10:07:22 -0500 Subject: [PATCH 03/57] Add gnomadHet column w/ number of heterozygotes (#334) * Add gnomadHet calculation - Add comments * Change gnomadHet to use PrimaryAF - Kept AF displayed as max between primary and secondary AF * Update tests --- react/src/components/Table/Table.tsx | 8 +++++++- react/src/types.ts | 2 +- react/src/utils/tableHelpers.ts | 2 ++ server/__tests__/utils/annotateGnomad.test.ts | 3 +++ .../resolvers/getVariantsResolver/utils/annotateGnomad.ts | 5 +++++ server/src/types.ts | 2 +- 6 files changed, 19 insertions(+), 3 deletions(-) diff --git a/react/src/components/Table/Table.tsx b/react/src/components/Table/Table.tsx index 6525ec72..52166029 100644 --- a/react/src/components/Table/Table.tsx +++ b/react/src/components/Table/Table.tsx @@ -243,7 +243,13 @@ const Table: React.FC = ({ variantData }) => { width: getColumnWidth('gnomAD_AF', true), filter: 'between', }, - /* { accessor: 'gnomadHet', id: 'gnomadHet', Header: 'gnomadHet', width: 105 }, */ + { + accessor: 'gnomadHet', + id: 'gnomadHet', + Header: 'gnomadHet', + width: getColumnWidth('gnomadHet'), + filter: 'between', + }, { accessor: 'gnomadHom', id: 'gnomadHom', diff --git a/react/src/types.ts b/react/src/types.ts index 0a6fa04f..53c60071 100644 --- a/react/src/types.ts +++ b/react/src/types.ts @@ -7,7 +7,7 @@ export interface VariantResponseInfoFields { cdna?: Maybe; consequence?: Maybe; geneName?: Maybe; - gnomadHet?: Maybe; + gnomadHet?: Maybe; gnomadHom?: Maybe; phred?: Maybe; spliceAIScore?: Maybe; diff --git a/react/src/utils/tableHelpers.ts b/react/src/utils/tableHelpers.ts index 29400901..70cdda5a 100644 --- a/react/src/utils/tableHelpers.ts +++ b/react/src/utils/tableHelpers.ts @@ -173,12 +173,14 @@ export const prepareData = ( sortedQueryResult.forEach(d => { const { ref, alt, start, end } = d.variant; + // if different variant from previous iteration if ( currVariant.ref !== ref || currVariant.alt !== alt || currVariant.start !== start || currVariant.end !== end ) { + // If this isn't the first variant if (uniqueVariantIndices.length) { result .slice(uniqueVariantIndices[uniqueVariantIndices.length - 1], currRowId) diff --git a/server/__tests__/utils/annotateGnomad.test.ts b/server/__tests__/utils/annotateGnomad.test.ts index a0101e81..6efbd632 100644 --- a/server/__tests__/utils/annotateGnomad.test.ts +++ b/server/__tests__/utils/annotateGnomad.test.ts @@ -61,6 +61,9 @@ describe('Test whether variants get annotated', () => { af: Math.max(primaryAnnotations[0].af, secondaryAnnotations[0].af), an: primaryAnnotations[0].an, gnomadHom: primaryAnnotations[0].nhomalt, + gnomadHet: + Math.round(primaryAnnotations[0].an * primaryAnnotations[0].af) - + primaryAnnotations[0].nhomalt * 2, }) ); }); diff --git a/server/src/resolvers/getVariantsResolver/utils/annotateGnomad.ts b/server/src/resolvers/getVariantsResolver/utils/annotateGnomad.ts index cd79ed5d..edf99492 100644 --- a/server/src/resolvers/getVariantsResolver/utils/annotateGnomad.ts +++ b/server/src/resolvers/getVariantsResolver/utils/annotateGnomad.ts @@ -39,11 +39,16 @@ export const annotateGnomad = ( // and the overall allele frequency will simply be the genome allele frequency const secondaryAF = secondaryAnnotationKeyMap?.[variantKey]?.af ?? 0; + const primaryIsGenome = 'ac' in rest; + const ac = primaryIsGenome ? rest.ac : Math.round(rest.an * primaryAF); r.variant.info = { ...r.variant.info, // The overall allele frequency is calculated as the greater value between the exome allele frequency and the genome allele frequency af: Math.max(primaryAF, secondaryAF), gnomadHom: nhomalt, + // https://www.biostars.org/p/440426/; each homozygote adds 2 to allele count, so remaining are heterozygotes + // only works for autosomes and X chromosome + gnomadHet: ac - 2 * nhomalt, ...rest, }; } diff --git a/server/src/types.ts b/server/src/types.ts index 1b1f6dad..7e39916c 100644 --- a/server/src/types.ts +++ b/server/src/types.ts @@ -8,7 +8,7 @@ export interface VariantResponseInfoFields { cdna?: Maybe; consequence?: Maybe; geneName?: Maybe; - gnomadHet?: Maybe; + gnomadHet?: Maybe; gnomadHom?: Maybe; phred?: Maybe; spliceAIScore?: Maybe; From 82fcc7403f31471972a2c449b91d1dff0f489598 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Mon, 6 Mar 2023 09:38:27 -0500 Subject: [PATCH 04/57] Add maleCount field to table rows (#335) --- react/src/components/Table/Table.tsx | 8 ++++++++ react/src/utils/tableHelpers.ts | 18 ++++++++++++++++-- 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/react/src/components/Table/Table.tsx b/react/src/components/Table/Table.tsx index 52166029..1ab4ba7c 100644 --- a/react/src/components/Table/Table.tsx +++ b/react/src/components/Table/Table.tsx @@ -64,6 +64,7 @@ export type FlattenedQueryResponse = Omit = ({ variantData }) => { width: getColumnWidth('SpliceAI type'), filter: 'multiSelect', }, + { + accessor: 'maleCount', + id: 'maleCount', + Header: 'Male Count', + width: getColumnWidth('Male Count'), + filter: 'between', + }, ], }, { diff --git a/react/src/utils/tableHelpers.ts b/react/src/utils/tableHelpers.ts index 70cdda5a..26a5302b 100644 --- a/react/src/utils/tableHelpers.ts +++ b/react/src/utils/tableHelpers.ts @@ -57,6 +57,8 @@ const addAdditionalFieldsAndFormatNulls = ( aaChange: results.aaChange || 'NA', af: results.af || 0, gnomadHom: results.gnomadHom || 0, + gnomadHet: results.gnomadHet || 0, + maleCount: 0, }); export const calculateColumnWidth = ( @@ -119,6 +121,8 @@ export const isHomozygous = (zygosity: string | null | undefined) => { return !!zygosity?.toLowerCase().includes('hom'); }; +export const isMale = (sex: string | null | undefined) => sex === 'Male'; + export const isLastCellInSet = (cell: Cell, columnOrder: string[]) => !!cell.column && // Check if the cell's column is the last in its set (excluding hidden columns) @@ -154,7 +158,7 @@ export const isLastHeaderInSet = ( }; // 1, Sort queryResult in ascending order according to variant's ref, alt, start, end. -// 2, Flatten data and compute values as needed (note that column display formatting function should not alter values for ease of export). Assign uniqueId, homozygousCount, heterozygousCount to each row. +// 2, Flatten data and compute values as needed (note that column display formatting function should not alter values for ease of export). Assign uniqueId, homozygousCount, heterozygousCount, maleCount to each row. export const prepareData = ( queryResult: VariantQueryDataResult[] ): [ResultTableColumns[], number[]] => { @@ -170,7 +174,9 @@ export const prepareData = ( var currRowId = 0; var currHomozygousCount = 0; var currHeterozygousCount = 0; + var currMaleCount = 0; + // sorted by variant sortedQueryResult.forEach(d => { const { ref, alt, start, end } = d.variant; // if different variant from previous iteration @@ -180,13 +186,14 @@ export const prepareData = ( currVariant.start !== start || currVariant.end !== end ) { - // If this isn't the first variant + // Update previous batch of rows that were all the same variant if (uniqueVariantIndices.length) { result .slice(uniqueVariantIndices[uniqueVariantIndices.length - 1], currRowId) .forEach(row => { row.homozygousCount = currHomozygousCount; row.heterozygousCount = currHeterozygousCount; + row.maleCount = currMaleCount; }); } @@ -194,9 +201,11 @@ export const prepareData = ( currHeterozygousCount = 0; currVariant = { ref, alt, start, end }; currUniqueId += 1; + currMaleCount = 0; uniqueVariantIndices.push(currRowId); } + // update counts if (d.variant.callsets.length) { result.push.apply( result, @@ -208,6 +217,10 @@ export const prepareData = ( } else if (isHomozygous(cs.info.zygosity)) { currHomozygousCount += 1; } + if (isMale(d.individual.sex)) { + currMaleCount += 1; + } + return true; } else { return false; @@ -231,6 +244,7 @@ export const prepareData = ( result.slice(uniqueVariantIndices[uniqueVariantIndices.length - 1], currRowId).forEach(row => { row.homozygousCount = currHomozygousCount; row.heterozygousCount = currHeterozygousCount; + row.maleCount = currMaleCount; }); // Remove duplicate variants for the same patient From b11acabd70f90e5f530c4ecdb5c805dd40c1c891 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Mon, 6 Mar 2023 10:05:42 -0500 Subject: [PATCH 05/57] Fix male count (#337) --- react/src/utils/tableHelpers.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/react/src/utils/tableHelpers.ts b/react/src/utils/tableHelpers.ts index 26a5302b..8c15d66d 100644 --- a/react/src/utils/tableHelpers.ts +++ b/react/src/utils/tableHelpers.ts @@ -121,7 +121,7 @@ export const isHomozygous = (zygosity: string | null | undefined) => { return !!zygosity?.toLowerCase().includes('hom'); }; -export const isMale = (sex: string | null | undefined) => sex === 'Male'; +export const isMale = (sex: string | null | undefined) => resolveSex('' + sex) === 'Male'; export const isLastCellInSet = (cell: Cell, columnOrder: string[]) => !!cell.column && From 21a94019ba81f9b8c6ad15958daf5a4d71b8c9b4 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Fri, 10 Mar 2023 09:28:03 -0500 Subject: [PATCH 06/57] Add allele count column, remove gnomadHet and male count (#338) * Replace gnomadHet with AC count * Add AC column to frontend - update tests * Update typedefs * Fix graphQL query, frontend query preparing * Hide male count by default * Comment out male count; redundant info --- .../src/apollo/hooks/useFetchVariantsQuery.ts | 2 +- react/src/components/Table/Table.tsx | 22 +++++++++---------- react/src/constants/headers.ts | 3 +++ react/src/types.ts | 2 +- react/src/utils/tableHelpers.ts | 3 ++- server/__tests__/gql/getVariants.test.ts | 2 +- server/__tests__/utils/annotateGnomad.test.ts | 4 +--- .../utils/annotateGnomad.ts | 16 ++++++++++---- server/src/typeDefs.ts | 2 +- server/src/types.ts | 2 +- 10 files changed, 34 insertions(+), 24 deletions(-) diff --git a/react/src/apollo/hooks/useFetchVariantsQuery.ts b/react/src/apollo/hooks/useFetchVariantsQuery.ts index 4d7391bc..ad529a02 100644 --- a/react/src/apollo/hooks/useFetchVariantsQuery.ts +++ b/react/src/apollo/hooks/useFetchVariantsQuery.ts @@ -25,10 +25,10 @@ const fetchVariantsQuery = gql` info { aaChange af + ac cdna consequence geneName - gnomadHet gnomadHom phred spliceAIScore diff --git a/react/src/components/Table/Table.tsx b/react/src/components/Table/Table.tsx index 1ab4ba7c..4702f8e6 100644 --- a/react/src/components/Table/Table.tsx +++ b/react/src/components/Table/Table.tsx @@ -223,6 +223,13 @@ const Table: React.FC = ({ variantData }) => { width: getColumnWidth('Het Count'), filter: 'between', }, + // { + // accessor: 'maleCount', + // id: 'maleCount', + // Header: 'Male Count', + // width: getColumnWidth('Male Count'), + // filter: 'between', + // }, { accessor: 'cdna', id: 'cdna', Header: 'cdna', width: getColumnWidth('cdna') }, { id: 'aaChange', @@ -245,10 +252,10 @@ const Table: React.FC = ({ variantData }) => { filter: 'between', }, { - accessor: 'gnomadHet', - id: 'gnomadHet', - Header: 'gnomadHet', - width: getColumnWidth('gnomadHet'), + accessor: 'ac', + id: 'ac', + Header: 'gnomAD_AC', + width: getColumnWidth('gnomAD_AC', true), filter: 'between', }, { @@ -279,13 +286,6 @@ const Table: React.FC = ({ variantData }) => { width: getColumnWidth('SpliceAI type'), filter: 'multiSelect', }, - { - accessor: 'maleCount', - id: 'maleCount', - Header: 'Male Count', - width: getColumnWidth('Male Count'), - filter: 'between', - }, ], }, { diff --git a/react/src/constants/headers.ts b/react/src/constants/headers.ts index 13c66f2e..0bd06597 100644 --- a/react/src/constants/headers.ts +++ b/react/src/constants/headers.ts @@ -5,6 +5,7 @@ const HEADERS: { [x: string]: string } = { source: 'The institution where the data comes from', af: 'Allele frequency from gnomAD, defined as the greater value between the exome allele frequency and the genome allele frequency.', + ac: 'Allele count from gnomAD. This is calculated as the sum of the genome and exome allele counts (for GRCh38 assemblies, this is only genome allele count).', ethnicity: 'Ethnic background of the individual. Value from NCIT Race ontology (NCIT:C17049), e.g. NCIT:C126531 (Latin American).', sex: 'Sex of the individual. Value from NCIT General Qualifier (NCIT:C27993) ontology: UNKNOWN (not assessed or not available) (NCIT:C17998), FEMALE (NCIT:C46113), MALE, (NCIT:C46112) or OTHER SEX (NCIT:C45908).', @@ -13,6 +14,8 @@ const HEADERS: { [x: string]: string } = { diseases: 'List of disease(s) been diagnosed to the individual, defined by disease ICD10 code, optionally other disease ontology ID(s), age of onset, stage and the presence of family history.', contactInfo: 'Contact information for the record owner', + maleCount: + "Total number of male participants with this variant returned from all sources. This is NOT retrieved from gnomAD, only what's retrieved from the selected sources.", }; export default HEADERS; diff --git a/react/src/types.ts b/react/src/types.ts index 53c60071..a58db133 100644 --- a/react/src/types.ts +++ b/react/src/types.ts @@ -4,10 +4,10 @@ import { Maybe } from 'graphql/jsutils/Maybe'; export interface VariantResponseInfoFields { aaChange?: Maybe; af?: Maybe; + ac?: Maybe; cdna?: Maybe; consequence?: Maybe; geneName?: Maybe; - gnomadHet?: Maybe; gnomadHom?: Maybe; phred?: Maybe; spliceAIScore?: Maybe; diff --git a/react/src/utils/tableHelpers.ts b/react/src/utils/tableHelpers.ts index 8c15d66d..d33838ae 100644 --- a/react/src/utils/tableHelpers.ts +++ b/react/src/utils/tableHelpers.ts @@ -56,8 +56,9 @@ const addAdditionalFieldsAndFormatNulls = ( cdna: results.cdna || 'NA', aaChange: results.aaChange || 'NA', af: results.af || 0, + ac: results.ac || 0, gnomadHom: results.gnomadHom || 0, - gnomadHet: results.gnomadHet || 0, + // gnomadHet: results.gnomadHet || 0, maleCount: 0, }); diff --git a/server/__tests__/gql/getVariants.test.ts b/server/__tests__/gql/getVariants.test.ts index 659855cb..3671acef 100644 --- a/server/__tests__/gql/getVariants.test.ts +++ b/server/__tests__/gql/getVariants.test.ts @@ -29,10 +29,10 @@ describe('Test minimal getVariants query', () => { info { aaChange af + ac cdna consequence geneName - gnomadHet gnomadHom transcript } diff --git a/server/__tests__/utils/annotateGnomad.test.ts b/server/__tests__/utils/annotateGnomad.test.ts index 6efbd632..031865fd 100644 --- a/server/__tests__/utils/annotateGnomad.test.ts +++ b/server/__tests__/utils/annotateGnomad.test.ts @@ -61,9 +61,7 @@ describe('Test whether variants get annotated', () => { af: Math.max(primaryAnnotations[0].af, secondaryAnnotations[0].af), an: primaryAnnotations[0].an, gnomadHom: primaryAnnotations[0].nhomalt, - gnomadHet: - Math.round(primaryAnnotations[0].an * primaryAnnotations[0].af) - - primaryAnnotations[0].nhomalt * 2, + ac: primaryAnnotations[0].af * primaryAnnotations[0].an + secondaryAnnotations[0].ac, }) ); }); diff --git a/server/src/resolvers/getVariantsResolver/utils/annotateGnomad.ts b/server/src/resolvers/getVariantsResolver/utils/annotateGnomad.ts index edf99492..63492ef5 100644 --- a/server/src/resolvers/getVariantsResolver/utils/annotateGnomad.ts +++ b/server/src/resolvers/getVariantsResolver/utils/annotateGnomad.ts @@ -9,6 +9,10 @@ const _mapToAnnotationsKeyMap = ( annotations: (GnomadGRCh37ExomeAnnotation | GnomadGenomeAnnotation)[] ) => Object.fromEntries(annotations.map(a => [`${a.ref}-${a.pos}-${a.chrom}`, a])); +const _isGenomeAnnotation = ( + annotation: GnomadGRCh37ExomeAnnotation | GnomadGenomeAnnotation +): annotation is GnomadGenomeAnnotation => annotation && 'ac' in annotation; + export const annotateGnomad = ( queryResponse: VariantQueryDataResult[], annotations: GnomadAnnotations @@ -37,18 +41,22 @@ export const annotateGnomad = ( /* eslint-enable @typescript-eslint/no-unused-vars */ // For the GRCh38 assembly, there aren't any secondary gnomAD annotations, so secondaryAF will always be 0 // and the overall allele frequency will simply be the genome allele frequency - const secondaryAF = secondaryAnnotationKeyMap?.[variantKey]?.af ?? 0; + const secondaryAnnotation = secondaryAnnotationKeyMap?.[variantKey]; + const secondaryAF = secondaryAnnotation?.af ?? 0; - const primaryIsGenome = 'ac' in rest; - const ac = primaryIsGenome ? rest.ac : Math.round(rest.an * primaryAF); + // GRCh38 only has primary genome; GRCh37 has primary exome and secondary genome + const is38 = 'ac' in rest; + const primaryAC = is38 ? rest.ac : Math.round(rest.an * primaryAF); + const secondaryAC = _isGenomeAnnotation(secondaryAnnotation) ? secondaryAnnotation.ac : 0; // always genome annotation or empty r.variant.info = { ...r.variant.info, // The overall allele frequency is calculated as the greater value between the exome allele frequency and the genome allele frequency af: Math.max(primaryAF, secondaryAF), gnomadHom: nhomalt, + ac: primaryAC + secondaryAC, // https://www.biostars.org/p/440426/; each homozygote adds 2 to allele count, so remaining are heterozygotes // only works for autosomes and X chromosome - gnomadHet: ac - 2 * nhomalt, + // gnomadHet: ac - 2 * nhomalt, ...rest, }; } diff --git a/server/src/typeDefs.ts b/server/src/typeDefs.ts index 64f5c37d..fd22f0ac 100644 --- a/server/src/typeDefs.ts +++ b/server/src/typeDefs.ts @@ -9,11 +9,11 @@ export default gql` type VariantResponseInfoFields { aaChange: String af: Float + ac: Int assembly: String cdna: String consequence: String geneName: String - gnomadHet: Int gnomadHom: Int phred: Float spliceAIScore: Float diff --git a/server/src/types.ts b/server/src/types.ts index 7e39916c..b6288d36 100644 --- a/server/src/types.ts +++ b/server/src/types.ts @@ -5,10 +5,10 @@ import { Maybe } from 'graphql/jsutils/Maybe'; export interface VariantResponseInfoFields { aaChange?: Maybe; af?: Maybe; + ac?: Maybe; cdna?: Maybe; consequence?: Maybe; geneName?: Maybe; - gnomadHet?: Maybe; gnomadHom?: Maybe; phred?: Maybe; spliceAIScore?: Maybe; From 68f477b9cb6bae2928a92637b3f693e62c17314e Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Thu, 11 May 2023 16:25:27 -0400 Subject: [PATCH 07/57] React: Bump timeout from 90 sec to 900 sec (#339) * Bump timeout from 90 sec to 900 sec - Suggested by Matt, Magda (2023-03-13) * Reduce to 5 minutes * Revert "Reduce to 5 minutes" This reverts commit 758f9b951a284c76a7a0fb8072b09f4a8c767744. * Fix comment --- react/src/apollo/client.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/react/src/apollo/client.ts b/react/src/apollo/client.ts index 2ca5c667..2d3154a4 100644 --- a/react/src/apollo/client.ts +++ b/react/src/apollo/client.ts @@ -12,7 +12,7 @@ import { VariantQueryResponseError } from '../types'; const GRAPHQL_URL = process.env.REACT_APP_GRAPHQL_URL; export const buildLink = (token?: string) => { - const timeoutLink = new ApolloLinkTimeout(90_000); // 90 second timeout + const timeoutLink = new ApolloLinkTimeout(900_000); // 900 second timeout const mygeneRestLink = new RestLink({ uri: 'https://mygene.info/v3/', }); From f4c5e78639e2459e41bb0a2787d08b6b6b3688ab Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Mon, 15 May 2023 15:28:50 -0400 Subject: [PATCH 08/57] CMH Integration (#341) * Fix typo in g4rdAdapter * Add CMH adapter * Add source prefixes; fix error messages * Update docs * Update staging server deploy with CMH vars * Remove cmh env vars from docker prod (for now) --- .env.sample | 9 + .github/workflows/node.yml | 8 + docker-compose.staging.yaml | 8 + docker-compose.yaml | 8 + docs/production.md | 2 +- docs/staging.md | 2 +- react/src/utils/tableHelpers.ts | 12 + .../adapters/cmhAdapter.ts | 303 ++++++++++++++++++ .../adapters/g4rdAdapter.ts | 4 +- .../adapters/remoteTestNodeAdapter.ts | 2 +- .../getVariantsResolver.ts | 3 + 11 files changed, 356 insertions(+), 5 deletions(-) create mode 100644 server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts diff --git a/.env.sample b/.env.sample index c26c3a6a..0222e6e9 100644 --- a/.env.sample +++ b/.env.sample @@ -48,4 +48,13 @@ G4RD_AUTH_METHOD=bearer G4RD_TOKEN_URL=https://some-provider.example.com G4RD_AUTH0_BASE_URL=https://some-subdomain.auth0.com +CMH_AZURE_CLIENT_ID=replacethis_id +CMH_AZURE_CLIENT_SECRET=replacethis_secret +CMH_TOKEN_URL=https://replacethis.fakeurl +CMH_RESOURCE=replacethis_id +CMH_SCOPE=https://replacethis.fakeurl/something +CMH_GRANT_TYPE=client_credentials +CMH_GENE42_SECRET=replacethis_secret +CMH_URL=https://replacethis.fakeurl + SERVER_SESSION_SECRET=secret diff --git a/.github/workflows/node.yml b/.github/workflows/node.yml index 3699332c..0116cf01 100644 --- a/.github/workflows/node.yml +++ b/.github/workflows/node.yml @@ -163,6 +163,14 @@ jobs: G4RD_GRANT_TYPE: ${{ secrets.G4RD_GRANT_TYPE }} G4RD_TOKEN_URL: ${{ secrets.G4RD_TOKEN_URL }} G4RD_CLIENT_ID: ${{ secrets.G4RD_CLIENT_ID }} + CMH_AZURE_CLIENT_ID: ${{ secrets.CMH_AZURE_CLIENT_ID }} + CMH_AZURE_CLIENT_SECRET: ${{ secrets.CMH_AZURE_CLIENT_SECRET }} + CMH_TOKEN_URL: ${{ secrets.CMH_TOKEN_URL }} + CMH_RESOURCE: ${{ secrets.CMH_RESOURCE }} + CMH_SCOPE: ${{ secrets.CMH_SCOPE }} + CMH_GRANT_TYPE: ${{ secrets.CMH_GRANT_TYPE }} + CMH_GENE42_SECRET: ${{ secrets.CMH_GENE42_SECRET }} + CMH_URL: ${{ secrets.CMH_URL }} KEYCLOAK_AUTH_URL: ${{ secrets.KEYCLOAK_AUTH_URL }} KEYCLOAK_REALM: ${{ secrets.KEYCLOAK_REALM }} KEYCLOAK_CLIENT_ID: ${{ secrets.KEYCLOAK_CLIENT_ID }} diff --git a/docker-compose.staging.yaml b/docker-compose.staging.yaml index 379d0e1d..fb32a9b1 100644 --- a/docker-compose.staging.yaml +++ b/docker-compose.staging.yaml @@ -21,6 +21,14 @@ services: G4RD_GRANT_TYPE: G4RD_TOKEN_URL: G4RD_CLIENT_ID: + CMH_AZURE_CLIENT_ID: + CMH_AZURE_CLIENT_SECRET: + CMH_TOKEN_URL: + CMH_RESOURCE: + CMH_SCOPE: + CMH_GRANT_TYPE: + CMH_GENE42_SECRET: + CMH_URL: KEYCLOAK_AUTH_URL: KEYCLOAK_CLIENT_ID: KEYCLOAK_REALM: diff --git a/docker-compose.yaml b/docker-compose.yaml index fcf5c142..9e2f97c5 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -37,6 +37,14 @@ services: G4RD_TOKEN_URL: G4RD_URL: G4RD_USERNAME: + CMH_AZURE_CLIENT_ID: + CMH_AZURE_CLIENT_SECRET: + CMH_TOKEN_URL: + CMH_RESOURCE: + CMH_SCOPE: + CMH_GRANT_TYPE: + CMH_GENE42_SECRET: + CMH_URL: KEYCLOAK_AUTH_URL: KEYCLOAK_REALM: KEYCLOAK_CLIENT_ID: ${KEYCLOAK_SERVER_CLIENT_ID} diff --git a/docs/production.md b/docs/production.md index b2af21f1..be57e740 100644 --- a/docs/production.md +++ b/docs/production.md @@ -1,6 +1,6 @@ # Production -OSMP is deployed via Docker Compose at [https://osmp.genomics4rd.ca](https://osmp.genomics4rd.ca). The key differences between the staging and production are the removal of the test node and increased memory and CPU resource allocations for the `server` container. The OSMP production instance is connected to the [production instance of G4RD Phenotips](https://phenotips.genomics4rd.ca). Similar to the staging stack, to deploy the frontend, compiled static bundles are uploaded to a designated MinIO bucket. The routing between the frontend and backend is handled by the HAProxy reverse proxy. User accounts are managed in [Keycloak](https://keycloak.genomics4rd.ca). +OSMP is deployed via Docker Compose at [https://osmp.genomics4rd.ca](https://osmp.genomics4rd.ca). The key differences between the staging and production are the removal of the test node and increased memory and CPU resource allocations for the `server` container. The OSMP production instance is connected to the [production instance of G4RD Phenotips](https://phenotips.genomics4rd.ca) and to the [production instance of CMH Phenotips](https://phenotips-ga4k.cmh.edu). Similar to the staging stack, to deploy the frontend, compiled static bundles are uploaded to a designated MinIO bucket. The routing between the frontend and backend is handled by the HAProxy reverse proxy. User accounts are managed in [Keycloak](https://keycloak.genomics4rd.ca). ## Continuous deployment through Github Actions diff --git a/docs/staging.md b/docs/staging.md index 4fbd8de6..256a0985 100644 --- a/docs/staging.md +++ b/docs/staging.md @@ -1,6 +1,6 @@ # Staging -OSMP is deployed via Docker Compose at [https://osmp.ccmdev.ca/](https://osmp.ccmdev.ca/). For G4RD data source, the OSMP staging instance is connected to the [staging instance of G4RD Phenotips](https://staging.phenotips.genomics4rd.ca). To deploy the frontend, compiled static bundles are uploaded to a designated MinIO bucket. The routing between the frontend and backend is handled by the HAProxy reverse proxy. User accounts are managed in [Keycloak](https://keycloak.ccmdev.ca). +OSMP is deployed via Docker Compose at [https://osmp.ccmdev.ca/](https://osmp.ccmdev.ca/). For G4RD data source, the OSMP staging instance is connected to the [staging instance of G4RD Phenotips](https://staging.phenotips.genomics4rd.ca) and the [staging instance of CMH Phenotips](https://phenotipstest-ga4k.cmh.edu). To deploy the frontend, compiled static bundles are uploaded to a designated MinIO bucket. The routing between the frontend and backend is handled by the HAProxy reverse proxy. User accounts are managed in [Keycloak](https://keycloak.ccmdev.ca). ## Continuous deployment through Github Actions diff --git a/react/src/utils/tableHelpers.ts b/react/src/utils/tableHelpers.ts index d33838ae..68b18581 100644 --- a/react/src/utils/tableHelpers.ts +++ b/react/src/utils/tableHelpers.ts @@ -248,6 +248,18 @@ export const prepareData = ( row.maleCount = currMaleCount; }); + // update individualId, familyId with source prefix + // (P0001 from G4RD is not the same as P0001 from CMH) + result.map(r => { + if (r.individualId) { + r.individualId = [r.source, r.individualId].join('_'); + } + if (r.familyId) { + r.familyId = [r.source, r.familyId].join('_'); + } + return r; + }); + // Remove duplicate variants for the same patient const uniquePatientVariants = result.filter( (arr, index, self) => diff --git a/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts new file mode 100644 index 00000000..da3deca3 --- /dev/null +++ b/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts @@ -0,0 +1,303 @@ +import axios, { AxiosError, AxiosResponse } from 'axios'; +import jwtDecode from 'jwt-decode'; +import { URLSearchParams } from 'url'; +import { v4 as uuidv4 } from 'uuid'; +import logger from '../../../logger'; +import { + ErrorTransformer, + IndividualResponseFields, + QueryInput, + ResultTransformer, + VariantQueryResponse, + VariantResponseFields, + G4RDFamilyQueryResult, + G4RDPatientQueryResult, + G4RDVariantQueryResult, + Disorder, + IndividualInfoFields, + PhenotypicFeaturesFields, + NonStandardFeature, + Feature, +} from '../../../types'; +import { getFromCache, putInCache } from '../../../utils/cache'; +import { timeit, timeitAsync } from '../../../utils/timeit'; +import resolveAssembly from '../utils/resolveAssembly'; + +/* eslint-disable camelcase */ + +/** + * CMH's PhenoTips instance should have the same format as G4RD. + * However, there's a different process in place for accessing it: + * - Request access token from Azure, + * - Provide token and Gene42 secret when querying CMH PT. + */ + +const SOURCE_NAME = 'cmh'; +const AZURE_BEARER_CACHE_KEY = 'cmhToken'; + +type CMHNodeQueryError = AxiosError; + +/** + * @param args VariantQueryInput + * @returns Promise + */ +const _getCMHNodeQuery = async ({ + input: { gene: geneInput, variant }, +}: QueryInput): Promise => { + let CMHNodeQueryError: CMHNodeQueryError | null = null; + let CMHVariantQueryResponse: null | AxiosResponse = null; + let CMHPatientQueryResponse: null | AxiosResponse = null; + const FamilyIds: null | Record = {}; // + let Authorization = ''; + try { + Authorization = await getAuthHeader(); + } catch (e: any) { + logger.error(e); + logger.error(JSON.stringify(e?.response?.data)); + return { + data: [], + error: { code: 403, message: 'ERROR FETCHING OAUTH TOKEN', id: uuidv4() }, + source: SOURCE_NAME, + }; + } + const url = `${process.env.CMH_URL}/rest/variants/match`; + /* eslint-disable @typescript-eslint/no-unused-vars */ + const { position, ...gene } = geneInput; + variant.assemblyId = 'GRCh37'; + try { + CMHVariantQueryResponse = await axios.post( + url, + { + gene, + variant, + }, + { + headers: { + Authorization, + 'Content-Type': 'application/json', + Accept: 'application/json', + 'X-Gene42-Secret': `${process.env.CMH_GENE42_SECRET}`, // + }, + } + ); + + // Get patients info + if (CMHVariantQueryResponse) { + let individualIds = CMHVariantQueryResponse.data.results + .map(v => v.individual.individualId!) + .filter(Boolean); // Filter out undefined and null values. + + // Get all unique individual Ids. + individualIds = [...new Set(individualIds)]; + + if (individualIds.length > 0) { + const patientUrl = `${process.env.CMH_URL}/rest/patients/fetch?${individualIds + .map(id => `id=${id}`) + .join('&')}`; + + CMHPatientQueryResponse = await axios.get( + new URL(patientUrl).toString(), + { + headers: { + Authorization, + 'Content-Type': 'application/json', + Accept: 'application/json', + 'X-Gene42-Secret': `${process.env.CMH_GENE42_SECRET}`, + }, + } + ); + + // Get Family Id for each patient. + const patientFamily = axios.create({ + headers: { + Authorization, + 'Content-Type': 'application/json', + Accept: 'application/json', + 'X-Gene42-Secret': `${process.env.CMH_GENE42_SECRET}`, + }, + }); + + const familyResponses = await Promise.allSettled( + individualIds.map(id => + patientFamily.get( + new URL(`${process.env.CMH_URL}/rest/patients/${id}/family`).toString() + ) + ) + ); + + familyResponses.forEach((response, index) => { + if (response.status === 'fulfilled' && response.value.status === 200) { + FamilyIds[individualIds[index]] = response.value.data.id; + } + }); + } + } + } catch (e: any) { + logger.error(e); + CMHNodeQueryError = e; + } + + return { + data: transformCMHQueryResponse( + (CMHVariantQueryResponse?.data as G4RDVariantQueryResult) || [], + (CMHPatientQueryResponse?.data as G4RDPatientQueryResult) || [], + FamilyIds + ), + error: transformCMHNodeErrorResponse(CMHNodeQueryError), + source: SOURCE_NAME, + }; +}; + +/** + * @param args VariantQueryInput + * @returns Promise + */ +const getCMHNodeQuery = timeitAsync('getCMHNodeQuery')(_getCMHNodeQuery); + +const getAuthHeader = async () => { + const { + CMH_AZURE_CLIENT_ID: client_id, + CMH_AZURE_CLIENT_SECRET: client_secret, + CMH_TOKEN_URL, + CMH_RESOURCE: resource, + CMH_SCOPE: scope, + CMH_GRANT_TYPE: grant_type, + } = process.env; + const cachedToken = getFromCache(AZURE_BEARER_CACHE_KEY); + if (cachedToken) { + return `Bearer ${cachedToken}`; + } + + const params = new URLSearchParams({ + client_id, + client_secret, + resource, + scope, + grant_type, + } as Record); + + const tokenResponse = await axios.post<{ access_token: string }>(CMH_TOKEN_URL!, params, { + headers: { 'Content-Type': 'application/x-www-form-urlencoded', Accept: '*/*' }, + }); + const token = tokenResponse.data.access_token; + const decoded = jwtDecode<{ iat: number; exp: number }>(token); + const ttl = decoded.exp - Date.now() / 1000; + putInCache(AZURE_BEARER_CACHE_KEY, token, ttl); + return `Bearer ${token}`; +}; + +export const transformCMHNodeErrorResponse: ErrorTransformer = error => { + if (!error) { + return undefined; + } else { + return { + id: uuidv4(), + code: error.response?.status || 500, + message: + error.response?.status === 404 + ? 'No variants found matching your query.' + : error.response?.statusText, + }; + } +}; + +const isObserved = (feature: Feature | NonStandardFeature) => + feature.observed === 'yes' ? true : feature.observed === 'no' ? false : undefined; + +export const transformCMHQueryResponse: ResultTransformer = timeit( + 'transformCMHQueryResponse' +)( + ( + variantResponse: G4RDVariantQueryResult, + patientResponse: G4RDPatientQueryResult[], + familyIds: Record + ) => { + const individualIdsMap = Object.fromEntries(patientResponse.map(p => [p.id, p])); + + return (variantResponse.results || []).map(r => { + /* eslint-disable @typescript-eslint/no-unused-vars */ + r.variant.assemblyId = resolveAssembly(r.variant.assemblyId); + const { individual, contactInfo } = r; + + const patient = individual.individualId ? individualIdsMap[individual.individualId] : null; + + let info: IndividualInfoFields = {}; + let ethnicity: string = ''; + let disorders: Disorder[] = []; + let phenotypicFeatures: PhenotypicFeaturesFields[] = individual.phenotypicFeatures || []; + + if (patient) { + const candidateGene = (patient.genes ?? []).map(g => g.gene).join('\n'); + const classifications = (patient.genes ?? []).map(g => g.status).join('\n'); + const diagnosis = patient.clinicalStatus; + const solved = patient.solved ? patient.solved.status : ''; + const clinicalStatus = patient.clinicalStatus; + disorders = patient.disorders.filter(({ label }) => label !== 'affected') as Disorder[]; + ethnicity = Object.values(patient.ethnicity) + .flat() + .map(p => p.trim()) + .join(', '); + info = { + solved, + candidateGene, + diagnosis, + classifications, + clinicalStatus, + disorders, + }; + // variant response contains all phenotypic features listed, + // even if some of them are explicitly _not_ observed by clinician and recorded as such + if (individual.phenotypicFeatures !== null && individual.phenotypicFeatures !== undefined) { + const features = [...(patient.features ?? []), ...(patient.nonstandard_features ?? [])]; + const detailedFeatures = individual.phenotypicFeatures; + // build list of features the safe way + const detailedFeatureMap = Object.fromEntries( + detailedFeatures.map(feat => [feat.phenotypeId, feat]) + ); + const finalFeatures: PhenotypicFeaturesFields[] = features.map(feat => { + if (feat.id === undefined) { + return { + ageOfOnset: null, + dateOfOnset: null, + levelSeverity: null, + onsetType: null, + phenotypeId: feat.id, + phenotypeLabel: feat.label, + observed: isObserved(feat), + }; + } + return { + ...detailedFeatureMap[feat.id], + observed: isObserved(feat), + }; + }); + phenotypicFeatures = finalFeatures; + } + } + + const variant: VariantResponseFields = { + alt: r.variant.alt, + assemblyId: r.variant.assemblyId, + callsets: r.variant.callsets, + end: r.variant.end, + ref: r.variant.ref, + start: r.variant.start, + chromosome: r.variant.chromosome, + }; + + let familyId: string = ''; + if (individual.individualId) familyId = familyIds[individual.individualId]; + + const individualResponseFields: IndividualResponseFields = { + ...individual, + ethnicity, + info, + familyId, + phenotypicFeatures, + }; + return { individual: individualResponseFields, variant, contactInfo, source: SOURCE_NAME }; + }); + } +); + +export default getCMHNodeQuery; diff --git a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts index a4e8b511..f306d496 100644 --- a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts +++ b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts @@ -46,7 +46,7 @@ const _getG4rdNodeQuery = async ({ Authorization = await getAuthHeader(); } catch (e: any) { logger.error(e); - logger.error(e?.resoponse?.data); + logger.error(JSON.stringify(e?.response?.data)); return { data: [], error: { code: 403, message: 'ERROR FETCHING OAUTH TOKEN', id: uuidv4() }, @@ -165,7 +165,7 @@ const getAuthHeader = async () => { } const params = new URLSearchParams({ - client_id: client_id, + client_id, grant_type, password, realm, diff --git a/server/src/resolvers/getVariantsResolver/adapters/remoteTestNodeAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/remoteTestNodeAdapter.ts index 8bc8c205..c88b6d3e 100644 --- a/server/src/resolvers/getVariantsResolver/adapters/remoteTestNodeAdapter.ts +++ b/server/src/resolvers/getVariantsResolver/adapters/remoteTestNodeAdapter.ts @@ -140,7 +140,7 @@ export const transformRemoteTestNodeErrorResponse: ErrorTransformer< return { id: uuidv4(), code: error.response?.status || 500, - message: error.response?.data, + message: JSON.stringify(error.response?.data), }; } }; diff --git a/server/src/resolvers/getVariantsResolver/getVariantsResolver.ts b/server/src/resolvers/getVariantsResolver/getVariantsResolver.ts index b0072629..21d5a904 100644 --- a/server/src/resolvers/getVariantsResolver/getVariantsResolver.ts +++ b/server/src/resolvers/getVariantsResolver/getVariantsResolver.ts @@ -18,6 +18,7 @@ import liftover from './utils/liftOver'; import { QueryResponseError } from './utils/queryResponseError'; import getG4rdNodeQuery from './adapters/g4rdAdapter'; import { timeitAsync } from '../../utils/timeit'; +import getCMHNodeQuery from './adapters/cmhAdapter'; const getVariants = async (parent: any, args: QueryInput): Promise => await resolveVariantQuery(args); @@ -144,6 +145,8 @@ const buildSourceQuery = timeitAsync('buildSourceQuery')( return getRemoteTestNodeQuery(args); case 'g4rd': return getG4rdNodeQuery(args); + case 'cmh': + return getCMHNodeQuery(args); default: throw new Error(`source ${source} not found!`); } From f612c7fbc4f58da620604393e525ab25426d0246 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 24 May 2023 16:17:35 -0400 Subject: [PATCH 09/57] Bump keycloak-connect from 17.0.0 to 21.0.1 in /server (#336) Bumps [keycloak-connect](https://github.com/keycloak/keycloak-nodejs-connect) from 17.0.0 to 21.0.1. - [Release notes](https://github.com/keycloak/keycloak-nodejs-connect/releases) - [Commits](https://github.com/keycloak/keycloak-nodejs-connect/compare/17.0.0...21.0.1) --- updated-dependencies: - dependency-name: keycloak-connect dependency-type: direct:production ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- server/package.json | 2 +- server/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/server/package.json b/server/package.json index 6874108a..b2da52a6 100644 --- a/server/package.json +++ b/server/package.json @@ -25,7 +25,7 @@ "generic-filehandle": "^2.2.2", "graphql": "^16.3.0", "jwt-decode": "^3.1.2", - "keycloak-connect": "17.0.0", + "keycloak-connect": "21.0.1", "memorystore": "^1.6.7", "mongoose": "^6.4.6", "node-cache": "^5.1.2", diff --git a/server/yarn.lock b/server/yarn.lock index 8a189d64..cfdc2e0d 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -4043,10 +4043,10 @@ kareem@2.4.1: resolved "https://registry.yarnpkg.com/kareem/-/kareem-2.4.1.tgz#7d81ec518204a48c1cb16554af126806c3cd82b0" integrity sha512-aJ9opVoXroQUPfovYP5kaj2lM7Jn02Gw13bL0lg9v0V7SaUc0qavPs0Eue7d2DcC3NjqI6QAUElXNsuZSeM+EA== -keycloak-connect@17.0.0: - version "17.0.0" - resolved "https://registry.yarnpkg.com/keycloak-connect/-/keycloak-connect-17.0.0.tgz#9ac6a619205490cf919a1cbfff4a355f361e010a" - integrity sha512-3dlqTUSkiTpmUiGcAFUZbT8k/5sXz94Jj+wIJBrZuqagykth8UVljx1RPcfto+2uextdLiQs2Ujk3Jn4BPrsJA== +keycloak-connect@21.0.1: + version "21.0.1" + resolved "https://registry.yarnpkg.com/keycloak-connect/-/keycloak-connect-21.0.1.tgz#22ba0bedd131a8ca8001a8501b87fbc502c95c51" + integrity sha512-jCLX1sYQpMb2TYK4H1gd2XOwMLXyzMd+ict+Z7295JtFs7GZ0kfBOT7St/RY/3xjen/zd2bHBlnuUBJVZZrciQ== dependencies: jwk-to-pem "^2.0.0" optionalDependencies: From f1f9a3f24756c0c5e258193b380dfb930b416143 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 24 May 2023 16:31:04 -0400 Subject: [PATCH 10/57] Bump undici from 5.9.1 to 5.19.1 in /server (#333) Bumps [undici](https://github.com/nodejs/undici) from 5.9.1 to 5.19.1. - [Release notes](https://github.com/nodejs/undici/releases) - [Commits](https://github.com/nodejs/undici/compare/v5.9.1...v5.19.1) --- updated-dependencies: - dependency-name: undici dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- server/yarn.lock | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/server/yarn.lock b/server/yarn.lock index cfdc2e0d..fda8003b 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -1855,6 +1855,13 @@ buffer@^5.6.0, buffer@^5.7.0: base64-js "^1.3.1" ieee754 "^1.1.13" +busboy@^1.6.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/busboy/-/busboy-1.6.0.tgz#966ea36a9502e43cdb9146962523b92f531f6893" + integrity sha512-8SFQbg/0hQ9xy3UNTB0YEnsNBbWfhf7RtnzpL7TkBiTBRfrQ9Fxcnz7VJsleJpyp6rVLvXiuORqjlHi5q+PYuA== + dependencies: + streamsearch "^1.1.0" + bytes@3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/bytes/-/bytes-3.1.2.tgz#8b0beeb98605adf1b128fa4386403c009e0221a5" @@ -5108,6 +5115,11 @@ statuses@2.0.1: resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.5.0.tgz#161c7dac177659fd9811f43771fa99381478628c" integrity sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow= +streamsearch@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/streamsearch/-/streamsearch-1.1.0.tgz#404dd1e2247ca94af554e841a8ef0eaa238da764" + integrity sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg== + string-env-interpolation@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/string-env-interpolation/-/string-env-interpolation-1.0.1.tgz#ad4397ae4ac53fe6c91d1402ad6f6a52862c7152" @@ -5499,9 +5511,11 @@ unbox-primitive@^1.0.1: which-boxed-primitive "^1.0.2" undici@^5.0.0: - version "5.9.1" - resolved "https://registry.yarnpkg.com/undici/-/undici-5.9.1.tgz#fc9fd85dd488f965f153314a63d9426a11f3360b" - integrity sha512-6fB3a+SNnWEm4CJbgo0/CWR8RGcOCQP68SF4X0mxtYTq2VNN8T88NYrWVBAeSX+zb7bny2dx2iYhP3XHi00omg== + version "5.19.1" + resolved "https://registry.yarnpkg.com/undici/-/undici-5.19.1.tgz#92b1fd3ab2c089b5a6bd3e579dcda8f1934ebf6d" + integrity sha512-YiZ61LPIgY73E7syxCDxxa3LV2yl3sN8spnIuTct60boiiRaE1J8mNWHO8Im2Zi/sFrPusjLlmRPrsyraSqX6A== + dependencies: + busboy "^1.6.0" universalify@^0.1.2: version "0.1.2" From 4e75725990bf62ca3126a87638bf662699647a8a Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Wed, 24 May 2023 16:56:21 -0400 Subject: [PATCH 11/57] Rearrange columns, add tooltips (#342) * Add source to duplicate variant check * Move some columns to Case Details * Add tooltips for all the columns --- react/src/components/Table/Table.tsx | 111 ++++++++++++++++----------- react/src/constants/headers.ts | 42 +++++++++- react/src/utils/tableHelpers.ts | 3 +- 3 files changed, 106 insertions(+), 50 deletions(-) diff --git a/react/src/components/Table/Table.tsx b/react/src/components/Table/Table.tsx index 4702f8e6..d7419589 100644 --- a/react/src/components/Table/Table.tsx +++ b/react/src/components/Table/Table.tsx @@ -113,8 +113,8 @@ const Table: React.FC = ({ variantData }) => { } else throw new Error(`Group ${groupId} not found!`); }; - const columns = useMemo( - (): ColumnGroup[] => [ + const columns = useMemo((): ColumnGroup[] => { + const columnGroups: ColumnGroup[] = [ { Header: 'Variant', id: 'core', @@ -160,33 +160,33 @@ const Table: React.FC = ({ variantData }) => { accessor: 'ref', id: 'ref', Header: 'Ref', - width: getColumnWidth('Ref'), + width: getColumnWidth('Ref', true), }, { accessor: 'alt', id: 'alt', Header: 'Alt', - width: getColumnWidth('Alt'), - }, - { - accessor: 'assemblyId', - id: 'originalAssembly', - Header: 'Original Assembly', - width: getColumnWidth('Original Assembly'), + width: getColumnWidth('Alt', true), }, + // { + // accessor: 'assemblyId', + // id: 'originalAssembly', + // Header: 'Original Assembly', + // width: getColumnWidth('Original Assembly'), + // }, { accessor: 'assemblyIdCurrent', id: 'currentAssembly', Header: 'Current Assembly', - width: getColumnWidth('Current Assembly'), - }, - { - accessor: 'source', - filter: 'singleSelect', - id: 'source', - Header: 'Source', - width: getColumnWidth('Source', true), + width: getColumnWidth('Current Assembly', true), }, + // { + // accessor: 'source', + // filter: 'singleSelect', + // id: 'source', + // Header: 'Source', + // width: getColumnWidth('Source', true), + // }, ], }, { @@ -213,14 +213,14 @@ const Table: React.FC = ({ variantData }) => { accessor: 'homozygousCount', id: 'homozygousCount', Header: 'Homo Count', - width: getColumnWidth('Homo Count'), + width: getColumnWidth('Homo Count', true), filter: 'between', }, { accessor: 'heterozygousCount', id: 'heterozygousCount', Header: 'Het Count', - width: getColumnWidth('Het Count'), + width: getColumnWidth('Het Count', true), filter: 'between', }, // { @@ -230,18 +230,23 @@ const Table: React.FC = ({ variantData }) => { // width: getColumnWidth('Male Count'), // filter: 'between', // }, - { accessor: 'cdna', id: 'cdna', Header: 'cdna', width: getColumnWidth('cdna') }, + { + accessor: 'cdna', + id: 'cdna', + Header: 'cdna', + width: getColumnWidth('cdna', true), + }, { id: 'aaChange', accessor: 'aaChange', Header: 'aaChange', - width: getColumnWidth('aaChange'), + width: getColumnWidth('aaChange', true), }, { accessor: 'consequence', id: 'consequence', Header: 'consequence', - width: getColumnWidth('consequence'), + width: getColumnWidth('consequence', true), filter: 'multiSelect', }, { @@ -262,28 +267,28 @@ const Table: React.FC = ({ variantData }) => { accessor: 'gnomadHom', id: 'gnomadHom', Header: 'gnomadHom', - width: getColumnWidth('gnomadHom'), + width: getColumnWidth('gnomadHom', true), filter: 'between', }, { accessor: 'phred', id: 'phred', Header: 'CADD score', - width: getColumnWidth('CADD score'), + width: getColumnWidth('CADD score', true), filter: 'between', }, { accessor: 'spliceAIScore', id: 'spliceAIScore', Header: 'SpliceAI score', - width: getColumnWidth('SpliceAI score'), + width: getColumnWidth('SpliceAI score', true), filter: 'between', }, { accessor: 'spliceAIType', id: 'spliceAIType', Header: 'SpliceAI type', - width: getColumnWidth('SpliceAI type'), + width: getColumnWidth('SpliceAI type', true), filter: 'multiSelect', }, ], @@ -294,6 +299,19 @@ const Table: React.FC = ({ variantData }) => { disableSortBy: true, disableFilters: true, columns: [ + { + accessor: 'assemblyId', + id: 'originalAssembly', + Header: 'Original Assembly', + width: getColumnWidth('Original Assembly', true), + }, + { + accessor: 'source', + filter: 'singleSelect', + id: 'source', + Header: 'Source', + width: getColumnWidth('Source', true), + }, { id: 'emptyCaseDetails', type: 'empty', @@ -312,29 +330,30 @@ const Table: React.FC = ({ variantData }) => { filter: 'multiSelect', id: 'zygosity', Header: 'Zygosity', - width: getColumnWidth('Zygosity'), + width: getColumnWidth('Zygosity', true), }, { accessor: 'burdenCount', id: 'burdenCount', Header: 'Burden Count', - width: getColumnWidth('Burden Count'), + width: getColumnWidth('Burden Count', true), filter: 'between', }, { accessor: 'ad', id: 'ad', Header: 'AD', - width: getColumnWidth('AD'), - filter: 'between', - }, - { - accessor: 'dp', - id: 'dp', - Header: 'DP', - width: getColumnWidth('DP'), + width: getColumnWidth('AD', true), filter: 'between', }, + // { + // accessor: 'dp', + // id: 'dp', + // Header: 'DP', + // width: getColumnWidth('DP', true), + // filter: 'between', + // }, // TODO: change to hidden by default + // (requires 2-layer column hiding; this section is hidden by default) { accessor: 'gq', id: 'gq', @@ -346,13 +365,13 @@ const Table: React.FC = ({ variantData }) => { accessor: 'individualId', id: 'individualId', Header: 'Individual ID', - width: getColumnWidth('Individual ID'), + width: getColumnWidth('Individual ID', true), }, { accessor: 'familyId', id: 'familyId', Header: 'Family ID', - width: getColumnWidth('Family ID'), + width: getColumnWidth('Family ID', true), }, { accessor: 'sex', @@ -388,7 +407,7 @@ const Table: React.FC = ({ variantData }) => { filter: 'multiSelect', id: 'affectedStatus', Header: 'Affected Status', - width: getColumnWidth('Affected Status'), + width: getColumnWidth('Affected Status', true), }, { accessor: state => { @@ -405,7 +424,7 @@ const Table: React.FC = ({ variantData }) => { }, id: 'flaggedGenes', Header: 'Flagged Gene(s)', - width: getColumnWidth('Flagged Gene(s)'), + width: getColumnWidth('Flagged Gene(s)', true), Cell: ({ cell: { value }, row: { isExpanded, toggleRowExpanded }, @@ -430,7 +449,7 @@ const Table: React.FC = ({ variantData }) => { : '', id: 'phenotypicFeaturesPresent', Header: 'Present Phenotypes', - width: 150, + width: 190, Cell: ({ row: { isExpanded, @@ -457,7 +476,7 @@ const Table: React.FC = ({ variantData }) => { : '', id: 'phenotypicFeaturesAbsent', Header: 'Absent Phenotypes', - width: 150, + width: 190, Cell: ({ row: { isExpanded, @@ -504,9 +523,9 @@ const Table: React.FC = ({ variantData }) => { }, ], }, - ], - [getColumnWidth, tableData] - ); + ]; + return columnGroups; + }, [getColumnWidth, tableData]); const defaultColumn = useMemo( () => ({ diff --git a/react/src/constants/headers.ts b/react/src/constants/headers.ts index 0bd06597..fd370fd9 100644 --- a/react/src/constants/headers.ts +++ b/react/src/constants/headers.ts @@ -1,9 +1,10 @@ -/* - * Describes the data provided in each column +/** + * Describes the data provided in each column. + * Keys are column ids defined in Table.tsx. */ const HEADERS: { [x: string]: string } = { - source: 'The institution where the data comes from', + source: 'The institution where the data comes from.', af: 'Allele frequency from gnomAD, defined as the greater value between the exome allele frequency and the genome allele frequency.', ac: 'Allele count from gnomAD. This is calculated as the sum of the genome and exome allele counts (for GRCh38 assemblies, this is only genome allele count).', ethnicity: @@ -16,6 +17,41 @@ const HEADERS: { [x: string]: string } = { contactInfo: 'Contact information for the record owner', maleCount: "Total number of male participants with this variant returned from all sources. This is NOT retrieved from gnomAD, only what's retrieved from the selected sources.", + ref: 'Reference allele. More than one nucleotide listed as the reference allele means there is a deletion at this position.', + alt: 'Alternative allele. More than one nucleotide listed as the alternative allele means there is a deletion at this position.', + currentAssembly: 'The assembly that variants were annotated with in the source database.', + originalAssembly: 'The assembly used to annotate variants in the OSMP query results.', + homozygousCount: + 'Number of individuals in the OSMP results who are homozygous for this variant.', + heterozygousCount: + 'Number of individuals in the OSMP results who are heterozygous for this variant.', + cdna: 'Coding DNA change according to the Ensembl transcript.', + aaChange: 'Amino acid change according to the Ensembl transcript.', + consequence: 'Calculated variant consequence according to the Ensembl Sequence Ontology.', + gnomadHom: + 'Number of individuals in gnomAD homozygous for this variant. Note that this is a sum of the homozygotes from the exome and genome data.', + phred: 'Scaled score for predicting the deleteriousness of single nucleotide variants, insertions, and deletions. A score of 20 or greater indicates a variant in the top 1% for likelihood of being deleterious.', + spliceAIScore: + 'SpliceAI probability of a variant being splice altering (scale of 0 to 1). Closer to 1 means a greater probability of a splicing change, recommended cutoff is normally 0.5.', + spliceAIType: + 'SpliceAI type of splicing change predicted for this variant. Can be a gain or a loss of a splice acceptor or splice donor. If the SpliceAI score is 0, this will be NA.', + zygosity: + 'Zygosity for the variant in this individual. Note that hemizygous variants in this column will appear as "homozygous".', + burdenCount: + 'Number of variants an individual has in this gene. Note that this is calculated AFTER variants have been returned by the search query, meaning that variants more common than the "Max Frequency" will NOT be included in the burden calculation.', + ad: 'Allele depth. This is the number of reads in which a variant is called for a given sample.', + dp: 'Total depth. If the sample is from singleton data, provides the total depth from just that sample. If the sample was annotated as part of a family, provides the sum of total depths across all samples in that family.', + qual: 'QUAL is the Phred-scaled probability that a variant exists given sequencing data. QUAL is annotated in the Quality field in the reports.', + individualId: 'Identifier for this individual in its source database.', + familyId: "Identifier for this individual's family in its source database.", + affectedStatus: + 'Flag for whether an individual is clinically affected or unaffected. Note that individuals are only listed as unaffected if "This patient is clinically normal" is checked off in Phenotips.', + flaggedGenes: + 'Gene(s) explicitly flagged for this individual record, along with their classification. Note that genes flagged as "solved" may be only a partial explanation for an individual\'s phenotype.', + phenotypicFeaturesPresent: + 'HPO phenotypes listed as present in this individual (click on text to expand field).', + phenotypicFeaturesAbsent: + 'HPO phenotypes explicitly listed as absent from this individual (click on text to expand field).', }; export default HEADERS; diff --git a/react/src/utils/tableHelpers.ts b/react/src/utils/tableHelpers.ts index 68b18581..e517c510 100644 --- a/react/src/utils/tableHelpers.ts +++ b/react/src/utils/tableHelpers.ts @@ -270,7 +270,8 @@ export const prepareData = ( t.end === arr.end && t.alt === arr.alt && t.ref === arr.ref && - t.individualId === arr.individualId + t.individualId === arr.individualId && + t.source === arr.source ) ); From a6cb45d3597f558936fd8cb6bc2befd30c8e8ce6 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Wed, 7 Jun 2023 14:20:15 -0400 Subject: [PATCH 12/57] Fix CMH assembly (#343) * Change CMH adapter to GRCh38 * Fix liftOver if no dataForAnnotation --- .../resolvers/getVariantsResolver/adapters/cmhAdapter.ts | 2 +- .../resolvers/getVariantsResolver/getVariantsResolver.ts | 9 +++++++-- .../src/resolvers/getVariantsResolver/utils/liftOver.ts | 4 +++- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts index da3deca3..3d8c4dc4 100644 --- a/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts +++ b/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts @@ -63,7 +63,7 @@ const _getCMHNodeQuery = async ({ const url = `${process.env.CMH_URL}/rest/variants/match`; /* eslint-disable @typescript-eslint/no-unused-vars */ const { position, ...gene } = geneInput; - variant.assemblyId = 'GRCh37'; + variant.assemblyId = 'GRCh38'; try { CMHVariantQueryResponse = await axios.post( url, diff --git a/server/src/resolvers/getVariantsResolver/getVariantsResolver.ts b/server/src/resolvers/getVariantsResolver/getVariantsResolver.ts index 21d5a904..c2e9e480 100644 --- a/server/src/resolvers/getVariantsResolver/getVariantsResolver.ts +++ b/server/src/resolvers/getVariantsResolver/getVariantsResolver.ts @@ -87,8 +87,13 @@ const resolveVariantQuery = timeitAsync('resolveVariantQuery')( // perform liftOver if needed if (dataForLiftover.length) { - const liftoverResults = await liftover(dataForAnnotation, dataForLiftover, assemblyId); - ({ unliftedVariants, dataForAnnotation, annotationPosition } = liftoverResults); + try { + const liftoverResults = await liftover(dataForAnnotation, dataForLiftover, assemblyId); + ({ unliftedVariants, dataForAnnotation, annotationPosition } = liftoverResults); + // annotationPosition == "" if there's no data for annotation, which is fine + } catch (err) { + logger.error(JSON.stringify(err)); + } } // Cadd annotations for data in user requested assemblyId diff --git a/server/src/resolvers/getVariantsResolver/utils/liftOver.ts b/server/src/resolvers/getVariantsResolver/utils/liftOver.ts index 4c17dd1c..891bbf91 100644 --- a/server/src/resolvers/getVariantsResolver/utils/liftOver.ts +++ b/server/src/resolvers/getVariantsResolver/utils/liftOver.ts @@ -83,8 +83,10 @@ const liftover = timeitAsync('liftover')( geneEnd = result.variant.end; } }); - const annotationPosition = `${dataForAnnotation[0].variant.chromosome}:${geneStart}-${geneEnd}`; + let annotationPosition = ''; + if (dataForAnnotation.length > 0) + annotationPosition = `${dataForAnnotation[0].variant.chromosome}:${geneStart}-${geneEnd}`; promises.rm(lifted); promises.rm(unlifted); promises.rm(bedfile); From 2e6a9c0d0c087d8ab209f16b8f36fcf422d834d6 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Fri, 18 Aug 2023 10:31:35 -0400 Subject: [PATCH 13/57] Perform LiftOver for CMH query results (GRCh38 -> h37) (#353) * Add CMHVariantIndelCoordinate type * More comments * Update mongo query to accomodate CMH format * Fix "chrchr" mapping in liftOver * Remove logger debugs * Fix gnomad query to exclude CMH if none found - Fix getCoordinates to not do "chrchr" * Remove ref[0] == alt[0] query check --- server/src/models/GnomadAnnotationModel.ts | 55 ++++++++++- server/src/models/utils/getCoordinates.ts | 8 +- .../getVariantsResolver/utils/liftOver.ts | 98 +++++++++++-------- server/src/types.ts | 11 +++ 4 files changed, 125 insertions(+), 47 deletions(-) diff --git a/server/src/models/GnomadAnnotationModel.ts b/server/src/models/GnomadAnnotationModel.ts index 42f45cc3..c8533711 100644 --- a/server/src/models/GnomadAnnotationModel.ts +++ b/server/src/models/GnomadAnnotationModel.ts @@ -1,6 +1,7 @@ import mongoose, { Model, model } from 'mongoose'; import logger from '../logger'; import { + CMHVariantIndelCoordinate, GnomadBaseAnnotation, GnomadGenomeAnnotation, GnomadGRCh37ExomeAnnotation, @@ -90,13 +91,61 @@ const getAnnotations = async ( if (!coordinates.length) return []; - return await model.aggregate([ - { $match: { pos: { $gte: start, $lte: end } } }, - { $match: { $or: coordinates } }, + // Check and modify coordinates to fit gnomAD model + // CMH uses "-" in ref/alt fields for insertions/deletions respectively, gnomAD doesn't + const cmhInsertions: CMHVariantIndelCoordinate<'$alt'>[] = []; + const cmhDeletions: CMHVariantIndelCoordinate<'$ref'>[] = []; + const normalCoords: VariantCoordinate[] = []; + coordinates.forEach(coord => { + if (coord.alt === '-') { + // CMH deletion + cmhDeletions.push({ + $expr: { + $eq: [{ $substrCP: ['$ref', 1, { $strLenCP: '$ref' }] }, coord.ref], + }, + pos: coord.pos - 1, // cmh 'start' is +1 compared to gnomad + chrom: coord.chrom, + }); + } else if (coord.ref === '-') { + // CMH insertion + cmhInsertions.push({ + $expr: { + $eq: [{ $substrCP: ['$alt', 1, { $strLenCP: '$alt' }] }, coord.alt], + }, + pos: coord.pos, + chrom: coord.chrom, + }); + } else { + normalCoords.push(coord); + } + }); + + // don't worry about the types + const coordinateStage: { $match: { $or: any[] } } = { + $match: { + $or: [ + ...normalCoords, // normal coordinates + ], + }, + }; + + // Don't need to add match for CMH coordinates if there aren't any + if (cmhInsertions.length > 0 || cmhDeletions.length > 0) { + // we assume that ref[0] == alt[0] in gnomAD + coordinateStage.$match.$or = coordinateStage.$match.$or.concat([ + ...cmhInsertions, + ...cmhDeletions, + ]); + } + + const results = await model.aggregate([ + { $match: { pos: { $gte: Math.max(start - 1, 0), $lte: end } } }, + coordinateStage, { $project: Object.fromEntries([...omittedFields, '_id', 'assembly', 'type'].map(f => [f, 0])), }, ]); + return results; }; GnomadGRCh37AnnotationSchema.statics.getAnnotations = async function (ids: AnnotationInput) { diff --git a/server/src/models/utils/getCoordinates.ts b/server/src/models/utils/getCoordinates.ts index 2ae15bdf..05b95ac2 100644 --- a/server/src/models/utils/getCoordinates.ts +++ b/server/src/models/utils/getCoordinates.ts @@ -1,11 +1,11 @@ import resolveAssembly from '../../resolvers/getVariantsResolver/utils/resolveAssembly'; import { VariantCoordinate, VariantQueryDataResult } from '../../types'; -const getCoordinates = (result: VariantQueryDataResult[]) => { +const getCoordinates = (results: VariantQueryDataResult[]) => { let start = +Infinity; let end = -Infinity; const coordinates: VariantCoordinate[] = []; - const variants = result.flat().map(d => d.variant); + const variants = results.flat().map(d => d.variant); variants.forEach(variant => { const resolvedAssemblyId = resolveAssembly(variant.assemblyIdCurrent ?? 'GRCh37'); @@ -17,6 +17,10 @@ const getCoordinates = (result: VariantQueryDataResult[]) => { end = variant.end; } + if (variant.chromosome.startsWith('chr')) { + variant.chromosome = variant.chromosome.substring(3); + } + coordinates.push({ alt: variant.alt, chrom: `${resolvedAssemblyId === 'GRCh38' ? 'chr' : ''}${variant.chromosome}`, diff --git a/server/src/resolvers/getVariantsResolver/utils/liftOver.ts b/server/src/resolvers/getVariantsResolver/utils/liftOver.ts index 891bbf91..eb722948 100644 --- a/server/src/resolvers/getVariantsResolver/utils/liftOver.ts +++ b/server/src/resolvers/getVariantsResolver/utils/liftOver.ts @@ -33,7 +33,15 @@ const liftover = timeitAsync('liftover')( // Convert variants from JSON format to BED format. // Note that position format is 1-based and BED format is half-open 0-based: https://genome.ucsc.edu/FAQ/FAQformat.html#format1 const bedstring = dataForLiftover - .map(v => `chr${v.variant.chromosome}\t${v.variant.start - 1}\t${v.variant.end}`) + .map( + v => + `${ + // if coming from GRCh38, probably starts with chr already + v.variant.chromosome.startsWith('chr') + ? v.variant.chromosome + : 'chr' + v.variant.chromosome + }\t${v.variant.start - 1}\t${v.variant.end}` + ) .join('\n'); const lifted = await createTmpFile(); const unlifted = await createTmpFile(); @@ -46,52 +54,58 @@ const liftover = timeitAsync('liftover')( } else { chain = '/home/node/hg19ToHg38.over.chain'; } - await exec(`liftOver ${bedfile} ${chain} ${lifted} ${unlifted}`); - const _liftedVars = await promises.readFile(lifted); - const _unliftedVars = await promises.readFile(unlifted); - const liftedVars = parseBedStart(_liftedVars.toString()); - const unliftedVars = parseBedStart(_unliftedVars.toString()); - const liftedVarsEnd = parseBedEnd(_liftedVars.toString()); + const liftOverCommand = `liftOver ${bedfile} ${chain} ${lifted} ${unlifted}`; + try { + await exec(liftOverCommand); + const _liftedVars = await promises.readFile(lifted); + const _unliftedVars = await promises.readFile(unlifted); + const liftedVars = parseBedStart(_liftedVars.toString()); + const unliftedVars = parseBedStart(_unliftedVars.toString()); + const liftedVarsEnd = parseBedEnd(_liftedVars.toString()); - const unliftedMap: { [key: string]: boolean } = unliftedVars.reduce( - (acc, curr) => ({ ...acc, [curr]: true }), - {} - ); - const unliftedVariants: VariantQueryDataResult[] = []; + const unliftedMap: { [key: string]: boolean } = unliftedVars.reduce( + (acc, curr) => ({ ...acc, [curr]: true }), + {} + ); + const unliftedVariants: VariantQueryDataResult[] = []; - // Merge lifted variants with dataForAnnotation. Filter unmapped variants. - dataForLiftover.forEach((v, i) => { - if (unliftedMap[(v.variant.start - 1).toString()]) { - v.variant.assemblyIdCurrent = v.variant.assemblyId; - unliftedVariants.push(v); - } else { - v.variant.start = Number(liftedVars[i]) + 1; // Convert from BED format to position format. - v.variant.end = Number(liftedVarsEnd[i]); - v.variant.assemblyIdCurrent = assemblyIdInput; - dataForAnnotation.push(v); - } - }); + // Merge lifted variants with dataForAnnotation. Filter unmapped variants. + dataForLiftover.forEach((v, i) => { + if (unliftedMap[(v.variant.start - 1).toString()]) { + v.variant.assemblyIdCurrent = v.variant.assemblyId; + unliftedVariants.push(v); + } else { + v.variant.start = Number(liftedVars[i]) + 1; // Convert from BED format to position format. + v.variant.end = Number(liftedVarsEnd[i]); + v.variant.assemblyIdCurrent = assemblyIdInput; + dataForAnnotation.push(v); + } + }); - // Compute the annotation position for the variants that are in user's requested assembly. - let geneStart = Infinity; - let geneEnd = 0; - dataForAnnotation.forEach(result => { - if (result.variant.start < geneStart) { - geneStart = result.variant.start; - } - if (result.variant.end > geneEnd) { - geneEnd = result.variant.end; - } - }); + // Compute the annotation position for the variants that are in user's requested assembly. + let geneStart = Infinity; + let geneEnd = 0; + dataForAnnotation.forEach(result => { + if (result.variant.start < geneStart) { + geneStart = result.variant.start; + } + if (result.variant.end > geneEnd) { + geneEnd = result.variant.end; + } + }); - let annotationPosition = ''; - if (dataForAnnotation.length > 0) - annotationPosition = `${dataForAnnotation[0].variant.chromosome}:${geneStart}-${geneEnd}`; - promises.rm(lifted); - promises.rm(unlifted); - promises.rm(bedfile); + let annotationPosition = ''; + if (dataForAnnotation.length > 0) + annotationPosition = `${dataForAnnotation[0].variant.chromosome}:${geneStart}-${geneEnd}`; + promises.rm(lifted); + promises.rm(unlifted); + promises.rm(bedfile); - return { dataForAnnotation, unliftedVariants, annotationPosition }; + return { dataForAnnotation, unliftedVariants, annotationPosition }; + } catch (e) { + console.error(e); + return { dataForAnnotation, unliftedVariants: [], annotationPosition: '' }; + } } ); diff --git a/server/src/types.ts b/server/src/types.ts index b6288d36..f2a6ab50 100644 --- a/server/src/types.ts +++ b/server/src/types.ts @@ -231,6 +231,17 @@ export interface VariantCoordinate { pos: number; } +// Very specific type so that it can be put into a mongo.aggregate under "$or:" +// CMH indels use "-" unlike G4RD, so we compare $ref[1:] or $alt[1:] to ref or alt in CMH respectively +// '$ref' for deletions, '$alt' for insertions (ie. which one has more nucleotides) +export interface CMHVariantIndelCoordinate { + $expr: { + $eq: [{ $substrCP: [T, 1, { $strLenCP: T }] }, string]; + }; + pos: number; + chrom: string; +} + export interface CaddAnnotation extends VariantCoordinate { aaAlt: string; aaPos: string; From 801aba81b50b8c0dd072e2fcee86a271a1ee1ecc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Aug 2023 11:39:09 -0400 Subject: [PATCH 14/57] Bump word-wrap from 1.2.3 to 1.2.4 in /server (#350) Bumps [word-wrap](https://github.com/jonschlinkert/word-wrap) from 1.2.3 to 1.2.4. - [Release notes](https://github.com/jonschlinkert/word-wrap/releases) - [Commits](https://github.com/jonschlinkert/word-wrap/compare/1.2.3...1.2.4) --- updated-dependencies: - dependency-name: word-wrap dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- server/yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/server/yarn.lock b/server/yarn.lock index fda8003b..85fa068d 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -5717,9 +5717,9 @@ winston@^3.3.3: winston-transport "^4.5.0" word-wrap@^1.2.3, word-wrap@~1.2.3: - version "1.2.3" - resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" - integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ== + version "1.2.4" + resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.4.tgz#cb4b50ec9aca570abd1f52f33cd45b6c61739a9f" + integrity sha512-2V81OA4ugVo5pRo46hAoD2ivUJx8jXmWXfUkY4KFNw0hEptvN0QfH3K4nHiwzGeKl5rFKedV48QVoqYavy4YpA== wrap-ansi@^7.0.0: version "7.0.0" From 0600cb41bd1bc608cb013d30c137b51487b7aa5a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Aug 2023 11:39:36 -0400 Subject: [PATCH 15/57] Bump word-wrap from 1.2.3 to 1.2.4 in /test-node (#351) Bumps [word-wrap](https://github.com/jonschlinkert/word-wrap) from 1.2.3 to 1.2.4. - [Release notes](https://github.com/jonschlinkert/word-wrap/releases) - [Commits](https://github.com/jonschlinkert/word-wrap/compare/1.2.3...1.2.4) --- updated-dependencies: - dependency-name: word-wrap dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- test-node/yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test-node/yarn.lock b/test-node/yarn.lock index 34549f7c..fdfef41b 100644 --- a/test-node/yarn.lock +++ b/test-node/yarn.lock @@ -2295,9 +2295,9 @@ which@^2.0.1: isexe "^2.0.0" word-wrap@^1.2.3: - version "1.2.3" - resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" - integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ== + version "1.2.4" + resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.4.tgz#cb4b50ec9aca570abd1f52f33cd45b6c61739a9f" + integrity sha512-2V81OA4ugVo5pRo46hAoD2ivUJx8jXmWXfUkY4KFNw0hEptvN0QfH3K4nHiwzGeKl5rFKedV48QVoqYavy4YpA== wrappy@1: version "1.0.2" From 510875dc3f9f9ab98b740e68a577bc388850f8dd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Aug 2023 11:39:49 -0400 Subject: [PATCH 16/57] Bump word-wrap from 1.2.3 to 1.2.4 in /react (#352) Bumps [word-wrap](https://github.com/jonschlinkert/word-wrap) from 1.2.3 to 1.2.4. - [Release notes](https://github.com/jonschlinkert/word-wrap/releases) - [Commits](https://github.com/jonschlinkert/word-wrap/compare/1.2.3...1.2.4) --- updated-dependencies: - dependency-name: word-wrap dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- react/yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/react/yarn.lock b/react/yarn.lock index e98fd416..e6efca3d 100644 --- a/react/yarn.lock +++ b/react/yarn.lock @@ -14585,9 +14585,9 @@ widest-line@^3.1.0: string-width "^4.0.0" word-wrap@^1.2.3, word-wrap@~1.2.3: - version "1.2.3" - resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" - integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ== + version "1.2.4" + resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.4.tgz#cb4b50ec9aca570abd1f52f33cd45b6c61739a9f" + integrity sha512-2V81OA4ugVo5pRo46hAoD2ivUJx8jXmWXfUkY4KFNw0hEptvN0QfH3K4nHiwzGeKl5rFKedV48QVoqYavy4YpA== wordwrap@^1.0.0: version "1.0.0" From 156c5410ac103fa41a0a4dda829a093b8e879439 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Aug 2023 12:11:47 -0400 Subject: [PATCH 17/57] Bump semver from 5.7.1 to 5.7.2 in /test-node (#348) Bumps [semver](https://github.com/npm/node-semver) from 5.7.1 to 5.7.2. - [Release notes](https://github.com/npm/node-semver/releases) - [Changelog](https://github.com/npm/node-semver/blob/v5.7.2/CHANGELOG.md) - [Commits](https://github.com/npm/node-semver/compare/v5.7.1...v5.7.2) --- updated-dependencies: - dependency-name: semver dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- test-node/yarn.lock | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/test-node/yarn.lock b/test-node/yarn.lock index fdfef41b..d100faef 100644 --- a/test-node/yarn.lock +++ b/test-node/yarn.lock @@ -1937,19 +1937,19 @@ safe-buffer@5.2.1, safe-buffer@^5.0.1: integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== semver@^5.6.0: - version "5.7.1" - resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" - integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== + version "5.7.2" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8" + integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g== semver@^6.1.0: - version "6.3.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" - integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== + version "6.3.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" + integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== semver@^7.2.1, semver@^7.3.5: - version "7.3.7" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.7.tgz#12c5b649afdbf9049707796e22a4028814ce523f" - integrity sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g== + version "7.5.4" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" + integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== dependencies: lru-cache "^6.0.0" From e796a1e5d6117824ecb43b2b7c5c8d1b440cd21b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Aug 2023 13:40:19 -0400 Subject: [PATCH 18/57] Bump semver from 6.3.0 to 6.3.1 in /server (#347) Bumps [semver](https://github.com/npm/node-semver) from 6.3.0 to 6.3.1. - [Release notes](https://github.com/npm/node-semver/releases) - [Changelog](https://github.com/npm/node-semver/blob/v6.3.1/CHANGELOG.md) - [Commits](https://github.com/npm/node-semver/compare/v6.3.0...v6.3.1) --- updated-dependencies: - dependency-name: semver dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- server/yarn.lock | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/server/yarn.lock b/server/yarn.lock index 85fa068d..54ccd728 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -4939,16 +4939,16 @@ saxes@^5.0.1: xmlchars "^2.2.0" semver@7.x, semver@^7.3.2, semver@^7.3.5: - version "7.3.7" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.7.tgz#12c5b649afdbf9049707796e22a4028814ce523f" - integrity sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g== + version "7.5.4" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" + integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== dependencies: lru-cache "^6.0.0" semver@^6.0.0, semver@^6.1.0, semver@^6.3.0: - version "6.3.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" - integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== + version "6.3.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" + integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== send@0.17.2: version "0.17.2" From d20ffcd38af3e28fbacb16083a1d655a3e9c4394 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Aug 2023 13:40:34 -0400 Subject: [PATCH 19/57] Bump semver from 5.7.1 to 5.7.2 in /react (#346) Bumps [semver](https://github.com/npm/node-semver) from 5.7.1 to 5.7.2. - [Release notes](https://github.com/npm/node-semver/releases) - [Changelog](https://github.com/npm/node-semver/blob/v5.7.2/CHANGELOG.md) - [Commits](https://github.com/npm/node-semver/compare/v5.7.1...v5.7.2) --- updated-dependencies: - dependency-name: semver dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- react/yarn.lock | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/react/yarn.lock b/react/yarn.lock index e6efca3d..c2582ca8 100644 --- a/react/yarn.lock +++ b/react/yarn.lock @@ -12627,9 +12627,9 @@ selfsigned@^2.0.0: node-forge "^1" "semver@2 || 3 || 4 || 5", semver@^5.4.1, semver@^5.5.0, semver@^5.6.0: - version "5.7.1" - resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" - integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== + version "5.7.2" + resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8" + integrity sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g== semver@7.0.0: version "7.0.0" @@ -12637,14 +12637,14 @@ semver@7.0.0: integrity sha512-+GB6zVA9LWh6zovYQLALHwv5rb2PHGlJi3lfiqIHxR0uuwCgefcOJc59v9fv1w8GbStwxuuqqAjI9NMAOOgq1A== semver@^6.0.0, semver@^6.1.1, semver@^6.1.2, semver@^6.3.0: - version "6.3.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" - integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== + version "6.3.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" + integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== semver@^7.3.2, semver@^7.3.4, semver@^7.3.5: - version "7.3.5" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.5.tgz#0b621c879348d8998e4b0e4be94b3f12e6018ef7" - integrity sha512-PoeGJYh8HK4BTO/a9Tf6ZG3veo/A7ZVsYrSA6J8ny9nb3B1VrpkuN+z9OE5wfE5p6H4LchYZsegiQgbJD94ZFQ== + version "7.5.4" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" + integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== dependencies: lru-cache "^6.0.0" From 081873b90808c942010f28cf747ba224270d2ff3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Aug 2023 13:42:47 -0400 Subject: [PATCH 20/57] Bump tough-cookie from 4.0.0 to 4.1.3 in /react (#345) Bumps [tough-cookie](https://github.com/salesforce/tough-cookie) from 4.0.0 to 4.1.3. - [Release notes](https://github.com/salesforce/tough-cookie/releases) - [Changelog](https://github.com/salesforce/tough-cookie/blob/master/CHANGELOG.md) - [Commits](https://github.com/salesforce/tough-cookie/compare/v4.0.0...v4.1.3) --- updated-dependencies: - dependency-name: tough-cookie dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- react/yarn.lock | 30 ++++++++++++++++++++++-------- 1 file changed, 22 insertions(+), 8 deletions(-) diff --git a/react/yarn.lock b/react/yarn.lock index c2582ca8..827a78cd 100644 --- a/react/yarn.lock +++ b/react/yarn.lock @@ -11638,6 +11638,11 @@ querystring@^0.2.0: resolved "https://registry.yarnpkg.com/querystring/-/querystring-0.2.1.tgz#40d77615bb09d16902a85c3e38aa8b5ed761c2dd" integrity sha512-wkvS7mL/JMugcup3/rMitHmd9ecIGd2lhFhK9N3UUQ450h66d1r3Y9nvXzQAW1Lq+wyx61k/1pfKS5KuKiyEbg== +querystringify@^2.1.1: + version "2.2.0" + resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-2.2.0.tgz#3345941b4153cb9d082d8eee4cda2016a9aef7f6" + integrity sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ== + queue-microtask@^1.2.2: version "1.2.3" resolved "https://registry.yarnpkg.com/queue-microtask/-/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243" @@ -13674,13 +13679,14 @@ toidentifier@1.0.1: integrity sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA== tough-cookie@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-4.0.0.tgz#d822234eeca882f991f0f908824ad2622ddbece4" - integrity sha512-tHdtEpQCMrc1YLrMaqXXcj6AxhYi/xgit6mZu1+EDWUn+qhUf8wMQoFIy9NXuq23zAwtcB0t/MjACGR18pcRbg== + version "4.1.3" + resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-4.1.3.tgz#97b9adb0728b42280aa3d814b6b999b2ff0318bf" + integrity sha512-aX/y5pVRkfRnfmuX+OdbSdXvPe6ieKX/G2s7e98f4poJHnqH3281gDPm/metm6E/WRamfx7WC4HUqkWHfQHprw== dependencies: psl "^1.1.33" punycode "^2.1.1" - universalify "^0.1.2" + universalify "^0.2.0" + url-parse "^1.5.3" tr46@^1.0.1: version "1.0.1" @@ -14010,10 +14016,10 @@ unist-util-visit@2.0.3, unist-util-visit@^2.0.0: unist-util-is "^4.0.0" unist-util-visit-parents "^3.0.0" -universalify@^0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.2.tgz#b646f69be3942dabcecc9d6639c80dc105efaa66" - integrity sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg== +universalify@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.2.0.tgz#6451760566fa857534745ab1dde952d1b1761be0" + integrity sha512-CJ1QgKmNg3CwvAv/kOFmtnEN05f0D/cn9QntgNOQlQF9dgvVTHj3t+8JPdjqawCHk7V/KA+fbUqzZ9XWhcqPUg== universalify@^2.0.0: version "2.0.0" @@ -14064,6 +14070,14 @@ url-loader@^4.1.1: mime-types "^2.1.27" schema-utils "^3.0.0" +url-parse@^1.5.3: + version "1.5.10" + resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1" + integrity sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ== + dependencies: + querystringify "^2.1.1" + requires-port "^1.0.0" + url@^0.11.0: version "0.11.0" resolved "https://registry.yarnpkg.com/url/-/url-0.11.0.tgz#3838e97cfc60521eb73c525a8e55bfdd9e2e28f1" From dc5f417abce5d9d7e003ec91b6cbc170e641d683 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Aug 2023 13:42:58 -0400 Subject: [PATCH 21/57] Bump tough-cookie from 4.0.0 to 4.1.3 in /server (#344) Bumps [tough-cookie](https://github.com/salesforce/tough-cookie) from 4.0.0 to 4.1.3. - [Release notes](https://github.com/salesforce/tough-cookie/releases) - [Changelog](https://github.com/salesforce/tough-cookie/blob/master/CHANGELOG.md) - [Commits](https://github.com/salesforce/tough-cookie/compare/v4.0.0...v4.1.3) --- updated-dependencies: - dependency-name: tough-cookie dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- server/yarn.lock | 35 +++++++++++++++++++++++++++-------- 1 file changed, 27 insertions(+), 8 deletions(-) diff --git a/server/yarn.lock b/server/yarn.lock index 54ccd728..2eb4284f 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -4766,6 +4766,11 @@ qs@6.9.7: resolved "https://registry.yarnpkg.com/qs/-/qs-6.9.7.tgz#4610846871485e1e048f44ae3b94033f0e675afe" integrity sha512-IhMFgUmuNpyRfxA90umL7ByLlgRXu6tIfKPpF5TmcfRLlLCckfP/g3IQmju6jjpu+Hh8rA+2p6A27ZSPOOHdKw== +querystringify@^2.1.1: + version "2.2.0" + resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-2.2.0.tgz#3345941b4153cb9d082d8eee4cda2016a9aef7f6" + integrity sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ== + queue-microtask@^1.2.2: version "1.2.3" resolved "https://registry.yarnpkg.com/queue-microtask/-/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243" @@ -4842,6 +4847,11 @@ require-directory@^2.1.1: resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I= +requires-port@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" + integrity sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ== + resolve-cwd@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/resolve-cwd/-/resolve-cwd-3.0.0.tgz#0f0075f1bb2544766cf73ba6a6e2adfebcb13f2d" @@ -5323,13 +5333,14 @@ toidentifier@1.0.1: integrity sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA== tough-cookie@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-4.0.0.tgz#d822234eeca882f991f0f908824ad2622ddbece4" - integrity sha512-tHdtEpQCMrc1YLrMaqXXcj6AxhYi/xgit6mZu1+EDWUn+qhUf8wMQoFIy9NXuq23zAwtcB0t/MjACGR18pcRbg== + version "4.1.3" + resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-4.1.3.tgz#97b9adb0728b42280aa3d814b6b999b2ff0318bf" + integrity sha512-aX/y5pVRkfRnfmuX+OdbSdXvPe6ieKX/G2s7e98f4poJHnqH3281gDPm/metm6E/WRamfx7WC4HUqkWHfQHprw== dependencies: psl "^1.1.33" punycode "^2.1.1" - universalify "^0.1.2" + universalify "^0.2.0" + url-parse "^1.5.3" tr46@^2.1.0: version "2.1.0" @@ -5517,10 +5528,10 @@ undici@^5.0.0: dependencies: busboy "^1.6.0" -universalify@^0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.2.tgz#b646f69be3942dabcecc9d6639c80dc105efaa66" - integrity sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg== +universalify@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.2.0.tgz#6451760566fa857534745ab1dde952d1b1761be0" + integrity sha512-CJ1QgKmNg3CwvAv/kOFmtnEN05f0D/cn9QntgNOQlQF9dgvVTHj3t+8JPdjqawCHk7V/KA+fbUqzZ9XWhcqPUg== unixify@^1.0.0: version "1.0.0" @@ -5541,6 +5552,14 @@ uri-js@^4.2.2: dependencies: punycode "^2.1.0" +url-parse@^1.5.3: + version "1.5.10" + resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1" + integrity sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ== + dependencies: + querystringify "^2.1.1" + requires-port "^1.0.0" + util-deprecate@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" From e449998855a9b730048f24b25171ac7c5a587893 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Aug 2023 14:45:33 -0400 Subject: [PATCH 22/57] Bump mongoose from 6.4.6 to 6.11.3 in /server (#349) * Bump mongoose from 6.4.6 to 6.11.3 in /server Bumps [mongoose](https://github.com/Automattic/mongoose) from 6.4.6 to 6.11.3. - [Release notes](https://github.com/Automattic/mongoose/releases) - [Changelog](https://github.com/Automattic/mongoose/blob/master/CHANGELOG.md) - [Commits](https://github.com/Automattic/mongoose/compare/6.4.6...6.11.3) --- updated-dependencies: - dependency-name: mongoose dependency-type: direct:production ... Signed-off-by: dependabot[bot] * Fix deprecation warning for strictQuery setting --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Mackenzie Ian Frew --- server/package.json | 2 +- server/src/server.ts | 1 + server/yarn.lock | 895 ++++++++++++++++++++++++++++++++++++++++--- 3 files changed, 854 insertions(+), 44 deletions(-) diff --git a/server/package.json b/server/package.json index b2da52a6..3eab8525 100644 --- a/server/package.json +++ b/server/package.json @@ -27,7 +27,7 @@ "jwt-decode": "^3.1.2", "keycloak-connect": "21.0.1", "memorystore": "^1.6.7", - "mongoose": "^6.4.6", + "mongoose": "^6.11.3", "node-cache": "^5.1.2", "subscriptions-transport-ws": "^0.11.0", "winston": "^3.3.3" diff --git a/server/src/server.ts b/server/src/server.ts index 4bce4d07..edc4d678 100644 --- a/server/src/server.ts +++ b/server/src/server.ts @@ -21,6 +21,7 @@ const memoryStore = new MemoryStore({ checkPeriod: 86400000, // prune expired entries every 24h }); +mongoose.set('strictQuery', true); // default value for mongoose v6 mongoose .connect(process.env.MONGO_CONNECTION_STRING!) .then(() => { diff --git a/server/yarn.lock b/server/yarn.lock index 2eb4284f..3884962e 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -92,6 +92,458 @@ dependencies: xss "^1.0.8" +"@aws-crypto/crc32@3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@aws-crypto/crc32/-/crc32-3.0.0.tgz#07300eca214409c33e3ff769cd5697b57fdd38fa" + integrity sha512-IzSgsrxUcsrejQbPVilIKy16kAT52EwB6zSaI+M3xxIhKh5+aldEyvI+z6erM7TCLB2BJsFrtHjp6/4/sr+3dA== + dependencies: + "@aws-crypto/util" "^3.0.0" + "@aws-sdk/types" "^3.222.0" + tslib "^1.11.1" + +"@aws-crypto/ie11-detection@^3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@aws-crypto/ie11-detection/-/ie11-detection-3.0.0.tgz#640ae66b4ec3395cee6a8e94ebcd9f80c24cd688" + integrity sha512-341lBBkiY1DfDNKai/wXM3aujNBkXR7tq1URPQDL9wi3AUbI80NR74uF1TXHMm7po1AcnFk8iu2S2IeU/+/A+Q== + dependencies: + tslib "^1.11.1" + +"@aws-crypto/sha256-browser@3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@aws-crypto/sha256-browser/-/sha256-browser-3.0.0.tgz#05f160138ab893f1c6ba5be57cfd108f05827766" + integrity sha512-8VLmW2B+gjFbU5uMeqtQM6Nj0/F1bro80xQXCW6CQBWgosFWXTx77aeOF5CAIAmbOK64SdMBJdNr6J41yP5mvQ== + dependencies: + "@aws-crypto/ie11-detection" "^3.0.0" + "@aws-crypto/sha256-js" "^3.0.0" + "@aws-crypto/supports-web-crypto" "^3.0.0" + "@aws-crypto/util" "^3.0.0" + "@aws-sdk/types" "^3.222.0" + "@aws-sdk/util-locate-window" "^3.0.0" + "@aws-sdk/util-utf8-browser" "^3.0.0" + tslib "^1.11.1" + +"@aws-crypto/sha256-js@3.0.0", "@aws-crypto/sha256-js@^3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@aws-crypto/sha256-js/-/sha256-js-3.0.0.tgz#f06b84d550d25521e60d2a0e2a90139341e007c2" + integrity sha512-PnNN7os0+yd1XvXAy23CFOmTbMaDxgxXtTKHybrJ39Y8kGzBATgBFibWJKH6BhytLI/Zyszs87xCOBNyBig6vQ== + dependencies: + "@aws-crypto/util" "^3.0.0" + "@aws-sdk/types" "^3.222.0" + tslib "^1.11.1" + +"@aws-crypto/supports-web-crypto@^3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@aws-crypto/supports-web-crypto/-/supports-web-crypto-3.0.0.tgz#5d1bf825afa8072af2717c3e455f35cda0103ec2" + integrity sha512-06hBdMwUAb2WFTuGG73LSC0wfPu93xWwo5vL2et9eymgmu3Id5vFAHBbajVWiGhPO37qcsdCap/FqXvJGJWPIg== + dependencies: + tslib "^1.11.1" + +"@aws-crypto/util@^3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@aws-crypto/util/-/util-3.0.0.tgz#1c7ca90c29293f0883468ad48117937f0fe5bfb0" + integrity sha512-2OJlpeJpCR48CC8r+uKVChzs9Iungj9wkZrl8Z041DWEWvyIHILYKCPNzJghKsivj+S3mLo6BVc7mBNzdxA46w== + dependencies: + "@aws-sdk/types" "^3.222.0" + "@aws-sdk/util-utf8-browser" "^3.0.0" + tslib "^1.11.1" + +"@aws-sdk/client-cognito-identity@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/client-cognito-identity/-/client-cognito-identity-3.370.0.tgz#cfa6bc1a1b4b3631d0a62cd9861e56a397faba43" + integrity sha512-/dQFXT8y0WUD/731cdLjCrxNxH7Wtg2uZx7PggevTZs9Yr2fdGPSHehIYfvpCvi59yeG9T2Cl8sFnxXL1OEx4A== + dependencies: + "@aws-crypto/sha256-browser" "3.0.0" + "@aws-crypto/sha256-js" "3.0.0" + "@aws-sdk/client-sts" "3.370.0" + "@aws-sdk/credential-provider-node" "3.370.0" + "@aws-sdk/middleware-host-header" "3.370.0" + "@aws-sdk/middleware-logger" "3.370.0" + "@aws-sdk/middleware-recursion-detection" "3.370.0" + "@aws-sdk/middleware-signing" "3.370.0" + "@aws-sdk/middleware-user-agent" "3.370.0" + "@aws-sdk/types" "3.370.0" + "@aws-sdk/util-endpoints" "3.370.0" + "@aws-sdk/util-user-agent-browser" "3.370.0" + "@aws-sdk/util-user-agent-node" "3.370.0" + "@smithy/config-resolver" "^1.0.1" + "@smithy/fetch-http-handler" "^1.0.1" + "@smithy/hash-node" "^1.0.1" + "@smithy/invalid-dependency" "^1.0.1" + "@smithy/middleware-content-length" "^1.0.1" + "@smithy/middleware-endpoint" "^1.0.2" + "@smithy/middleware-retry" "^1.0.3" + "@smithy/middleware-serde" "^1.0.1" + "@smithy/middleware-stack" "^1.0.1" + "@smithy/node-config-provider" "^1.0.1" + "@smithy/node-http-handler" "^1.0.2" + "@smithy/protocol-http" "^1.1.0" + "@smithy/smithy-client" "^1.0.3" + "@smithy/types" "^1.1.0" + "@smithy/url-parser" "^1.0.1" + "@smithy/util-base64" "^1.0.1" + "@smithy/util-body-length-browser" "^1.0.1" + "@smithy/util-body-length-node" "^1.0.1" + "@smithy/util-defaults-mode-browser" "^1.0.1" + "@smithy/util-defaults-mode-node" "^1.0.1" + "@smithy/util-retry" "^1.0.3" + "@smithy/util-utf8" "^1.0.1" + tslib "^2.5.0" + +"@aws-sdk/client-sso-oidc@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/client-sso-oidc/-/client-sso-oidc-3.370.0.tgz#db03c04cb6a23888dc60016eb67505a41ede410b" + integrity sha512-jAYOO74lmVXylQylqkPrjLzxvUnMKw476JCUTvCO6Q8nv3LzCWd76Ihgv/m9Q4M2Tbqi1iP2roVK5bstsXzEjA== + dependencies: + "@aws-crypto/sha256-browser" "3.0.0" + "@aws-crypto/sha256-js" "3.0.0" + "@aws-sdk/middleware-host-header" "3.370.0" + "@aws-sdk/middleware-logger" "3.370.0" + "@aws-sdk/middleware-recursion-detection" "3.370.0" + "@aws-sdk/middleware-user-agent" "3.370.0" + "@aws-sdk/types" "3.370.0" + "@aws-sdk/util-endpoints" "3.370.0" + "@aws-sdk/util-user-agent-browser" "3.370.0" + "@aws-sdk/util-user-agent-node" "3.370.0" + "@smithy/config-resolver" "^1.0.1" + "@smithy/fetch-http-handler" "^1.0.1" + "@smithy/hash-node" "^1.0.1" + "@smithy/invalid-dependency" "^1.0.1" + "@smithy/middleware-content-length" "^1.0.1" + "@smithy/middleware-endpoint" "^1.0.2" + "@smithy/middleware-retry" "^1.0.3" + "@smithy/middleware-serde" "^1.0.1" + "@smithy/middleware-stack" "^1.0.1" + "@smithy/node-config-provider" "^1.0.1" + "@smithy/node-http-handler" "^1.0.2" + "@smithy/protocol-http" "^1.1.0" + "@smithy/smithy-client" "^1.0.3" + "@smithy/types" "^1.1.0" + "@smithy/url-parser" "^1.0.1" + "@smithy/util-base64" "^1.0.1" + "@smithy/util-body-length-browser" "^1.0.1" + "@smithy/util-body-length-node" "^1.0.1" + "@smithy/util-defaults-mode-browser" "^1.0.1" + "@smithy/util-defaults-mode-node" "^1.0.1" + "@smithy/util-retry" "^1.0.3" + "@smithy/util-utf8" "^1.0.1" + tslib "^2.5.0" + +"@aws-sdk/client-sso@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/client-sso/-/client-sso-3.370.0.tgz#68aea97ecb2e5e6c817dfd3a1dd9fa4e09ff6e1c" + integrity sha512-0Ty1iHuzNxMQtN7nahgkZr4Wcu1XvqGfrQniiGdKKif9jG/4elxsQPiydRuQpFqN6b+bg7wPP7crFP1uTxx2KQ== + dependencies: + "@aws-crypto/sha256-browser" "3.0.0" + "@aws-crypto/sha256-js" "3.0.0" + "@aws-sdk/middleware-host-header" "3.370.0" + "@aws-sdk/middleware-logger" "3.370.0" + "@aws-sdk/middleware-recursion-detection" "3.370.0" + "@aws-sdk/middleware-user-agent" "3.370.0" + "@aws-sdk/types" "3.370.0" + "@aws-sdk/util-endpoints" "3.370.0" + "@aws-sdk/util-user-agent-browser" "3.370.0" + "@aws-sdk/util-user-agent-node" "3.370.0" + "@smithy/config-resolver" "^1.0.1" + "@smithy/fetch-http-handler" "^1.0.1" + "@smithy/hash-node" "^1.0.1" + "@smithy/invalid-dependency" "^1.0.1" + "@smithy/middleware-content-length" "^1.0.1" + "@smithy/middleware-endpoint" "^1.0.2" + "@smithy/middleware-retry" "^1.0.3" + "@smithy/middleware-serde" "^1.0.1" + "@smithy/middleware-stack" "^1.0.1" + "@smithy/node-config-provider" "^1.0.1" + "@smithy/node-http-handler" "^1.0.2" + "@smithy/protocol-http" "^1.1.0" + "@smithy/smithy-client" "^1.0.3" + "@smithy/types" "^1.1.0" + "@smithy/url-parser" "^1.0.1" + "@smithy/util-base64" "^1.0.1" + "@smithy/util-body-length-browser" "^1.0.1" + "@smithy/util-body-length-node" "^1.0.1" + "@smithy/util-defaults-mode-browser" "^1.0.1" + "@smithy/util-defaults-mode-node" "^1.0.1" + "@smithy/util-retry" "^1.0.3" + "@smithy/util-utf8" "^1.0.1" + tslib "^2.5.0" + +"@aws-sdk/client-sts@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/client-sts/-/client-sts-3.370.0.tgz#65879fa35b396035dcab446c782056ef768f48af" + integrity sha512-utFxOPWIzbN+3kc415Je2o4J72hOLNhgR2Gt5EnRSggC3yOnkC4GzauxG8n7n5gZGBX45eyubHyPOXLOIyoqQA== + dependencies: + "@aws-crypto/sha256-browser" "3.0.0" + "@aws-crypto/sha256-js" "3.0.0" + "@aws-sdk/credential-provider-node" "3.370.0" + "@aws-sdk/middleware-host-header" "3.370.0" + "@aws-sdk/middleware-logger" "3.370.0" + "@aws-sdk/middleware-recursion-detection" "3.370.0" + "@aws-sdk/middleware-sdk-sts" "3.370.0" + "@aws-sdk/middleware-signing" "3.370.0" + "@aws-sdk/middleware-user-agent" "3.370.0" + "@aws-sdk/types" "3.370.0" + "@aws-sdk/util-endpoints" "3.370.0" + "@aws-sdk/util-user-agent-browser" "3.370.0" + "@aws-sdk/util-user-agent-node" "3.370.0" + "@smithy/config-resolver" "^1.0.1" + "@smithy/fetch-http-handler" "^1.0.1" + "@smithy/hash-node" "^1.0.1" + "@smithy/invalid-dependency" "^1.0.1" + "@smithy/middleware-content-length" "^1.0.1" + "@smithy/middleware-endpoint" "^1.0.2" + "@smithy/middleware-retry" "^1.0.3" + "@smithy/middleware-serde" "^1.0.1" + "@smithy/middleware-stack" "^1.0.1" + "@smithy/node-config-provider" "^1.0.1" + "@smithy/node-http-handler" "^1.0.2" + "@smithy/protocol-http" "^1.1.0" + "@smithy/smithy-client" "^1.0.3" + "@smithy/types" "^1.1.0" + "@smithy/url-parser" "^1.0.1" + "@smithy/util-base64" "^1.0.1" + "@smithy/util-body-length-browser" "^1.0.1" + "@smithy/util-body-length-node" "^1.0.1" + "@smithy/util-defaults-mode-browser" "^1.0.1" + "@smithy/util-defaults-mode-node" "^1.0.1" + "@smithy/util-retry" "^1.0.3" + "@smithy/util-utf8" "^1.0.1" + fast-xml-parser "4.2.5" + tslib "^2.5.0" + +"@aws-sdk/credential-provider-cognito-identity@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/credential-provider-cognito-identity/-/credential-provider-cognito-identity-3.370.0.tgz#ba251131db44368473b151178a7c2329058dad39" + integrity sha512-OjNAN72+QoyJAmOayi47AlFzpQc4E59LWRE2GKgH0F1pEgr3t34T0/EHusCoxUjOz5mRRXrKjNlHVC7ezOFEcg== + dependencies: + "@aws-sdk/client-cognito-identity" "3.370.0" + "@aws-sdk/types" "3.370.0" + "@smithy/property-provider" "^1.0.1" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/credential-provider-env@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/credential-provider-env/-/credential-provider-env-3.370.0.tgz#edd507a88b36b967da048255f4a478ad92d1c5aa" + integrity sha512-raR3yP/4GGbKFRPP5hUBNkEmTnzxI9mEc2vJAJrcv4G4J4i/UP6ELiLInQ5eO2/VcV/CeKGZA3t7d1tsJ+jhCg== + dependencies: + "@aws-sdk/types" "3.370.0" + "@smithy/property-provider" "^1.0.1" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/credential-provider-ini@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/credential-provider-ini/-/credential-provider-ini-3.370.0.tgz#4e569b8054b4fba2f0a0a7fa88af84b1f8d78c0b" + integrity sha512-eJyapFKa4NrC9RfTgxlXnXfS9InG/QMEUPPVL+VhG7YS6nKqetC1digOYgivnEeu+XSKE0DJ7uZuXujN2Y7VAQ== + dependencies: + "@aws-sdk/credential-provider-env" "3.370.0" + "@aws-sdk/credential-provider-process" "3.370.0" + "@aws-sdk/credential-provider-sso" "3.370.0" + "@aws-sdk/credential-provider-web-identity" "3.370.0" + "@aws-sdk/types" "3.370.0" + "@smithy/credential-provider-imds" "^1.0.1" + "@smithy/property-provider" "^1.0.1" + "@smithy/shared-ini-file-loader" "^1.0.1" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/credential-provider-node@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/credential-provider-node/-/credential-provider-node-3.370.0.tgz#74605644ccbd9e8237223318a7955f4ab2ff0d86" + integrity sha512-gkFiotBFKE4Fcn8CzQnMeab9TAR06FEAD02T4ZRYW1xGrBJOowmje9dKqdwQFHSPgnWAP+8HoTA8iwbhTLvjNA== + dependencies: + "@aws-sdk/credential-provider-env" "3.370.0" + "@aws-sdk/credential-provider-ini" "3.370.0" + "@aws-sdk/credential-provider-process" "3.370.0" + "@aws-sdk/credential-provider-sso" "3.370.0" + "@aws-sdk/credential-provider-web-identity" "3.370.0" + "@aws-sdk/types" "3.370.0" + "@smithy/credential-provider-imds" "^1.0.1" + "@smithy/property-provider" "^1.0.1" + "@smithy/shared-ini-file-loader" "^1.0.1" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/credential-provider-process@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/credential-provider-process/-/credential-provider-process-3.370.0.tgz#f7b94d2ccfda3b067cb23ea832b10c692c831855" + integrity sha512-0BKFFZmUO779Xdw3u7wWnoWhYA4zygxJbgGVSyjkOGBvdkbPSTTcdwT1KFkaQy2kOXYeZPl+usVVRXs+ph4ejg== + dependencies: + "@aws-sdk/types" "3.370.0" + "@smithy/property-provider" "^1.0.1" + "@smithy/shared-ini-file-loader" "^1.0.1" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/credential-provider-sso@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/credential-provider-sso/-/credential-provider-sso-3.370.0.tgz#4c57f93d73f198d7e1e53fbfcdf72c053bc9c682" + integrity sha512-PFroYm5hcPSfC/jkZnCI34QFL3I7WVKveVk6/F3fud/cnP8hp6YjA9NiTNbqdFSzsyoiN/+e5fZgNKih8vVPTA== + dependencies: + "@aws-sdk/client-sso" "3.370.0" + "@aws-sdk/token-providers" "3.370.0" + "@aws-sdk/types" "3.370.0" + "@smithy/property-provider" "^1.0.1" + "@smithy/shared-ini-file-loader" "^1.0.1" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/credential-provider-web-identity@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/credential-provider-web-identity/-/credential-provider-web-identity-3.370.0.tgz#c5831bb656bea1fe3b300e495e19a33bc90f4d84" + integrity sha512-CFaBMLRudwhjv1sDzybNV93IaT85IwS+L8Wq6VRMa0mro1q9rrWsIZO811eF+k0NEPfgU1dLH+8Vc2qhw4SARQ== + dependencies: + "@aws-sdk/types" "3.370.0" + "@smithy/property-provider" "^1.0.1" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/credential-providers@^3.186.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/credential-providers/-/credential-providers-3.370.0.tgz#280878e08298e959e1877a733ed6ead1cb3486d8" + integrity sha512-K5yUHJPB2QJKWzKoz1YCE2xJDvYL6bvCRyoT0mRPWbITrDjFuWxbe1QXWcMymwQIyzOITAnZq5fvj456KhPATg== + dependencies: + "@aws-sdk/client-cognito-identity" "3.370.0" + "@aws-sdk/client-sso" "3.370.0" + "@aws-sdk/client-sts" "3.370.0" + "@aws-sdk/credential-provider-cognito-identity" "3.370.0" + "@aws-sdk/credential-provider-env" "3.370.0" + "@aws-sdk/credential-provider-ini" "3.370.0" + "@aws-sdk/credential-provider-node" "3.370.0" + "@aws-sdk/credential-provider-process" "3.370.0" + "@aws-sdk/credential-provider-sso" "3.370.0" + "@aws-sdk/credential-provider-web-identity" "3.370.0" + "@aws-sdk/types" "3.370.0" + "@smithy/credential-provider-imds" "^1.0.1" + "@smithy/property-provider" "^1.0.1" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/middleware-host-header@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/middleware-host-header/-/middleware-host-header-3.370.0.tgz#645472416efd16b22a66b0aa1d52f48cf5699feb" + integrity sha512-CPXOm/TnOFC7KyXcJglICC7OiA7Kj6mT3ChvEijr56TFOueNHvJdV4aNIFEQy0vGHOWtY12qOWLNto/wYR1BAQ== + dependencies: + "@aws-sdk/types" "3.370.0" + "@smithy/protocol-http" "^1.1.0" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/middleware-logger@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/middleware-logger/-/middleware-logger-3.370.0.tgz#c9f694d7e1dd47b5e6e8eab94793fc1e272b1e26" + integrity sha512-cQMq9SaZ/ORmTJPCT6VzMML7OxFdQzNkhMAgKpTDl+tdPWynlHF29E5xGoSzROnThHlQPCjogU0NZ8AxI0SWPA== + dependencies: + "@aws-sdk/types" "3.370.0" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/middleware-recursion-detection@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/middleware-recursion-detection/-/middleware-recursion-detection-3.370.0.tgz#e5e8fd1d2ff1ade91135295dabcaa81c311ce00b" + integrity sha512-L7ZF/w0lAAY/GK1khT8VdoU0XB7nWHk51rl/ecAg64J70dHnMOAg8n+5FZ9fBu/xH1FwUlHOkwlodJOgzLJjtg== + dependencies: + "@aws-sdk/types" "3.370.0" + "@smithy/protocol-http" "^1.1.0" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/middleware-sdk-sts@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/middleware-sdk-sts/-/middleware-sdk-sts-3.370.0.tgz#0599a624fe5cabe75cd7d9e7420927b102356fa2" + integrity sha512-ykbsoVy0AJtVbuhAlTAMcaz/tCE3pT8nAp0L7CQQxSoanRCvOux7au0KwMIQVhxgnYid4dWVF6d00SkqU5MXRA== + dependencies: + "@aws-sdk/middleware-signing" "3.370.0" + "@aws-sdk/types" "3.370.0" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/middleware-signing@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/middleware-signing/-/middleware-signing-3.370.0.tgz#c094026251faa17a24f61630d56152f7b073e6cf" + integrity sha512-Dwr/RTCWOXdm394wCwICGT2VNOTMRe4IGPsBRJAsM24pm+EEqQzSS3Xu/U/zF4exuxqpMta4wec4QpSarPNTxA== + dependencies: + "@aws-sdk/types" "3.370.0" + "@smithy/property-provider" "^1.0.1" + "@smithy/protocol-http" "^1.1.0" + "@smithy/signature-v4" "^1.0.1" + "@smithy/types" "^1.1.0" + "@smithy/util-middleware" "^1.0.1" + tslib "^2.5.0" + +"@aws-sdk/middleware-user-agent@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/middleware-user-agent/-/middleware-user-agent-3.370.0.tgz#a2bf71baf6407654811a02e4d276a2eec3996fdb" + integrity sha512-2+3SB6MtMAq1+gVXhw0Y3ONXuljorh6ijnxgTpv+uQnBW5jHCUiAS8WDYiDEm7i9euJPbvJfM8WUrSMDMU6Cog== + dependencies: + "@aws-sdk/types" "3.370.0" + "@aws-sdk/util-endpoints" "3.370.0" + "@smithy/protocol-http" "^1.1.0" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/token-providers@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/token-providers/-/token-providers-3.370.0.tgz#e5229f2d116887c90ec103e024583be05c1f506c" + integrity sha512-EyR2ZYr+lJeRiZU2/eLR+mlYU9RXLQvNyGFSAekJKgN13Rpq/h0syzXVFLP/RSod/oZenh/fhVZ2HwlZxuGBtQ== + dependencies: + "@aws-sdk/client-sso-oidc" "3.370.0" + "@aws-sdk/types" "3.370.0" + "@smithy/property-provider" "^1.0.1" + "@smithy/shared-ini-file-loader" "^1.0.1" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/types@3.370.0", "@aws-sdk/types@^3.222.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/types/-/types-3.370.0.tgz#79e0e4927529c957b5c5c2a00f7590a76784a5e4" + integrity sha512-8PGMKklSkRKjunFhzM2y5Jm0H2TBu7YRNISdYzXLUHKSP9zlMEYagseKVdmox0zKHf1LXVNuSlUV2b6SRrieCQ== + dependencies: + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/util-endpoints@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/util-endpoints/-/util-endpoints-3.370.0.tgz#bf1f4653c3afc89d4e79aa4895dd3dffbb56c930" + integrity sha512-5ltVAnM79nRlywwzZN5i8Jp4tk245OCGkKwwXbnDU+gq7zT3CIOsct1wNZvmpfZEPGt/bv7/NyRcjP+7XNsX/g== + dependencies: + "@aws-sdk/types" "3.370.0" + tslib "^2.5.0" + +"@aws-sdk/util-locate-window@^3.0.0": + version "3.310.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/util-locate-window/-/util-locate-window-3.310.0.tgz#b071baf050301adee89051032bd4139bba32cc40" + integrity sha512-qo2t/vBTnoXpjKxlsC2e1gBrRm80M3bId27r0BRB2VniSSe7bL1mmzM+/HFtujm0iAxtPM+aLEflLJlJeDPg0w== + dependencies: + tslib "^2.5.0" + +"@aws-sdk/util-user-agent-browser@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/util-user-agent-browser/-/util-user-agent-browser-3.370.0.tgz#df144f5f1a65578842b79d49555c754a531d85f0" + integrity sha512-028LxYZMQ0DANKhW+AKFQslkScZUeYlPmSphrCIXgdIItRZh6ZJHGzE7J/jDsEntZOrZJsjI4z0zZ5W2idj04w== + dependencies: + "@aws-sdk/types" "3.370.0" + "@smithy/types" "^1.1.0" + bowser "^2.11.0" + tslib "^2.5.0" + +"@aws-sdk/util-user-agent-node@3.370.0": + version "3.370.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/util-user-agent-node/-/util-user-agent-node-3.370.0.tgz#96d8420b42cbebd498de8b94886340d11c97a34b" + integrity sha512-33vxZUp8vxTT/DGYIR3PivQm07sSRGWI+4fCv63Rt7Q++fO24E0kQtmVAlikRY810I10poD6rwILVtITtFSzkg== + dependencies: + "@aws-sdk/types" "3.370.0" + "@smithy/node-config-provider" "^1.0.1" + "@smithy/types" "^1.1.0" + tslib "^2.5.0" + +"@aws-sdk/util-utf8-browser@^3.0.0": + version "3.259.0" + resolved "https://registry.yarnpkg.com/@aws-sdk/util-utf8-browser/-/util-utf8-browser-3.259.0.tgz#3275a6f5eb334f96ca76635b961d3c50259fd9ff" + integrity sha512-UvFa/vR+e19XookZF8RzFZBrw2EUkQWxiBW0yYQAhvk3C+QVGl0H3ouca8LDBlBfQKXwmW3huo/59H8rwb1wJw== + dependencies: + tslib "^2.3.1" + "@babel/code-frame@7.16.7", "@babel/code-frame@^7.0.0", "@babel/code-frame@^7.12.13", "@babel/code-frame@^7.16.7": version "7.16.7" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.16.7.tgz#44416b6bd7624b998f5b1af5d470856c40138789" @@ -970,6 +1422,346 @@ dependencies: "@sinonjs/commons" "^1.7.0" +"@smithy/abort-controller@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/abort-controller/-/abort-controller-1.0.2.tgz#74caac052ecea15c5460438272ad8d43a6ccbc53" + integrity sha512-tb2h0b+JvMee+eAxTmhnyqyNk51UXIK949HnE14lFeezKsVJTB30maan+CO2IMwnig2wVYQH84B5qk6ylmKCuA== + dependencies: + "@smithy/types" "^1.1.1" + tslib "^2.5.0" + +"@smithy/config-resolver@^1.0.1", "@smithy/config-resolver@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/config-resolver/-/config-resolver-1.0.2.tgz#d4f556a44292b41b5c067662a4bd5049dea40e35" + integrity sha512-8Bk7CgnVKg1dn5TgnjwPz2ebhxeR7CjGs5yhVYH3S8x0q8yPZZVWwpRIglwXaf5AZBzJlNO1lh+lUhMf2e73zQ== + dependencies: + "@smithy/types" "^1.1.1" + "@smithy/util-config-provider" "^1.0.2" + "@smithy/util-middleware" "^1.0.2" + tslib "^2.5.0" + +"@smithy/credential-provider-imds@^1.0.1", "@smithy/credential-provider-imds@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/credential-provider-imds/-/credential-provider-imds-1.0.2.tgz#7aa797c0d95448eb3dccb988b40e62db8989576f" + integrity sha512-fLjCya+JOu2gPJpCiwSUyoLvT8JdNJmOaTOkKYBZoGf7CzqR6lluSyI+eboZnl/V0xqcfcqBG4tgqCISmWS3/w== + dependencies: + "@smithy/node-config-provider" "^1.0.2" + "@smithy/property-provider" "^1.0.2" + "@smithy/types" "^1.1.1" + "@smithy/url-parser" "^1.0.2" + tslib "^2.5.0" + +"@smithy/eventstream-codec@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/eventstream-codec/-/eventstream-codec-1.0.2.tgz#06d1b6e2510cb2475a39b3a20b0c75e751917c59" + integrity sha512-eW/XPiLauR1VAgHKxhVvgvHzLROUgTtqat2lgljztbH8uIYWugv7Nz+SgCavB+hWRazv2iYgqrSy74GvxXq/rg== + dependencies: + "@aws-crypto/crc32" "3.0.0" + "@smithy/types" "^1.1.1" + "@smithy/util-hex-encoding" "^1.0.2" + tslib "^2.5.0" + +"@smithy/fetch-http-handler@^1.0.1", "@smithy/fetch-http-handler@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/fetch-http-handler/-/fetch-http-handler-1.0.2.tgz#4186ee6451de22e867f43c05236dcff43eca6e91" + integrity sha512-kynyofLf62LvR8yYphPPdyHb8fWG3LepFinM/vWUTG2Q1pVpmPCM530ppagp3+q2p+7Ox0UvSqldbKqV/d1BpA== + dependencies: + "@smithy/protocol-http" "^1.1.1" + "@smithy/querystring-builder" "^1.0.2" + "@smithy/types" "^1.1.1" + "@smithy/util-base64" "^1.0.2" + tslib "^2.5.0" + +"@smithy/hash-node@^1.0.1": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/hash-node/-/hash-node-1.0.2.tgz#dc65203a348d29e45c493ead3e772e4f7dfb5bc0" + integrity sha512-K6PKhcUNrJXtcesyzhIvNlU7drfIU7u+EMQuGmPw6RQDAg/ufUcfKHz4EcUhFAodUmN+rrejhRG9U6wxjeBOQA== + dependencies: + "@smithy/types" "^1.1.1" + "@smithy/util-buffer-from" "^1.0.2" + "@smithy/util-utf8" "^1.0.2" + tslib "^2.5.0" + +"@smithy/invalid-dependency@^1.0.1": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/invalid-dependency/-/invalid-dependency-1.0.2.tgz#0a9d82d1a14e5bdbdc0bd2cef5f457c85a942920" + integrity sha512-B1Y3Tsa6dfC+Vvb+BJMhTHOfFieeYzY9jWQSTR1vMwKkxsymD0OIAnEw8rD/RiDj/4E4RPGFdx9Mdgnyd6Bv5Q== + dependencies: + "@smithy/types" "^1.1.1" + tslib "^2.5.0" + +"@smithy/is-array-buffer@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/is-array-buffer/-/is-array-buffer-1.0.2.tgz#224702a2364d698f0a36ecb2c240c0c9541ecfb6" + integrity sha512-pkyBnsBRpe+c/6ASavqIMRBdRtZNJEVJOEzhpxZ9JoAXiZYbkfaSMRA/O1dUxGdJ653GHONunnZ4xMo/LJ7utQ== + dependencies: + tslib "^2.5.0" + +"@smithy/middleware-content-length@^1.0.1": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/middleware-content-length/-/middleware-content-length-1.0.2.tgz#63099f8d01b3419b65e21cfd07b0c2ef47d1f473" + integrity sha512-pa1/SgGIrSmnEr2c9Apw7CdU4l/HW0fK3+LKFCPDYJrzM0JdYpqjQzgxi31P00eAkL0EFBccpus/p1n2GF9urw== + dependencies: + "@smithy/protocol-http" "^1.1.1" + "@smithy/types" "^1.1.1" + tslib "^2.5.0" + +"@smithy/middleware-endpoint@^1.0.2": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@smithy/middleware-endpoint/-/middleware-endpoint-1.0.3.tgz#ff4b1c0a83eb8d8b8d3937f434a95efbbf43e1cd" + integrity sha512-GsWvTXMFjSgl617PCE2km//kIjjtvMRrR2GAuRDIS9sHiLwmkS46VWaVYy+XE7ubEsEtzZ5yK2e8TKDR6Qr5Lw== + dependencies: + "@smithy/middleware-serde" "^1.0.2" + "@smithy/types" "^1.1.1" + "@smithy/url-parser" "^1.0.2" + "@smithy/util-middleware" "^1.0.2" + tslib "^2.5.0" + +"@smithy/middleware-retry@^1.0.3": + version "1.0.4" + resolved "https://registry.yarnpkg.com/@smithy/middleware-retry/-/middleware-retry-1.0.4.tgz#8e9de0713dac7f7af405477d46bd4525ca7b9ea8" + integrity sha512-G7uRXGFL8c3F7APnoIMTtNAHH8vT4F2qVnAWGAZaervjupaUQuRRHYBLYubK0dWzOZz86BtAXKieJ5p+Ni2Xpg== + dependencies: + "@smithy/protocol-http" "^1.1.1" + "@smithy/service-error-classification" "^1.0.3" + "@smithy/types" "^1.1.1" + "@smithy/util-middleware" "^1.0.2" + "@smithy/util-retry" "^1.0.4" + tslib "^2.5.0" + uuid "^8.3.2" + +"@smithy/middleware-serde@^1.0.1", "@smithy/middleware-serde@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/middleware-serde/-/middleware-serde-1.0.2.tgz#87b3a0211602ae991d9b756893eb6bf2e3e5f711" + integrity sha512-T4PcdMZF4xme6koUNfjmSZ1MLi7eoFeYCtodQNQpBNsS77TuJt1A6kt5kP/qxrTvfZHyFlj0AubACoaUqgzPeg== + dependencies: + "@smithy/types" "^1.1.1" + tslib "^2.5.0" + +"@smithy/middleware-stack@^1.0.1", "@smithy/middleware-stack@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/middleware-stack/-/middleware-stack-1.0.2.tgz#d241082bf3cb315c749dda57e233039a9aed804e" + integrity sha512-H7/uAQEcmO+eDqweEFMJ5YrIpsBwmrXSP6HIIbtxKJSQpAcMGY7KrR2FZgZBi1FMnSUOh+rQrbOyj5HQmSeUBA== + dependencies: + tslib "^2.5.0" + +"@smithy/node-config-provider@^1.0.1", "@smithy/node-config-provider@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/node-config-provider/-/node-config-provider-1.0.2.tgz#2d391b96a9e10072e7e0a3698427400f4ef17ec4" + integrity sha512-HU7afWpTToU0wL6KseGDR2zojeyjECQfr8LpjAIeHCYIW7r360ABFf4EaplaJRMVoC3hD9FeltgI3/NtShOqCg== + dependencies: + "@smithy/property-provider" "^1.0.2" + "@smithy/shared-ini-file-loader" "^1.0.2" + "@smithy/types" "^1.1.1" + tslib "^2.5.0" + +"@smithy/node-http-handler@^1.0.2", "@smithy/node-http-handler@^1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@smithy/node-http-handler/-/node-http-handler-1.0.3.tgz#89b556ca2bdcce7a994a9da1ea265094d76d4791" + integrity sha512-PcPUSzTbIb60VCJCiH0PU0E6bwIekttsIEf5Aoo/M0oTfiqsxHTn0Rcij6QoH6qJy6piGKXzLSegspXg5+Kq6g== + dependencies: + "@smithy/abort-controller" "^1.0.2" + "@smithy/protocol-http" "^1.1.1" + "@smithy/querystring-builder" "^1.0.2" + "@smithy/types" "^1.1.1" + tslib "^2.5.0" + +"@smithy/property-provider@^1.0.1", "@smithy/property-provider@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/property-provider/-/property-provider-1.0.2.tgz#f99f104cbd6576c9aca9f56cb72819b4a65208e1" + integrity sha512-pXDPyzKX8opzt38B205kDgaxda6LHcTfPvTYQZnwP6BAPp1o9puiCPjeUtkKck7Z6IbpXCPUmUQnzkUzWTA42Q== + dependencies: + "@smithy/types" "^1.1.1" + tslib "^2.5.0" + +"@smithy/protocol-http@^1.1.0", "@smithy/protocol-http@^1.1.1": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@smithy/protocol-http/-/protocol-http-1.1.1.tgz#10977cf71631eed4f5ad1845408920238d52cdba" + integrity sha512-mFLFa2sSvlUxm55U7B4YCIsJJIMkA6lHxwwqOaBkral1qxFz97rGffP/mmd4JDuin1EnygiO5eNJGgudiUgmDQ== + dependencies: + "@smithy/types" "^1.1.1" + tslib "^2.5.0" + +"@smithy/querystring-builder@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/querystring-builder/-/querystring-builder-1.0.2.tgz#ce861f6cbd14792c83aa19b4967a19923bd0706e" + integrity sha512-6P/xANWrtJhMzTPUR87AbXwSBuz1SDHIfL44TFd/GT3hj6rA+IEv7rftEpPjayUiWRocaNnrCPLvmP31mobOyA== + dependencies: + "@smithy/types" "^1.1.1" + "@smithy/util-uri-escape" "^1.0.2" + tslib "^2.5.0" + +"@smithy/querystring-parser@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/querystring-parser/-/querystring-parser-1.0.2.tgz#559d09c46b21e6fbda71e95deda4bcd8a46bdecc" + integrity sha512-IWxwxjn+KHWRRRB+K2Ngl+plTwo2WSgc2w+DvLy0DQZJh9UGOpw40d6q97/63GBlXIt4TEt5NbcFrO30CKlrsA== + dependencies: + "@smithy/types" "^1.1.1" + tslib "^2.5.0" + +"@smithy/service-error-classification@^1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@smithy/service-error-classification/-/service-error-classification-1.0.3.tgz#c620c1562610d3351985eb6dd04262ca2657ae67" + integrity sha512-2eglIYqrtcUnuI71yweu7rSfCgt6kVvRVf0C72VUqrd0LrV1M0BM0eYN+nitp2CHPSdmMI96pi+dU9U/UqAMSA== + +"@smithy/shared-ini-file-loader@^1.0.1", "@smithy/shared-ini-file-loader@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/shared-ini-file-loader/-/shared-ini-file-loader-1.0.2.tgz#c6e79991d87925bd18e0adae00c97da6c8ecae1e" + integrity sha512-bdQj95VN+lCXki+P3EsDyrkpeLn8xDYiOISBGnUG/AGPYJXN8dmp4EhRRR7XOoLoSs8anZHR4UcGEOzFv2jwGw== + dependencies: + "@smithy/types" "^1.1.1" + tslib "^2.5.0" + +"@smithy/signature-v4@^1.0.1": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/signature-v4/-/signature-v4-1.0.2.tgz#3a7b10ac66c337b404aa061e5f268f0550729680" + integrity sha512-rpKUhmCuPmpV5dloUkOb9w1oBnJatvKQEjIHGmkjRGZnC3437MTdzWej9TxkagcZ8NRRJavYnEUixzxM1amFig== + dependencies: + "@smithy/eventstream-codec" "^1.0.2" + "@smithy/is-array-buffer" "^1.0.2" + "@smithy/types" "^1.1.1" + "@smithy/util-hex-encoding" "^1.0.2" + "@smithy/util-middleware" "^1.0.2" + "@smithy/util-uri-escape" "^1.0.2" + "@smithy/util-utf8" "^1.0.2" + tslib "^2.5.0" + +"@smithy/smithy-client@^1.0.3": + version "1.0.4" + resolved "https://registry.yarnpkg.com/@smithy/smithy-client/-/smithy-client-1.0.4.tgz#96d03d123d117a637c679a79bb8eae96e3857bd9" + integrity sha512-gpo0Xl5Nyp9sgymEfpt7oa9P2q/GlM3VmQIdm+FeH0QEdYOQx3OtvwVmBYAMv2FIPWxkMZlsPYRTnEiBTK5TYg== + dependencies: + "@smithy/middleware-stack" "^1.0.2" + "@smithy/types" "^1.1.1" + "@smithy/util-stream" "^1.0.2" + tslib "^2.5.0" + +"@smithy/types@^1.1.0", "@smithy/types@^1.1.1": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@smithy/types/-/types-1.1.1.tgz#949394a22e13e7077471bae0d18c146e5f62c456" + integrity sha512-tMpkreknl2gRrniHeBtdgQwaOlo39df8RxSrwsHVNIGXULy5XP6KqgScUw2m12D15wnJCKWxVhCX+wbrBW/y7g== + dependencies: + tslib "^2.5.0" + +"@smithy/url-parser@^1.0.1", "@smithy/url-parser@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/url-parser/-/url-parser-1.0.2.tgz#fb59be6f2283399443d9e7afe08ebf63b3c266bb" + integrity sha512-0JRsDMQe53F6EHRWksdcavKDRjyqp8vrjakg8EcCUOa7PaFRRB1SO/xGZdzSlW1RSTWQDEksFMTCEcVEKmAoqA== + dependencies: + "@smithy/querystring-parser" "^1.0.2" + "@smithy/types" "^1.1.1" + tslib "^2.5.0" + +"@smithy/util-base64@^1.0.1", "@smithy/util-base64@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/util-base64/-/util-base64-1.0.2.tgz#6cdd5a9356dafad3c531123c12cd77d674762da0" + integrity sha512-BCm15WILJ3SL93nusoxvJGMVfAMWHZhdeDZPtpAaskozuexd0eF6szdz4kbXaKp38bFCSenA6bkUHqaE3KK0dA== + dependencies: + "@smithy/util-buffer-from" "^1.0.2" + tslib "^2.5.0" + +"@smithy/util-body-length-browser@^1.0.1": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/util-body-length-browser/-/util-body-length-browser-1.0.2.tgz#4a9a49497634b5f25ab5ff73f1a8498010b0024a" + integrity sha512-Xh8L06H2anF5BHjSYTg8hx+Itcbf4SQZnVMl4PIkCOsKtneMJoGjPRLy17lEzfoh/GOaa0QxgCP6lRMQWzNl4w== + dependencies: + tslib "^2.5.0" + +"@smithy/util-body-length-node@^1.0.1": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/util-body-length-node/-/util-body-length-node-1.0.2.tgz#bc4969022f7d9ffcb239d626d80a85138e986df6" + integrity sha512-nXHbZsUtvZeyfL4Ceds9nmy2Uh2AhWXohG4vWHyjSdmT8cXZlJdmJgnH6SJKDjyUecbu+BpKeVvSrA4cWPSOPA== + dependencies: + tslib "^2.5.0" + +"@smithy/util-buffer-from@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/util-buffer-from/-/util-buffer-from-1.0.2.tgz#27e19573d721962bd2443f23d4edadb8206b2cb5" + integrity sha512-lHAYIyrBO9RANrPvccnPjU03MJnWZ66wWuC5GjWWQVfsmPwU6m00aakZkzHdUT6tGCkGacXSgArP5wgTgA+oCw== + dependencies: + "@smithy/is-array-buffer" "^1.0.2" + tslib "^2.5.0" + +"@smithy/util-config-provider@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/util-config-provider/-/util-config-provider-1.0.2.tgz#4d2e867df1cc7b4010d1278bd5767ce1b679dae9" + integrity sha512-HOdmDm+3HUbuYPBABLLHtn8ittuRyy+BSjKOA169H+EMc+IozipvXDydf+gKBRAxUa4dtKQkLraypwppzi+PRw== + dependencies: + tslib "^2.5.0" + +"@smithy/util-defaults-mode-browser@^1.0.1": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/util-defaults-mode-browser/-/util-defaults-mode-browser-1.0.2.tgz#31ad7b9bce7e38fd57f4a370ee416373b4fbd432" + integrity sha512-J1u2PO235zxY7dg0+ZqaG96tFg4ehJZ7isGK1pCBEA072qxNPwIpDzUVGnLJkHZvjWEGA8rxIauDtXfB0qxeAg== + dependencies: + "@smithy/property-provider" "^1.0.2" + "@smithy/types" "^1.1.1" + bowser "^2.11.0" + tslib "^2.5.0" + +"@smithy/util-defaults-mode-node@^1.0.1": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/util-defaults-mode-node/-/util-defaults-mode-node-1.0.2.tgz#b295fe2a18568c1e21a85b6557e2b769452b4d95" + integrity sha512-9/BN63rlIsFStvI+AvljMh873Xw6bbI6b19b+PVYXyycQ2DDQImWcjnzRlHW7eP65CCUNGQ6otDLNdBQCgMXqg== + dependencies: + "@smithy/config-resolver" "^1.0.2" + "@smithy/credential-provider-imds" "^1.0.2" + "@smithy/node-config-provider" "^1.0.2" + "@smithy/property-provider" "^1.0.2" + "@smithy/types" "^1.1.1" + tslib "^2.5.0" + +"@smithy/util-hex-encoding@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/util-hex-encoding/-/util-hex-encoding-1.0.2.tgz#5b9f2162f2a59b2d2aa39992bd2c7f65b6616ab6" + integrity sha512-Bxydb5rMJorMV6AuDDMOxro3BMDdIwtbQKHpwvQFASkmr52BnpDsWlxgpJi8Iq7nk1Bt4E40oE1Isy/7ubHGzg== + dependencies: + tslib "^2.5.0" + +"@smithy/util-middleware@^1.0.1", "@smithy/util-middleware@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/util-middleware/-/util-middleware-1.0.2.tgz#c3d4c7a6cd31bde33901e54abd7700c8ca73dab3" + integrity sha512-vtXK7GOR2BoseCX8NCGe9SaiZrm9M2lm/RVexFGyPuafTtry9Vyv7hq/vw8ifd/G/pSJ+msByfJVb1642oQHKw== + dependencies: + tslib "^2.5.0" + +"@smithy/util-retry@^1.0.3", "@smithy/util-retry@^1.0.4": + version "1.0.4" + resolved "https://registry.yarnpkg.com/@smithy/util-retry/-/util-retry-1.0.4.tgz#9d95df3884981414163d5f780d38e3529384d9ad" + integrity sha512-RnZPVFvRoqdj2EbroDo3OsnnQU8eQ4AlnZTOGusbYKybH3269CFdrZfZJloe60AQjX7di3J6t/79PjwCLO5Khw== + dependencies: + "@smithy/service-error-classification" "^1.0.3" + tslib "^2.5.0" + +"@smithy/util-stream@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/util-stream/-/util-stream-1.0.2.tgz#2d33aa5168e51d1dd7937c32a09c8334d2da44d9" + integrity sha512-qyN2M9QFMTz4UCHi6GnBfLOGYKxQZD01Ga6nzaXFFC51HP/QmArU72e4kY50Z/EtW8binPxspP2TAsGbwy9l3A== + dependencies: + "@smithy/fetch-http-handler" "^1.0.2" + "@smithy/node-http-handler" "^1.0.3" + "@smithy/types" "^1.1.1" + "@smithy/util-base64" "^1.0.2" + "@smithy/util-buffer-from" "^1.0.2" + "@smithy/util-hex-encoding" "^1.0.2" + "@smithy/util-utf8" "^1.0.2" + tslib "^2.5.0" + +"@smithy/util-uri-escape@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/util-uri-escape/-/util-uri-escape-1.0.2.tgz#c69a5423c9baa7a045a79372320bd40a437ac756" + integrity sha512-k8C0BFNS9HpBMHSgUDnWb1JlCQcFG+PPlVBq9keP4Nfwv6a9Q0yAfASWqUCtzjuMj1hXeLhn/5ADP6JxnID1Pg== + dependencies: + tslib "^2.5.0" + +"@smithy/util-utf8@^1.0.1", "@smithy/util-utf8@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@smithy/util-utf8/-/util-utf8-1.0.2.tgz#b34c27b4efbe4f0edb6560b6d4f743088302671f" + integrity sha512-V4cyjKfJlARui0dMBfWJMQAmJzoW77i4N3EjkH/bwnE2Ngbl4tqD2Y0C/xzpzY/J1BdxeCKxAebVFk8aFCaSCw== + dependencies: + "@smithy/util-buffer-from" "^1.0.2" + tslib "^2.5.0" + "@testim/chrome-version@^1.1.2": version "1.1.2" resolved "https://registry.yarnpkg.com/@testim/chrome-version/-/chrome-version-1.1.2.tgz#092005c5b77bd3bb6576a4677110a11485e11864" @@ -1780,6 +2572,11 @@ body-parser@^1.19.0: type-is "~1.6.18" unpipe "1.0.0" +bowser@^2.11.0: + version "2.11.0" + resolved "https://registry.yarnpkg.com/bowser/-/bowser-2.11.0.tgz#5ca3c35757a7aa5771500c70a73a9f91ef420a8f" + integrity sha512-AlcaJBi/pqqJBIQ8U9Mcpc9i8Aqxn88Skv5d+xBX006BY5u8N3mGLHa5Lgppa7L/HfwgwLgZ6NYs+Ag6uUmJRA== + brace-expansion@^1.1.7: version "1.1.11" resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd" @@ -1830,10 +2627,10 @@ bser@2.1.1: dependencies: node-int64 "^0.4.0" -bson@^4.6.2, bson@^4.6.3: - version "4.7.0" - resolved "https://registry.yarnpkg.com/bson/-/bson-4.7.0.tgz#7874a60091ffc7a45c5dd2973b5cad7cded9718a" - integrity sha512-VrlEE4vuiO1WTpfof4VmaVolCVYkYTgB9iWgYNOrVlnifpME/06fhFRmONgBhClD5pFC1t9ZWqFUQEQAzY43bA== +bson@^4.7.2: + version "4.7.2" + resolved "https://registry.yarnpkg.com/bson/-/bson-4.7.2.tgz#320f4ad0eaf5312dd9b45dc369cc48945e2a5f2e" + integrity sha512-Ry9wCtIZ5kGqkJoi6aD8KjxFZEx78guTQDnpXWiNthsxzrxAK/i8E6pCHAIZTbaEFWcOCvbecMukfK7XUvyLpQ== dependencies: buffer "^5.6.0" @@ -2252,11 +3049,6 @@ delayed-stream@~1.0.0: resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" integrity sha1-3zrhmayt+31ECqrgsp4icrJOxhk= -denque@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/denque/-/denque-2.0.1.tgz#bcef4c1b80dc32efe97515744f21a4229ab8934a" - integrity sha512-tfiWc6BQLXNLpNiR5iGd0Ocu3P3VpxfzFiqubLgMfhfOw9WyvgJBd46CClNn9k3qfbjvT//0cf7AlYRX/OslMQ== - depd@2.0.0, depd@~2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/depd/-/depd-2.0.0.tgz#b696163cc757560d09cf22cc8fad1571b79e76df" @@ -2826,6 +3618,13 @@ fast-levenshtein@^2.0.6, fast-levenshtein@~2.0.6: resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= +fast-xml-parser@4.2.5: + version "4.2.5" + resolved "https://registry.yarnpkg.com/fast-xml-parser/-/fast-xml-parser-4.2.5.tgz#a6747a09296a6cb34f2ae634019bf1738f3b421f" + integrity sha512-B9/wizE4WngqQftFPmdaMYlXoJlJOYxGQOanC77fq9k8+Z0v5dDSVh+3glErdIROP//s/jgb7ZuxKfB8nVyo0g== + dependencies: + strnum "^1.0.5" + fastq@^1.6.0: version "1.13.0" resolved "https://registry.yarnpkg.com/fastq/-/fastq-1.13.0.tgz#616760f88a7526bdfc596b7cab8c18938c36b98c" @@ -4045,10 +4844,10 @@ jwt-decode@^3.1.2: resolved "https://registry.yarnpkg.com/jwt-decode/-/jwt-decode-3.1.2.tgz#3fb319f3675a2df0c2895c8f5e9fa4b67b04ed59" integrity sha512-UfpWE/VZn0iP50d8cz9NrZLM9lSWhcJ+0Gt/nm4by88UL+J1SiKN8/5dkjMmbEzwL2CAe+67GsegCbIKtbp75A== -kareem@2.4.1: - version "2.4.1" - resolved "https://registry.yarnpkg.com/kareem/-/kareem-2.4.1.tgz#7d81ec518204a48c1cb16554af126806c3cd82b0" - integrity sha512-aJ9opVoXroQUPfovYP5kaj2lM7Jn02Gw13bL0lg9v0V7SaUc0qavPs0Eue7d2DcC3NjqI6QAUElXNsuZSeM+EA== +kareem@2.5.1: + version "2.5.1" + resolved "https://registry.yarnpkg.com/kareem/-/kareem-2.5.1.tgz#7b8203e11819a8e77a34b3517d3ead206764d15d" + integrity sha512-7jFxRVm+jD+rkq3kY0iZDJfsO2/t4BBPeEb2qKn2lR/9KhuksYk5hxzfRYWMPV8P/x2d0kHD306YyWLzjjH+uA== keycloak-connect@21.0.1: version "21.0.1" @@ -4312,38 +5111,38 @@ mkdirp@^1.0.4: resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-1.0.4.tgz#3eb5ed62622756d79a5f0e2a221dfebad75c2f7e" integrity sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw== -mongodb-connection-string-url@^2.5.2: - version "2.5.3" - resolved "https://registry.yarnpkg.com/mongodb-connection-string-url/-/mongodb-connection-string-url-2.5.3.tgz#c0c572b71570e58be2bd52b33dffd1330cfb6990" - integrity sha512-f+/WsED+xF4B74l3k9V/XkTVj5/fxFH2o5ToKXd8Iyi5UhM+sO9u0Ape17Mvl/GkZaFtM0HQnzAG5OTmhKw+tQ== +mongodb-connection-string-url@^2.5.4: + version "2.6.0" + resolved "https://registry.yarnpkg.com/mongodb-connection-string-url/-/mongodb-connection-string-url-2.6.0.tgz#57901bf352372abdde812c81be47b75c6b2ec5cf" + integrity sha512-WvTZlI9ab0QYtTYnuMLgobULWhokRjtC7db9LtcVfJ+Hsnyr5eo6ZtNAt3Ly24XZScGMelOcGtm7lSn0332tPQ== dependencies: "@types/whatwg-url" "^8.2.1" whatwg-url "^11.0.0" -mongodb@4.7.0: - version "4.7.0" - resolved "https://registry.yarnpkg.com/mongodb/-/mongodb-4.7.0.tgz#99f7323271d93659067695b60e7b4efee2de9bf0" - integrity sha512-HhVar6hsUeMAVlIbwQwWtV36iyjKd9qdhY+s4wcU8K6TOj4Q331iiMy+FoPuxEntDIijTYWivwFJkLv8q/ZgvA== +mongodb@4.16.0: + version "4.16.0" + resolved "https://registry.yarnpkg.com/mongodb/-/mongodb-4.16.0.tgz#8b0043de7b577c6a7e0ce44a2ca7315b9c0a7927" + integrity sha512-0EB113Fsucaq1wsY0dOhi1fmZOwFtLOtteQkiqOXGklvWMnSH3g2QS53f0KTP+/6qOkuoXE2JksubSZNmxeI+g== dependencies: - bson "^4.6.3" - denque "^2.0.1" - mongodb-connection-string-url "^2.5.2" - socks "^2.6.2" + bson "^4.7.2" + mongodb-connection-string-url "^2.5.4" + socks "^2.7.1" optionalDependencies: + "@aws-sdk/credential-providers" "^3.186.0" saslprep "^1.0.3" -mongoose@*, mongoose@^6.4.6: - version "6.4.6" - resolved "https://registry.yarnpkg.com/mongoose/-/mongoose-6.4.6.tgz#57bc7ae68de56abcc5e890284f2d10acac863aa2" - integrity sha512-ZAfNCWgXhwev6k/+rMzjHIJ/+wLkundQU/i+aUTqmCgGoYqc+B5e4EC4Y3E1XaLzNXiWID1/vocSM6zs5IAGvA== +mongoose@*, mongoose@^6.11.3: + version "6.11.3" + resolved "https://registry.yarnpkg.com/mongoose/-/mongoose-6.11.3.tgz#26e5de0437c470f09c5a71a188a75718efc6c84a" + integrity sha512-M1Y5PjttgV51YDa30u7GVMVypQSlNZF/jUhlzTBAmaz5C9FvOr8eih/VLhhO7xtTSlcVTFQS1dqlQNMbtfUowQ== dependencies: - bson "^4.6.2" - kareem "2.4.1" - mongodb "4.7.0" + bson "^4.7.2" + kareem "2.5.1" + mongodb "4.16.0" mpath "0.9.0" mquery "4.0.3" ms "2.1.3" - sift "16.0.0" + sift "16.0.1" mpath@0.9.0: version "0.9.0" @@ -5023,10 +5822,10 @@ side-channel@^1.0.4: get-intrinsic "^1.0.2" object-inspect "^1.9.0" -sift@16.0.0: - version "16.0.0" - resolved "https://registry.yarnpkg.com/sift/-/sift-16.0.0.tgz#447991577db61f1a8fab727a8a98a6db57a23eb8" - integrity sha512-ILTjdP2Mv9V1kIxWMXeMTIRbOBrqKc4JAXmFMnFq3fKeyQ2Qwa3Dw1ubcye3vR+Y6ofA0b9gNDr/y2t6eUeIzQ== +sift@16.0.1: + version "16.0.1" + resolved "https://registry.yarnpkg.com/sift/-/sift-16.0.1.tgz#e9c2ccc72191585008cf3e36fc447b2d2633a053" + integrity sha512-Wv6BjQ5zbhW7VFefWusVP33T/EM0vYikCaQ2qR8yULbsilAT8/wQaXvuQ3ptGLpoKx+lihJE3y2UTgKDyyNHZQ== signal-exit@^3.0.2, signal-exit@^3.0.3: version "3.0.7" @@ -5060,10 +5859,10 @@ smart-buffer@^4.2.0: resolved "https://registry.yarnpkg.com/smart-buffer/-/smart-buffer-4.2.0.tgz#6e1d71fa4f18c05f7d0ff216dd16a481d0e8d9ae" integrity sha512-94hK0Hh8rPqQl2xXc3HsaBoOXKV20MToPkcXvwbISWLEs+64sBq5kFgn2kJDHb1Pry9yrP0dxrCI9RRci7RXKg== -socks@^2.6.2: - version "2.7.0" - resolved "https://registry.yarnpkg.com/socks/-/socks-2.7.0.tgz#f9225acdb841e874dca25f870e9130990f3913d0" - integrity sha512-scnOe9y4VuiNUULJN72GrM26BNOjVsfPXI+j+98PkyEfsIXroa5ofyjT+FzGvn/xHs73U2JtoBYAVx9Hl4quSA== +socks@^2.7.1: + version "2.7.1" + resolved "https://registry.yarnpkg.com/socks/-/socks-2.7.1.tgz#d8e651247178fde79c0663043e07240196857d55" + integrity sha512-7maUZy1N7uo6+WVEX6psASxtNlKaNVMlGQKkG/63nEDdLOWNbiUMoLK7X4uYoLhQstau72mLgfEWcXcwsaHbYQ== dependencies: ip "^2.0.0" smart-buffer "^4.2.0" @@ -5207,6 +6006,11 @@ strip-json-comments@^3.1.0, strip-json-comments@^3.1.1: resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== +strnum@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/strnum/-/strnum-1.0.5.tgz#5c4e829fe15ad4ff0d20c3db5ac97b73c9b072db" + integrity sha512-J8bbNyKKXl5qYcR36TIO8W3mVGVHrmmxsd5PAItGkmyzwJvybiw2IVq5nqd0i4LSNSkB/sx9VHllbfFdr9k1JA== + subscriptions-transport-ws@^0.11.0: version "0.11.0" resolved "https://registry.yarnpkg.com/subscriptions-transport-ws/-/subscriptions-transport-ws-0.11.0.tgz#baf88f050cba51d52afe781de5e81b3c31f89883" @@ -5433,7 +6237,7 @@ tsconfig@^7.0.0: strip-bom "^3.0.0" strip-json-comments "^2.0.0" -tslib@^1.8.1: +tslib@^1.11.1, tslib@^1.8.1: version "1.14.1" resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== @@ -5448,6 +6252,11 @@ tslib@^2.1.0, tslib@^2.4.0: resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.4.0.tgz#7cecaa7f073ce680a05847aa77be941098f36dc3" integrity sha512-d6xOpEDfsi2CZVlPQzGeux8XMwLT9hssAsaPYExaQMuYskwb+x1x7J371tWlbBdWHroy99KnVB6qIkUbs5X3UQ== +tslib@^2.3.1, tslib@^2.5.0: + version "2.6.0" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.6.0.tgz#b295854684dbda164e181d259a22cd779dcd7bc3" + integrity sha512-7At1WUettjcSRHXCyYtTselblcHl9PJFFVKiCAy/bY97+BPZXSQ2wbq0P9s8tK2G7dFQfNnlJnPAiArVBVBsfA== + tsutils@^3.21.0: version "3.21.0" resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-3.21.0.tgz#b48717d394cea6c1e096983eed58e9d61715b623" @@ -5570,7 +6379,7 @@ utils-merge@1.0.1: resolved "https://registry.yarnpkg.com/utils-merge/-/utils-merge-1.0.1.tgz#9f95710f50a267947b2ccc124741c1028427e713" integrity sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM= -uuid@^8.0.0: +uuid@^8.0.0, uuid@^8.3.2: version "8.3.2" resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== From 387f57068edeeebfe29fb30f8afe0139df3d5104 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Fri, 18 Aug 2023 15:00:36 -0400 Subject: [PATCH 23/57] Set ApolloServer cache to bounded (#354) --- server/src/server.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/server/src/server.ts b/server/src/server.ts index edc4d678..f63f32ac 100644 --- a/server/src/server.ts +++ b/server/src/server.ts @@ -85,6 +85,7 @@ const startServer = async () => { schema, context: ({ req, res }: any) => ({ req, res }), plugins: [ApolloServerPluginLandingPageGraphQLPlayground()], + cache: 'bounded', }); await apolloServer.start(); apolloServer.applyMiddleware({ app }); From 37067ec4c89d75dce131a78ddf30dec8f1c66909 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 31 Aug 2023 11:22:55 -0400 Subject: [PATCH 24/57] Bump apollo-server-core from 3.10.1 to 3.12.1 in /server (#356) Bumps [apollo-server-core](https://github.com/apollographql/apollo-server/tree/HEAD/packages/apollo-server-core) from 3.10.1 to 3.12.1. - [Release notes](https://github.com/apollographql/apollo-server/releases) - [Commits](https://github.com/apollographql/apollo-server/commits/apollo-server-core@3.12.1/packages/apollo-server-core) --- updated-dependencies: - dependency-name: apollo-server-core dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- server/yarn.lock | 75 +++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 61 insertions(+), 14 deletions(-) diff --git a/server/yarn.lock b/server/yarn.lock index 3884962e..413930dd 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -28,6 +28,25 @@ "@types/node" "^10.1.0" long "^4.0.0" +"@apollo/protobufjs@1.2.6": + version "1.2.6" + resolved "https://registry.yarnpkg.com/@apollo/protobufjs/-/protobufjs-1.2.6.tgz#d601e65211e06ae1432bf5993a1a0105f2862f27" + integrity sha512-Wqo1oSHNUj/jxmsVp4iR3I480p6qdqHikn38lKrFhfzcDJ7lwd7Ck7cHRl4JE81tWNArl77xhnG/OkZhxKBYOw== + dependencies: + "@protobufjs/aspromise" "^1.1.2" + "@protobufjs/base64" "^1.1.2" + "@protobufjs/codegen" "^2.0.4" + "@protobufjs/eventemitter" "^1.1.0" + "@protobufjs/fetch" "^1.1.0" + "@protobufjs/float" "^1.0.2" + "@protobufjs/inquire" "^1.1.0" + "@protobufjs/path" "^1.1.2" + "@protobufjs/pool" "^1.1.0" + "@protobufjs/utf8" "^1.1.0" + "@types/long" "^4.0.0" + "@types/node" "^10.1.0" + long "^4.0.0" + "@apollo/utils.dropunuseddefinitions@^1.1.0": version "1.1.0" resolved "https://registry.yarnpkg.com/@apollo/utils.dropunuseddefinitions/-/utils.dropunuseddefinitions-1.1.0.tgz#02b04006442eaf037f4c4624146b12775d70d929" @@ -2284,10 +2303,17 @@ apollo-reporting-protobuf@^3.3.1, apollo-reporting-protobuf@^3.3.2: dependencies: "@apollo/protobufjs" "1.2.4" +apollo-reporting-protobuf@^3.4.0: + version "3.4.0" + resolved "https://registry.yarnpkg.com/apollo-reporting-protobuf/-/apollo-reporting-protobuf-3.4.0.tgz#6edd31f09d4a3704d9e808d1db30eca2229ded26" + integrity sha512-h0u3EbC/9RpihWOmcSsvTW2O6RXVaD/mPEjfrPkxRPTEPWqncsgOoRJw+wih4OqfH3PvTJvoEIf4LwKrUaqWog== + dependencies: + "@apollo/protobufjs" "1.2.6" + apollo-server-core@^3.6.7: - version "3.10.1" - resolved "https://registry.yarnpkg.com/apollo-server-core/-/apollo-server-core-3.10.1.tgz#01f9ffc57c7d15c27bd7f89d65f45522aa3f3c3d" - integrity sha512-UFFziv6h15QbKRZOA6wLyr1Sle9kns3JuQ5DEB7OYe5AIoOJNjZkWXX/tmLFUrSmlnDDryi6Sf5pDzpYmUC/UA== + version "3.12.1" + resolved "https://registry.yarnpkg.com/apollo-server-core/-/apollo-server-core-3.12.1.tgz#ba255c37345db29c48a2e0c064c519a8d62eb5af" + integrity sha512-9SF5WAkkV0FZQ2HVUWI9Jada1U0jg7e8NCN9EklbtvaCeUlOLyXyM+KCWuZ7+dqHxjshbtcwylPHutt3uzoNkw== dependencies: "@apollo/utils.keyvaluecache" "^1.0.1" "@apollo/utils.logger" "^1.0.0" @@ -2298,18 +2324,19 @@ apollo-server-core@^3.6.7: "@graphql-tools/schema" "^8.0.0" "@josephg/resolvable" "^1.0.0" apollo-datasource "^3.3.2" - apollo-reporting-protobuf "^3.3.2" + apollo-reporting-protobuf "^3.4.0" apollo-server-env "^4.2.1" apollo-server-errors "^3.3.1" - apollo-server-plugin-base "^3.6.2" - apollo-server-types "^3.6.2" + apollo-server-plugin-base "^3.7.2" + apollo-server-types "^3.8.0" async-retry "^1.2.1" fast-json-stable-stringify "^2.1.0" graphql-tag "^2.11.0" loglevel "^1.6.8" lru-cache "^6.0.0" + node-abort-controller "^3.0.1" sha.js "^2.4.11" - uuid "^8.0.0" + uuid "^9.0.0" whatwg-mimetype "^3.0.0" apollo-server-env@^4.2.1: @@ -2341,14 +2368,14 @@ apollo-server-express@3.x: cors "^2.8.5" parseurl "^1.3.3" -apollo-server-plugin-base@^3.6.2: - version "3.6.2" - resolved "https://registry.yarnpkg.com/apollo-server-plugin-base/-/apollo-server-plugin-base-3.6.2.tgz#f256e1f274c8fee0d7267b6944f402da71788fb3" - integrity sha512-erWXjLOO1u7fxQkbxJ2cwSO7p0tYzNied91I1SJ9tikXZ/2eZUyDyvrpI+4g70kOdEi+AmJ5Fo8ahEXKJ75zdg== +apollo-server-plugin-base@^3.7.2: + version "3.7.2" + resolved "https://registry.yarnpkg.com/apollo-server-plugin-base/-/apollo-server-plugin-base-3.7.2.tgz#c19cd137bc4c993ba2490ba2b571b0f3ce60a0cd" + integrity sha512-wE8dwGDvBOGehSsPTRZ8P/33Jan6/PmL0y0aN/1Z5a5GcbFhDaaJCjK5cav6npbbGL2DPKK0r6MPXi3k3N45aw== dependencies: - apollo-server-types "^3.6.2" + apollo-server-types "^3.8.0" -apollo-server-types@^3.5.2, apollo-server-types@^3.6.2: +apollo-server-types@^3.5.2: version "3.6.2" resolved "https://registry.yarnpkg.com/apollo-server-types/-/apollo-server-types-3.6.2.tgz#34bb0c335fcce3057cbdf72b3b63da182de6fc84" integrity sha512-9Z54S7NB+qW1VV+kmiqwU2Q6jxWfX89HlSGCGOo3zrkrperh85LrzABgN9S92+qyeHYd72noMDg2aI039sF3dg== @@ -2358,6 +2385,16 @@ apollo-server-types@^3.5.2, apollo-server-types@^3.6.2: apollo-reporting-protobuf "^3.3.2" apollo-server-env "^4.2.1" +apollo-server-types@^3.8.0: + version "3.8.0" + resolved "https://registry.yarnpkg.com/apollo-server-types/-/apollo-server-types-3.8.0.tgz#d976b6967878681f715fe2b9e4dad9ba86b1346f" + integrity sha512-ZI/8rTE4ww8BHktsVpb91Sdq7Cb71rdSkXELSwdSR0eXu600/sY+1UXhTWdiJvk+Eq5ljqoHLwLbY2+Clq2b9A== + dependencies: + "@apollo/utils.keyvaluecache" "^1.0.1" + "@apollo/utils.logger" "^1.0.0" + apollo-reporting-protobuf "^3.4.0" + apollo-server-env "^4.2.1" + arg@^4.1.0: version "4.1.3" resolved "https://registry.yarnpkg.com/arg/-/arg-4.1.3.tgz#269fc7ad5b8e42cb63c896d5666017261c144089" @@ -5181,6 +5218,11 @@ negotiator@0.6.3: resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.3.tgz#58e323a72fedc0d6f9cd4d31fe49f51479590ccd" integrity sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg== +node-abort-controller@^3.0.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/node-abort-controller/-/node-abort-controller-3.1.1.tgz#a94377e964a9a37ac3976d848cb5c765833b8548" + integrity sha512-AGK2yQKIjRuqnc6VkX2Xj5d+QW8xZ87pa1UK6yA6ouUyuxfHuMP6umE5QK7UmTeOAymo+Zx1Fxiuw9rVx8taHQ== + node-cache@^5.1.2: version "5.1.2" resolved "https://registry.yarnpkg.com/node-cache/-/node-cache-5.1.2.tgz#f264dc2ccad0a780e76253a694e9fd0ed19c398d" @@ -6379,11 +6421,16 @@ utils-merge@1.0.1: resolved "https://registry.yarnpkg.com/utils-merge/-/utils-merge-1.0.1.tgz#9f95710f50a267947b2ccc124741c1028427e713" integrity sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM= -uuid@^8.0.0, uuid@^8.3.2: +uuid@^8.3.2: version "8.3.2" resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== +uuid@^9.0.0: + version "9.0.0" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-9.0.0.tgz#592f550650024a38ceb0c562f2f6aa435761efb5" + integrity sha512-MXcSTerfPa4uqyzStbRoTgt5XIe3x5+42+q1sDuy3R5MDk66URdLMOZe5aPX/SQd+kuYAh0FdP/pO28IkQyTeg== + v8-compile-cache@^2.0.3: version "2.3.0" resolved "https://registry.yarnpkg.com/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz#2de19618c66dc247dcfb6f99338035d8245a2cee" From e38154c0f10dfe7f5a75be2236b99fbc204443d0 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Thu, 31 Aug 2023 16:56:07 -0400 Subject: [PATCH 25/57] Add check for hg38 before filtering gene hits (#357) --- react/src/components/GeneSearch.tsx | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/react/src/components/GeneSearch.tsx b/react/src/components/GeneSearch.tsx index ab742f2d..42491738 100644 --- a/react/src/components/GeneSearch.tsx +++ b/react/src/components/GeneSearch.tsx @@ -55,9 +55,14 @@ const GeneSearch: React.FC = ({ assembly, geneName, onChange, o const debouncedAutocompleteFetch = useAsyncDebounce(fetchAutocompleteResults, 500); const formatAutocompleteOptions = useCallback( - (autocompleteResults: AutocompleteResults, assembly: AssemblyId) => - (autocompleteResults.autocompleteResults.hits || []) - .filter(hit => !!hit.ensembl && !!hit.genomic_pos && !!hit.genomic_pos_hg19) + (autocompleteResults: AutocompleteResults, assembly: AssemblyId) => { + const is38 = /38/.test(assembly); + const something = (autocompleteResults.autocompleteResults.hits || []) + .filter( + hit => + !!hit.ensembl && + ((is38 && !!hit.genomic_pos) || (!is38 && !!hit.genomic_pos_hg19)) + ) .map((hit, i) => { const { symbol, ...rest } = hit; @@ -71,8 +76,6 @@ const GeneSearch: React.FC = ({ assembly, geneName, onChange, o genomic_pos_hg19, }; - const is38 = /38/.test(assembly); - return (is38 ? genomic_pos : genomic_pos_hg19) .filter(g => isCanonicalRegion(g.chr)) .map((e, eid) => { @@ -88,7 +91,9 @@ const GeneSearch: React.FC = ({ assembly, geneName, onChange, o }; }); }) - .flat(), + .flat(); + return something; + }, [] ); From 27f7adf92a1ca172eb0841526c6e5fff35038b14 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 17 Oct 2023 15:51:52 -0400 Subject: [PATCH 26/57] Bump @babel/traverse from 7.17.3 to 7.23.2 in /react (#360) Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.17.3 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- react/yarn.lock | 149 +++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 134 insertions(+), 15 deletions(-) diff --git a/react/yarn.lock b/react/yarn.lock index 827a78cd..093e50b4 100644 --- a/react/yarn.lock +++ b/react/yarn.lock @@ -50,6 +50,14 @@ dependencies: "@babel/highlight" "^7.16.7" +"@babel/code-frame@^7.22.13": + version "7.22.13" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.22.13.tgz#e3c1c099402598483b7a8c46a721d1038803755e" + integrity sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w== + dependencies: + "@babel/highlight" "^7.22.13" + chalk "^2.4.2" + "@babel/compat-data@^7.13.11", "@babel/compat-data@^7.16.8", "@babel/compat-data@^7.17.0", "@babel/compat-data@^7.17.7": version "7.17.7" resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.17.7.tgz#078d8b833fbbcc95286613be8c716cef2b519fa2" @@ -107,7 +115,7 @@ eslint-visitor-keys "^2.1.0" semver "^6.3.0" -"@babel/generator@^7.12.11", "@babel/generator@^7.12.5", "@babel/generator@^7.17.3", "@babel/generator@^7.17.7", "@babel/generator@^7.7.2": +"@babel/generator@^7.12.11", "@babel/generator@^7.12.5", "@babel/generator@^7.17.7", "@babel/generator@^7.7.2": version "7.17.7" resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.17.7.tgz#8da2599beb4a86194a3b24df6c085931d9ee45ad" integrity sha512-oLcVCTeIFadUoArDTwpluncplrYBmTCCZZgXCbgNGvOBBiSDDK3eWO4b/+eOTli5tKv1lg+a5/NAXg+nTcei1w== @@ -116,6 +124,16 @@ jsesc "^2.5.1" source-map "^0.5.0" +"@babel/generator@^7.23.0": + version "7.23.0" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.23.0.tgz#df5c386e2218be505b34837acbcb874d7a983420" + integrity sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g== + dependencies: + "@babel/types" "^7.23.0" + "@jridgewell/gen-mapping" "^0.3.2" + "@jridgewell/trace-mapping" "^0.3.17" + jsesc "^2.5.1" + "@babel/helper-annotate-as-pure@^7.16.0", "@babel/helper-annotate-as-pure@^7.16.7": version "7.16.7" resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.16.7.tgz#bb2339a7534a9c128e3102024c60760a3a7f3862" @@ -197,6 +215,11 @@ dependencies: "@babel/types" "^7.16.7" +"@babel/helper-environment-visitor@^7.22.20": + version "7.22.20" + resolved "https://registry.yarnpkg.com/@babel/helper-environment-visitor/-/helper-environment-visitor-7.22.20.tgz#96159db61d34a29dba454c959f5ae4a649ba9167" + integrity sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA== + "@babel/helper-explode-assignable-expression@^7.16.7": version "7.16.7" resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.16.7.tgz#12a6d8522fdd834f194e868af6354e8650242b7a" @@ -213,6 +236,14 @@ "@babel/template" "^7.16.7" "@babel/types" "^7.16.7" +"@babel/helper-function-name@^7.23.0": + version "7.23.0" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.23.0.tgz#1f9a3cdbd5b2698a670c30d2735f9af95ed52759" + integrity sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw== + dependencies: + "@babel/template" "^7.22.15" + "@babel/types" "^7.23.0" + "@babel/helper-get-function-arity@^7.16.7": version "7.16.7" resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.16.7.tgz#ea08ac753117a669f1508ba06ebcc49156387419" @@ -227,6 +258,13 @@ dependencies: "@babel/types" "^7.16.7" +"@babel/helper-hoist-variables@^7.22.5": + version "7.22.5" + resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.22.5.tgz#c01a007dac05c085914e8fb652b339db50d823bb" + integrity sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw== + dependencies: + "@babel/types" "^7.22.5" + "@babel/helper-member-expression-to-functions@^7.16.7": version "7.17.7" resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.17.7.tgz#a34013b57d8542a8c4ff8ba3f747c02452a4d8c4" @@ -313,11 +351,28 @@ dependencies: "@babel/types" "^7.16.7" +"@babel/helper-split-export-declaration@^7.22.6": + version "7.22.6" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.22.6.tgz#322c61b7310c0997fe4c323955667f18fcefb91c" + integrity sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g== + dependencies: + "@babel/types" "^7.22.5" + +"@babel/helper-string-parser@^7.22.5": + version "7.22.5" + resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.22.5.tgz#533f36457a25814cf1df6488523ad547d784a99f" + integrity sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw== + "@babel/helper-validator-identifier@^7.16.7": version "7.16.7" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.16.7.tgz#e8c602438c4a8195751243da9031d1607d247cad" integrity sha512-hsEnFemeiW4D08A5gUAZxLBTXpZ39P+a+DGDsHw1yxqyQ/jzFEnxf5uTEGp+3bzAbNOxU1paTgYS4ECU/IgfDw== +"@babel/helper-validator-identifier@^7.22.20": + version "7.22.20" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz#c4ae002c61d2879e724581d96665583dbc1dc0e0" + integrity sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A== + "@babel/helper-validator-option@^7.16.7": version "7.16.7" resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.16.7.tgz#b203ce62ce5fe153899b617c08957de860de4d23" @@ -351,11 +406,25 @@ chalk "^2.0.0" js-tokens "^4.0.0" -"@babel/parser@^7.1.0", "@babel/parser@^7.12.11", "@babel/parser@^7.12.7", "@babel/parser@^7.14.7", "@babel/parser@^7.16.7", "@babel/parser@^7.17.3", "@babel/parser@^7.17.8": +"@babel/highlight@^7.22.13": + version "7.22.20" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.22.20.tgz#4ca92b71d80554b01427815e06f2df965b9c1f54" + integrity sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg== + dependencies: + "@babel/helper-validator-identifier" "^7.22.20" + chalk "^2.4.2" + js-tokens "^4.0.0" + +"@babel/parser@^7.1.0", "@babel/parser@^7.12.11", "@babel/parser@^7.12.7", "@babel/parser@^7.14.7", "@babel/parser@^7.16.7", "@babel/parser@^7.17.8": version "7.17.8" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.17.8.tgz#2817fb9d885dd8132ea0f8eb615a6388cca1c240" integrity sha512-BoHhDJrJXqcg+ZL16Xv39H9n+AqJ4pcDrQBGZN+wHxIysrLZ3/ECwCBUch/1zUNhnsXULcONU3Ei5Hmkfk6kiQ== +"@babel/parser@^7.22.15", "@babel/parser@^7.23.0": + version "7.23.0" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.23.0.tgz#da950e622420bf96ca0d0f2909cdddac3acd8719" + integrity sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw== + "@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@^7.16.7": version "7.16.7" resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression/-/plugin-bugfix-safari-id-destructuring-collision-in-function-expression-7.16.7.tgz#4eda6d6c2a0aa79c70fa7b6da67763dfe2141050" @@ -1157,19 +1226,28 @@ "@babel/parser" "^7.16.7" "@babel/types" "^7.16.7" -"@babel/traverse@^7.1.6", "@babel/traverse@^7.12.11", "@babel/traverse@^7.12.9", "@babel/traverse@^7.13.0", "@babel/traverse@^7.16.7", "@babel/traverse@^7.16.8", "@babel/traverse@^7.17.3", "@babel/traverse@^7.4.5", "@babel/traverse@^7.7.2": - version "7.17.3" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.17.3.tgz#0ae0f15b27d9a92ba1f2263358ea7c4e7db47b57" - integrity sha512-5irClVky7TxRWIRtxlh2WPUUOLhcPN06AGgaQSB8AEwuyEBgJVuJ5imdHm5zxk8w0QS5T+tDfnDxAlhWjpb7cw== +"@babel/template@^7.22.15": + version "7.22.15" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.22.15.tgz#09576efc3830f0430f4548ef971dde1350ef2f38" + integrity sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w== dependencies: - "@babel/code-frame" "^7.16.7" - "@babel/generator" "^7.17.3" - "@babel/helper-environment-visitor" "^7.16.7" - "@babel/helper-function-name" "^7.16.7" - "@babel/helper-hoist-variables" "^7.16.7" - "@babel/helper-split-export-declaration" "^7.16.7" - "@babel/parser" "^7.17.3" - "@babel/types" "^7.17.0" + "@babel/code-frame" "^7.22.13" + "@babel/parser" "^7.22.15" + "@babel/types" "^7.22.15" + +"@babel/traverse@^7.1.6", "@babel/traverse@^7.12.11", "@babel/traverse@^7.12.9", "@babel/traverse@^7.13.0", "@babel/traverse@^7.16.7", "@babel/traverse@^7.16.8", "@babel/traverse@^7.17.3", "@babel/traverse@^7.4.5", "@babel/traverse@^7.7.2": + version "7.23.2" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.23.2.tgz#329c7a06735e144a506bdb2cad0268b7f46f4ad8" + integrity sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw== + dependencies: + "@babel/code-frame" "^7.22.13" + "@babel/generator" "^7.23.0" + "@babel/helper-environment-visitor" "^7.22.20" + "@babel/helper-function-name" "^7.23.0" + "@babel/helper-hoist-variables" "^7.22.5" + "@babel/helper-split-export-declaration" "^7.22.6" + "@babel/parser" "^7.23.0" + "@babel/types" "^7.23.0" debug "^4.1.0" globals "^11.1.0" @@ -1181,6 +1259,15 @@ "@babel/helper-validator-identifier" "^7.16.7" to-fast-properties "^2.0.0" +"@babel/types@^7.22.15", "@babel/types@^7.22.5", "@babel/types@^7.23.0": + version "7.23.0" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.23.0.tgz#8c1f020c9df0e737e4e247c0619f58c68458aaeb" + integrity sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg== + dependencies: + "@babel/helper-string-parser" "^7.22.5" + "@babel/helper-validator-identifier" "^7.22.20" + to-fast-properties "^2.0.0" + "@base2/pretty-print-object@1.0.1": version "1.0.1" resolved "https://registry.yarnpkg.com/@base2/pretty-print-object/-/pretty-print-object-1.0.1.tgz#371ba8be66d556812dc7fb169ebc3c08378f69d4" @@ -1626,16 +1713,40 @@ "@types/yargs" "^16.0.0" chalk "^4.0.0" +"@jridgewell/gen-mapping@^0.3.2": + version "0.3.3" + resolved "https://registry.yarnpkg.com/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz#7e02e6eb5df901aaedb08514203b096614024098" + integrity sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ== + dependencies: + "@jridgewell/set-array" "^1.0.1" + "@jridgewell/sourcemap-codec" "^1.4.10" + "@jridgewell/trace-mapping" "^0.3.9" + "@jridgewell/resolve-uri@^3.0.3": version "3.0.5" resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.0.5.tgz#68eb521368db76d040a6315cdb24bf2483037b9c" integrity sha512-VPeQ7+wH0itvQxnG+lIzWgkysKIr3L9sslimFW55rHMdGu/qCQ5z5h9zq4gI8uBtqkpHhsF4Z/OwExufUCThew== +"@jridgewell/resolve-uri@^3.1.0": + version "3.1.1" + resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.1.tgz#c08679063f279615a3326583ba3a90d1d82cc721" + integrity sha512-dSYZh7HhCDtCKm4QakX0xFpsRDqjjtZf/kjI/v3T3Nwt5r8/qz/M19F9ySyOqU94SXBmeG9ttTul+YnR4LOxFA== + +"@jridgewell/set-array@^1.0.1": + version "1.1.2" + resolved "https://registry.yarnpkg.com/@jridgewell/set-array/-/set-array-1.1.2.tgz#7c6cf998d6d20b914c0a55a91ae928ff25965e72" + integrity sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw== + "@jridgewell/sourcemap-codec@^1.4.10": version "1.4.11" resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.11.tgz#771a1d8d744eeb71b6adb35808e1a6c7b9b8c8ec" integrity sha512-Fg32GrJo61m+VqYSdRSjRXMjQ06j8YIYfcTqndLYVAaHmroZHLJZCydsWBOTDqXS2v+mjxohBWEMfg97GXmYQg== +"@jridgewell/sourcemap-codec@^1.4.14": + version "1.4.15" + resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.15.tgz#d7c6e6755c78567a951e04ab52ef0fd26de59f32" + integrity sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg== + "@jridgewell/trace-mapping@^0.3.0": version "0.3.4" resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.4.tgz#f6a0832dffd5b8a6aaa633b7d9f8e8e94c83a0c3" @@ -1644,6 +1755,14 @@ "@jridgewell/resolve-uri" "^3.0.3" "@jridgewell/sourcemap-codec" "^1.4.10" +"@jridgewell/trace-mapping@^0.3.17", "@jridgewell/trace-mapping@^0.3.9": + version "0.3.19" + resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.19.tgz#f8a3249862f91be48d3127c3cfe992f79b4b8811" + integrity sha512-kf37QtfW+Hwx/buWGMPcR60iF9ziHa6r/CZJIHbmcm4+0qrXiVdxegAH0F6yddEVQ7zdkjcGCgCzUu+BcbhQxw== + dependencies: + "@jridgewell/resolve-uri" "^3.1.0" + "@jridgewell/sourcemap-codec" "^1.4.14" + "@mdx-js/loader@^1.6.22": version "1.6.22" resolved "https://registry.yarnpkg.com/@mdx-js/loader/-/loader-1.6.22.tgz#d9e8fe7f8185ff13c9c8639c048b123e30d322c4" @@ -5035,7 +5154,7 @@ ccount@^1.0.0: resolved "https://registry.yarnpkg.com/ccount/-/ccount-1.1.0.tgz#246687debb6014735131be8abab2d93898f8d043" integrity sha512-vlNK021QdI7PNeiUh/lKkC/mNHHfV0m/Ad5JoI0TYtlBnJAslM/JIkm/tGC88bkLIwO6OQ5uV6ztS6kVAtCDlg== -chalk@^2.0.0, chalk@^2.4.1: +chalk@^2.0.0, chalk@^2.4.1, chalk@^2.4.2: version "2.4.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== From 66401bfca8b9f15e6ff1607cd6ef4f92825fdb7f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 17 Oct 2023 16:05:40 -0400 Subject: [PATCH 27/57] Bump graphql from 16.3.0 to 16.8.1 in /server (#358) * Bump graphql from 16.3.0 to 16.8.1 in /server Bumps [graphql](https://github.com/graphql/graphql-js) from 16.3.0 to 16.8.1. - [Release notes](https://github.com/graphql/graphql-js/releases) - [Commits](https://github.com/graphql/graphql-js/compare/v16.3.0...v16.8.1) --- updated-dependencies: - dependency-name: graphql dependency-type: direct:production ... Signed-off-by: dependabot[bot] * Bump @babel/traverse from 7.17.3 to 7.23.2 in /react (#360) Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.17.3 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Bump graphql from 16.3.0 to 16.8.1 in /server Bumps [graphql](https://github.com/graphql/graphql-js) from 16.3.0 to 16.8.1. - [Release notes](https://github.com/graphql/graphql-js/releases) - [Commits](https://github.com/graphql/graphql-js/compare/v16.3.0...v16.8.1) --- updated-dependencies: - dependency-name: graphql dependency-type: direct:production ... Signed-off-by: dependabot[bot] --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Mackenzie Ian Frew --- server/package.json | 2 +- server/yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/server/package.json b/server/package.json index 3eab8525..4470c258 100644 --- a/server/package.json +++ b/server/package.json @@ -23,7 +23,7 @@ "express": "^4.17.1", "express-session": "^1.17.2", "generic-filehandle": "^2.2.2", - "graphql": "^16.3.0", + "graphql": "^16.8.1", "jwt-decode": "^3.1.2", "keycloak-connect": "21.0.1", "memorystore": "^1.6.7", diff --git a/server/yarn.lock b/server/yarn.lock index 413930dd..62200d21 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -3963,10 +3963,10 @@ graphql-ws@^5.4.1: resolved "https://registry.yarnpkg.com/graphql-ws/-/graphql-ws-5.7.0.tgz#4b9d7a0ee9555804582f27f5d7695d10aafdbdc8" integrity sha512-8yYuvnyqIjlJ/WfebOyu2GSOQeFauRxnfuTveY9yvrDGs2g3kR9Nv4gu40AKvRHbXlSJwTbMJ6dVxAtEyKwVRA== -graphql@^16.3.0: - version "16.3.0" - resolved "https://registry.yarnpkg.com/graphql/-/graphql-16.3.0.tgz#a91e24d10babf9e60c706919bb182b53ccdffc05" - integrity sha512-xm+ANmA16BzCT5pLjuXySbQVFwH3oJctUVdy81w1sV0vBU0KgDdBGtxQOUd5zqOBk/JayAFeG8Dlmeq74rjm/A== +graphql@^16.8.1: + version "16.8.1" + resolved "https://registry.yarnpkg.com/graphql/-/graphql-16.8.1.tgz#1930a965bef1170603702acdb68aedd3f3cf6f07" + integrity sha512-59LZHPdGZVh695Ud9lRzPBVTtlX9ZCV150Er2W43ro37wVof0ctenSaskPPjN7lVTIN8mSZt8PHUNKZuNQUuxw== has-bigints@^1.0.1: version "1.0.1" From 0a6086e8ec6bc4acf9144786f5fe177ac103540a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 17 Oct 2023 16:23:10 -0400 Subject: [PATCH 28/57] Bump undici from 5.19.1 to 5.26.3 in /server (#359) * Bump undici from 5.19.1 to 5.26.3 in /server Bumps [undici](https://github.com/nodejs/undici) from 5.19.1 to 5.26.3. - [Release notes](https://github.com/nodejs/undici/releases) - [Commits](https://github.com/nodejs/undici/compare/v5.19.1...v5.26.3) --- updated-dependencies: - dependency-name: undici dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump @babel/traverse from 7.17.3 to 7.23.2 in /react (#360) Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.17.3 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Bump graphql from 16.3.0 to 16.8.1 in /server (#358) * Bump graphql from 16.3.0 to 16.8.1 in /server Bumps [graphql](https://github.com/graphql/graphql-js) from 16.3.0 to 16.8.1. - [Release notes](https://github.com/graphql/graphql-js/releases) - [Commits](https://github.com/graphql/graphql-js/compare/v16.3.0...v16.8.1) --- updated-dependencies: - dependency-name: graphql dependency-type: direct:production ... Signed-off-by: dependabot[bot] * Bump @babel/traverse from 7.17.3 to 7.23.2 in /react (#360) Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.17.3 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Bump graphql from 16.3.0 to 16.8.1 in /server Bumps [graphql](https://github.com/graphql/graphql-js) from 16.3.0 to 16.8.1. - [Release notes](https://github.com/graphql/graphql-js/releases) - [Commits](https://github.com/graphql/graphql-js/compare/v16.3.0...v16.8.1) --- updated-dependencies: - dependency-name: graphql dependency-type: direct:production ... Signed-off-by: dependabot[bot] --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Mackenzie Ian Frew * Bump undici from 5.19.1 to 5.26.3 in /server Bumps [undici](https://github.com/nodejs/undici) from 5.19.1 to 5.26.3. - [Release notes](https://github.com/nodejs/undici/releases) - [Commits](https://github.com/nodejs/undici/compare/v5.19.1...v5.26.3) --- updated-dependencies: - dependency-name: undici dependency-type: indirect ... Signed-off-by: dependabot[bot] --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Mackenzie Ian Frew --- server/yarn.lock | 25 +++++++++---------------- 1 file changed, 9 insertions(+), 16 deletions(-) diff --git a/server/yarn.lock b/server/yarn.lock index 62200d21..e188f67c 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -878,6 +878,11 @@ minimatch "^3.0.4" strip-json-comments "^3.1.1" +"@fastify/busboy@^2.0.0": + version "2.0.0" + resolved "https://registry.yarnpkg.com/@fastify/busboy/-/busboy-2.0.0.tgz#f22824caff3ae506b18207bad4126dbc6ccdb6b8" + integrity sha512-JUFJad5lv7jxj926GPgymrWQxxjPYuJNiNjNMzqT+HiuP6Vl3dk5xzG+8sTX96np0ZAluvaMzPsjhHZ5rNuNQQ== + "@gmod/bgzf-filehandle@^1.3.3": version "1.4.4" resolved "https://registry.yarnpkg.com/@gmod/bgzf-filehandle/-/bgzf-filehandle-1.4.4.tgz#dd7e8169c039a93a719d927ed0692a0f2ddf265e" @@ -2689,13 +2694,6 @@ buffer@^5.6.0, buffer@^5.7.0: base64-js "^1.3.1" ieee754 "^1.1.13" -busboy@^1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/busboy/-/busboy-1.6.0.tgz#966ea36a9502e43cdb9146962523b92f531f6893" - integrity sha512-8SFQbg/0hQ9xy3UNTB0YEnsNBbWfhf7RtnzpL7TkBiTBRfrQ9Fxcnz7VJsleJpyp6rVLvXiuORqjlHi5q+PYuA== - dependencies: - streamsearch "^1.1.0" - bytes@3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/bytes/-/bytes-3.1.2.tgz#8b0beeb98605adf1b128fa4386403c009e0221a5" @@ -5966,11 +5964,6 @@ statuses@2.0.1: resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.5.0.tgz#161c7dac177659fd9811f43771fa99381478628c" integrity sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow= -streamsearch@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/streamsearch/-/streamsearch-1.1.0.tgz#404dd1e2247ca94af554e841a8ef0eaa238da764" - integrity sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg== - string-env-interpolation@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/string-env-interpolation/-/string-env-interpolation-1.0.1.tgz#ad4397ae4ac53fe6c91d1402ad6f6a52862c7152" @@ -6373,11 +6366,11 @@ unbox-primitive@^1.0.1: which-boxed-primitive "^1.0.2" undici@^5.0.0: - version "5.19.1" - resolved "https://registry.yarnpkg.com/undici/-/undici-5.19.1.tgz#92b1fd3ab2c089b5a6bd3e579dcda8f1934ebf6d" - integrity sha512-YiZ61LPIgY73E7syxCDxxa3LV2yl3sN8spnIuTct60boiiRaE1J8mNWHO8Im2Zi/sFrPusjLlmRPrsyraSqX6A== + version "5.26.3" + resolved "https://registry.yarnpkg.com/undici/-/undici-5.26.3.tgz#ab3527b3d5bb25b12f898dfd22165d472dd71b79" + integrity sha512-H7n2zmKEWgOllKkIUkLvFmsJQj062lSm3uA4EYApG8gLuiOM0/go9bIoC3HVaSnfg4xunowDE2i9p8drkXuvDw== dependencies: - busboy "^1.6.0" + "@fastify/busboy" "^2.0.0" universalify@^0.2.0: version "0.2.0" From 25ea9e6d013f1b6e85c594bf0f79781860ca4692 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 17 Oct 2023 16:36:32 -0400 Subject: [PATCH 29/57] Bump @babel/traverse from 7.17.9 to 7.23.2 in /server (#361) * Bump @babel/traverse from 7.17.9 to 7.23.2 in /server Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.17.9 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump graphql from 16.3.0 to 16.8.1 in /server (#358) * Bump graphql from 16.3.0 to 16.8.1 in /server Bumps [graphql](https://github.com/graphql/graphql-js) from 16.3.0 to 16.8.1. - [Release notes](https://github.com/graphql/graphql-js/releases) - [Commits](https://github.com/graphql/graphql-js/compare/v16.3.0...v16.8.1) --- updated-dependencies: - dependency-name: graphql dependency-type: direct:production ... Signed-off-by: dependabot[bot] * Bump @babel/traverse from 7.17.3 to 7.23.2 in /react (#360) Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.17.3 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Bump graphql from 16.3.0 to 16.8.1 in /server Bumps [graphql](https://github.com/graphql/graphql-js) from 16.3.0 to 16.8.1. - [Release notes](https://github.com/graphql/graphql-js/releases) - [Commits](https://github.com/graphql/graphql-js/compare/v16.3.0...v16.8.1) --- updated-dependencies: - dependency-name: graphql dependency-type: direct:production ... Signed-off-by: dependabot[bot] --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Mackenzie Ian Frew * Bump undici from 5.19.1 to 5.26.3 in /server (#359) * Bump undici from 5.19.1 to 5.26.3 in /server Bumps [undici](https://github.com/nodejs/undici) from 5.19.1 to 5.26.3. - [Release notes](https://github.com/nodejs/undici/releases) - [Commits](https://github.com/nodejs/undici/compare/v5.19.1...v5.26.3) --- updated-dependencies: - dependency-name: undici dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump @babel/traverse from 7.17.3 to 7.23.2 in /react (#360) Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.17.3 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Bump graphql from 16.3.0 to 16.8.1 in /server (#358) * Bump graphql from 16.3.0 to 16.8.1 in /server Bumps [graphql](https://github.com/graphql/graphql-js) from 16.3.0 to 16.8.1. - [Release notes](https://github.com/graphql/graphql-js/releases) - [Commits](https://github.com/graphql/graphql-js/compare/v16.3.0...v16.8.1) --- updated-dependencies: - dependency-name: graphql dependency-type: direct:production ... Signed-off-by: dependabot[bot] * Bump @babel/traverse from 7.17.3 to 7.23.2 in /react (#360) Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.17.3 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Bump graphql from 16.3.0 to 16.8.1 in /server Bumps [graphql](https://github.com/graphql/graphql-js) from 16.3.0 to 16.8.1. - [Release notes](https://github.com/graphql/graphql-js/releases) - [Commits](https://github.com/graphql/graphql-js/compare/v16.3.0...v16.8.1) --- updated-dependencies: - dependency-name: graphql dependency-type: direct:production ... Signed-off-by: dependabot[bot] --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Mackenzie Ian Frew * Bump undici from 5.19.1 to 5.26.3 in /server Bumps [undici](https://github.com/nodejs/undici) from 5.19.1 to 5.26.3. - [Release notes](https://github.com/nodejs/undici/releases) - [Commits](https://github.com/nodejs/undici/compare/v5.19.1...v5.26.3) --- updated-dependencies: - dependency-name: undici dependency-type: indirect ... Signed-off-by: dependabot[bot] --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Mackenzie Ian Frew * Bump @babel/traverse from 7.17.9 to 7.23.2 in /server Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.17.9 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Mackenzie Ian Frew --- server/yarn.lock | 152 +++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 128 insertions(+), 24 deletions(-) diff --git a/server/yarn.lock b/server/yarn.lock index e188f67c..bbe224ba 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -570,6 +570,14 @@ dependencies: "@babel/highlight" "^7.16.7" +"@babel/code-frame@^7.22.13": + version "7.22.13" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.22.13.tgz#e3c1c099402598483b7a8c46a721d1038803755e" + integrity sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w== + dependencies: + "@babel/highlight" "^7.22.13" + chalk "^2.4.2" + "@babel/compat-data@^7.17.7": version "7.17.7" resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.17.7.tgz#078d8b833fbbcc95286613be8c716cef2b519fa2" @@ -605,6 +613,16 @@ jsesc "^2.5.1" source-map "^0.5.0" +"@babel/generator@^7.23.0": + version "7.23.0" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.23.0.tgz#df5c386e2218be505b34837acbcb874d7a983420" + integrity sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g== + dependencies: + "@babel/types" "^7.23.0" + "@jridgewell/gen-mapping" "^0.3.2" + "@jridgewell/trace-mapping" "^0.3.17" + jsesc "^2.5.1" + "@babel/helper-compilation-targets@^7.17.7": version "7.17.7" resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.17.7.tgz#a3c2924f5e5f0379b356d4cfb313d1414dc30e46" @@ -622,20 +640,25 @@ dependencies: "@babel/types" "^7.16.7" -"@babel/helper-function-name@^7.17.9": - version "7.17.9" - resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.17.9.tgz#136fcd54bc1da82fcb47565cf16fd8e444b1ff12" - integrity sha512-7cRisGlVtiVqZ0MW0/yFB4atgpGLWEHUVYnb448hZK4x+vih0YO5UoS11XIYtZYqHd0dIPMdUSv8q5K4LdMnIg== +"@babel/helper-environment-visitor@^7.22.20": + version "7.22.20" + resolved "https://registry.yarnpkg.com/@babel/helper-environment-visitor/-/helper-environment-visitor-7.22.20.tgz#96159db61d34a29dba454c959f5ae4a649ba9167" + integrity sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA== + +"@babel/helper-function-name@^7.23.0": + version "7.23.0" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.23.0.tgz#1f9a3cdbd5b2698a670c30d2735f9af95ed52759" + integrity sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw== dependencies: - "@babel/template" "^7.16.7" - "@babel/types" "^7.17.0" + "@babel/template" "^7.22.15" + "@babel/types" "^7.23.0" -"@babel/helper-hoist-variables@^7.16.7": - version "7.16.7" - resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.16.7.tgz#86bcb19a77a509c7b77d0e22323ef588fa58c246" - integrity sha512-m04d/0Op34H5v7pbZw6pSKP7weA6lsMvfiIAMeIvkY/R4xQtBSMFEigu9QTZ2qB/9l22vsxtM8a+Q8CzD255fg== +"@babel/helper-hoist-variables@^7.22.5": + version "7.22.5" + resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.22.5.tgz#c01a007dac05c085914e8fb652b339db50d823bb" + integrity sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw== dependencies: - "@babel/types" "^7.16.7" + "@babel/types" "^7.22.5" "@babel/helper-module-imports@^7.16.7": version "7.16.7" @@ -677,11 +700,28 @@ dependencies: "@babel/types" "^7.16.7" +"@babel/helper-split-export-declaration@^7.22.6": + version "7.22.6" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.22.6.tgz#322c61b7310c0997fe4c323955667f18fcefb91c" + integrity sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g== + dependencies: + "@babel/types" "^7.22.5" + +"@babel/helper-string-parser@^7.22.5": + version "7.22.5" + resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.22.5.tgz#533f36457a25814cf1df6488523ad547d784a99f" + integrity sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw== + "@babel/helper-validator-identifier@^7.16.7": version "7.16.7" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.16.7.tgz#e8c602438c4a8195751243da9031d1607d247cad" integrity sha512-hsEnFemeiW4D08A5gUAZxLBTXpZ39P+a+DGDsHw1yxqyQ/jzFEnxf5uTEGp+3bzAbNOxU1paTgYS4ECU/IgfDw== +"@babel/helper-validator-identifier@^7.22.20": + version "7.22.20" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz#c4ae002c61d2879e724581d96665583dbc1dc0e0" + integrity sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A== + "@babel/helper-validator-option@^7.16.7": version "7.16.7" resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.16.7.tgz#b203ce62ce5fe153899b617c08957de860de4d23" @@ -705,11 +745,25 @@ chalk "^2.0.0" js-tokens "^4.0.0" +"@babel/highlight@^7.22.13": + version "7.22.20" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.22.20.tgz#4ca92b71d80554b01427815e06f2df965b9c1f54" + integrity sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg== + dependencies: + "@babel/helper-validator-identifier" "^7.22.20" + chalk "^2.4.2" + js-tokens "^4.0.0" + "@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.16.7", "@babel/parser@^7.16.8", "@babel/parser@^7.17.9": version "7.17.9" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.17.9.tgz#9c94189a6062f0291418ca021077983058e171ef" integrity sha512-vqUSBLP8dQHFPdPi9bc5GK9vRkYHJ49fsZdtoJ8EQ8ibpwk5rPKfvNIwChB0KVXcIjcepEBBd2VHC5r9Gy8ueg== +"@babel/parser@^7.22.15", "@babel/parser@^7.23.0": + version "7.23.0" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.23.0.tgz#da950e622420bf96ca0d0f2909cdddac3acd8719" + integrity sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw== + "@babel/plugin-syntax-async-generators@^7.8.4": version "7.8.4" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz#a983fb1aeb2ec3f6ed042a210f640e90e786fe0d" @@ -810,19 +864,28 @@ "@babel/parser" "^7.16.7" "@babel/types" "^7.16.7" -"@babel/traverse@^7.16.8", "@babel/traverse@^7.17.3", "@babel/traverse@^7.17.9", "@babel/traverse@^7.7.2": - version "7.17.9" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.17.9.tgz#1f9b207435d9ae4a8ed6998b2b82300d83c37a0d" - integrity sha512-PQO8sDIJ8SIwipTPiR71kJQCKQYB5NGImbOviK8K+kg5xkNSYXLBupuX9QhatFowrsvo9Hj8WgArg3W7ijNAQw== +"@babel/template@^7.22.15": + version "7.22.15" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.22.15.tgz#09576efc3830f0430f4548ef971dde1350ef2f38" + integrity sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w== dependencies: - "@babel/code-frame" "^7.16.7" - "@babel/generator" "^7.17.9" - "@babel/helper-environment-visitor" "^7.16.7" - "@babel/helper-function-name" "^7.17.9" - "@babel/helper-hoist-variables" "^7.16.7" - "@babel/helper-split-export-declaration" "^7.16.7" - "@babel/parser" "^7.17.9" - "@babel/types" "^7.17.0" + "@babel/code-frame" "^7.22.13" + "@babel/parser" "^7.22.15" + "@babel/types" "^7.22.15" + +"@babel/traverse@^7.16.8", "@babel/traverse@^7.17.3", "@babel/traverse@^7.17.9", "@babel/traverse@^7.7.2": + version "7.23.2" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.23.2.tgz#329c7a06735e144a506bdb2cad0268b7f46f4ad8" + integrity sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw== + dependencies: + "@babel/code-frame" "^7.22.13" + "@babel/generator" "^7.23.0" + "@babel/helper-environment-visitor" "^7.22.20" + "@babel/helper-function-name" "^7.23.0" + "@babel/helper-hoist-variables" "^7.22.5" + "@babel/helper-split-export-declaration" "^7.22.6" + "@babel/parser" "^7.23.0" + "@babel/types" "^7.23.0" debug "^4.1.0" globals "^11.1.0" @@ -834,6 +897,15 @@ "@babel/helper-validator-identifier" "^7.16.7" to-fast-properties "^2.0.0" +"@babel/types@^7.22.15", "@babel/types@^7.22.5", "@babel/types@^7.23.0": + version "7.23.0" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.23.0.tgz#8c1f020c9df0e737e4e247c0619f58c68458aaeb" + integrity sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg== + dependencies: + "@babel/helper-string-parser" "^7.22.5" + "@babel/helper-validator-identifier" "^7.22.20" + to-fast-properties "^2.0.0" + "@bcoe/v8-coverage@^0.2.3": version "0.2.3" resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" @@ -1335,16 +1407,40 @@ resolved "https://registry.yarnpkg.com/@josephg/resolvable/-/resolvable-1.0.1.tgz#69bc4db754d79e1a2f17a650d3466e038d94a5eb" integrity sha512-CtzORUwWTTOTqfVtHaKRJ0I1kNQd1bpn3sUh8I3nJDVY+5/M/Oe1DnEWzPQvqq/xPIIkzzzIP7mfCoAjFRvDhg== +"@jridgewell/gen-mapping@^0.3.2": + version "0.3.3" + resolved "https://registry.yarnpkg.com/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz#7e02e6eb5df901aaedb08514203b096614024098" + integrity sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ== + dependencies: + "@jridgewell/set-array" "^1.0.1" + "@jridgewell/sourcemap-codec" "^1.4.10" + "@jridgewell/trace-mapping" "^0.3.9" + "@jridgewell/resolve-uri@^3.0.3": version "3.0.5" resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.0.5.tgz#68eb521368db76d040a6315cdb24bf2483037b9c" integrity sha512-VPeQ7+wH0itvQxnG+lIzWgkysKIr3L9sslimFW55rHMdGu/qCQ5z5h9zq4gI8uBtqkpHhsF4Z/OwExufUCThew== +"@jridgewell/resolve-uri@^3.1.0": + version "3.1.1" + resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.1.tgz#c08679063f279615a3326583ba3a90d1d82cc721" + integrity sha512-dSYZh7HhCDtCKm4QakX0xFpsRDqjjtZf/kjI/v3T3Nwt5r8/qz/M19F9ySyOqU94SXBmeG9ttTul+YnR4LOxFA== + +"@jridgewell/set-array@^1.0.1": + version "1.1.2" + resolved "https://registry.yarnpkg.com/@jridgewell/set-array/-/set-array-1.1.2.tgz#7c6cf998d6d20b914c0a55a91ae928ff25965e72" + integrity sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw== + "@jridgewell/sourcemap-codec@^1.4.10": version "1.4.11" resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.11.tgz#771a1d8d744eeb71b6adb35808e1a6c7b9b8c8ec" integrity sha512-Fg32GrJo61m+VqYSdRSjRXMjQ06j8YIYfcTqndLYVAaHmroZHLJZCydsWBOTDqXS2v+mjxohBWEMfg97GXmYQg== +"@jridgewell/sourcemap-codec@^1.4.14": + version "1.4.15" + resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.15.tgz#d7c6e6755c78567a951e04ab52ef0fd26de59f32" + integrity sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg== + "@jridgewell/trace-mapping@^0.3.0": version "0.3.4" resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.4.tgz#f6a0832dffd5b8a6aaa633b7d9f8e8e94c83a0c3" @@ -1353,6 +1449,14 @@ "@jridgewell/resolve-uri" "^3.0.3" "@jridgewell/sourcemap-codec" "^1.4.10" +"@jridgewell/trace-mapping@^0.3.17", "@jridgewell/trace-mapping@^0.3.9": + version "0.3.19" + resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.19.tgz#f8a3249862f91be48d3127c3cfe992f79b4b8811" + integrity sha512-kf37QtfW+Hwx/buWGMPcR60iF9ziHa6r/CZJIHbmcm4+0qrXiVdxegAH0F6yddEVQ7zdkjcGCgCzUu+BcbhQxw== + dependencies: + "@jridgewell/resolve-uri" "^3.1.0" + "@jridgewell/sourcemap-codec" "^1.4.14" + "@n1ru4l/graphql-live-query@^0.9.0": version "0.9.0" resolved "https://registry.yarnpkg.com/@n1ru4l/graphql-live-query/-/graphql-live-query-0.9.0.tgz#defaebdd31f625bee49e6745934f36312532b2bc" @@ -2735,7 +2839,7 @@ chalk@4.1.2, chalk@^4.0.0: ansi-styles "^4.1.0" supports-color "^7.1.0" -chalk@^2.0.0: +chalk@^2.0.0, chalk@^2.4.2: version "2.4.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== From 322c53a13c1fb7deb38f2d02d6dfa602b8f533b5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Nov 2023 14:47:28 -0500 Subject: [PATCH 30/57] Bump browserify-sign from 4.2.1 to 4.2.2 in /react (#363) Bumps [browserify-sign](https://github.com/crypto-browserify/browserify-sign) from 4.2.1 to 4.2.2. - [Changelog](https://github.com/browserify/browserify-sign/blob/main/CHANGELOG.md) - [Commits](https://github.com/crypto-browserify/browserify-sign/compare/v4.2.1...v4.2.2) --- updated-dependencies: - dependency-name: browserify-sign dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- react/yarn.lock | 42 ++++++++++++++++++++++++++++-------------- 1 file changed, 28 insertions(+), 14 deletions(-) diff --git a/react/yarn.lock b/react/yarn.lock index 093e50b4..e6fc254b 100644 --- a/react/yarn.lock +++ b/react/yarn.lock @@ -4775,11 +4775,16 @@ bn.js@^4.0.0, bn.js@^4.1.0, bn.js@^4.11.9: resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.12.0.tgz#775b3f278efbb9718eec7361f483fb36fbbfea88" integrity sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA== -bn.js@^5.0.0, bn.js@^5.1.1: +bn.js@^5.0.0: version "5.2.0" resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-5.2.0.tgz#358860674396c6997771a9d051fcc1b57d4ae002" integrity sha512-D7iWRBvnZE8ecXiLj/9wbxH7Tk79fAh8IHaTNq1RWRixsS02W+5qS+iE9yq6RYl0asXx5tw0bLhmT5pIfbSquw== +bn.js@^5.2.1: + version "5.2.1" + resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-5.2.1.tgz#0bc527a6a0d18d0aa8d5b0538ce4a77dccfa7b70" + integrity sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ== + body-parser@1.19.2: version "1.19.2" resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.19.2.tgz#4714ccd9c157d44797b8b5607d72c0b89952f26e" @@ -4906,7 +4911,7 @@ browserify-des@^1.0.0: inherits "^2.0.1" safe-buffer "^5.1.2" -browserify-rsa@^4.0.0, browserify-rsa@^4.0.1: +browserify-rsa@^4.0.0, browserify-rsa@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/browserify-rsa/-/browserify-rsa-4.1.0.tgz#b2fd06b5b75ae297f7ce2dc651f918f5be158c8d" integrity sha512-AdEER0Hkspgno2aR97SAf6vi0y0k8NuOpGnVH3O99rcA5Q6sh8QxcngtHuJ6uXwnfAXNM4Gn1Gb7/MV1+Ymbog== @@ -4915,19 +4920,19 @@ browserify-rsa@^4.0.0, browserify-rsa@^4.0.1: randombytes "^2.0.1" browserify-sign@^4.0.0: - version "4.2.1" - resolved "https://registry.yarnpkg.com/browserify-sign/-/browserify-sign-4.2.1.tgz#eaf4add46dd54be3bb3b36c0cf15abbeba7956c3" - integrity sha512-/vrA5fguVAKKAVTNJjgSm1tRQDHUU6DbwO9IROu/0WAzC8PKhucDSh18J0RMvVeHAn5puMd+QHC2erPRNf8lmg== + version "4.2.2" + resolved "https://registry.yarnpkg.com/browserify-sign/-/browserify-sign-4.2.2.tgz#e78d4b69816d6e3dd1c747e64e9947f9ad79bc7e" + integrity sha512-1rudGyeYY42Dk6texmv7c4VcQ0EsvVbLwZkA+AQB7SxvXxmcD93jcHie8bzecJ+ChDlmAm2Qyu0+Ccg5uhZXCg== dependencies: - bn.js "^5.1.1" - browserify-rsa "^4.0.1" + bn.js "^5.2.1" + browserify-rsa "^4.1.0" create-hash "^1.2.0" create-hmac "^1.1.7" - elliptic "^6.5.3" + elliptic "^6.5.4" inherits "^2.0.4" - parse-asn1 "^5.1.5" - readable-stream "^3.6.0" - safe-buffer "^5.2.0" + parse-asn1 "^5.1.6" + readable-stream "^3.6.2" + safe-buffer "^5.2.1" browserify-zlib@^0.2.0: version "0.2.0" @@ -6452,7 +6457,7 @@ element-resize-detector@^1.2.2: dependencies: batch-processor "1.0.0" -elliptic@^6.5.3: +elliptic@^6.5.3, elliptic@^6.5.4: version "6.5.4" resolved "https://registry.yarnpkg.com/elliptic/-/elliptic-6.5.4.tgz#da37cebd31e79a1367e941b592ed1fbebd58abbb" integrity sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ== @@ -10697,7 +10702,7 @@ parent-module@^1.0.0: dependencies: callsites "^3.0.0" -parse-asn1@^5.0.0, parse-asn1@^5.1.5: +parse-asn1@^5.0.0, parse-asn1@^5.1.6: version "5.1.6" resolved "https://registry.yarnpkg.com/parse-asn1/-/parse-asn1-5.1.6.tgz#385080a3ec13cb62a62d39409cb3e88844cdaed4" integrity sha512-RnZRo1EPU6JBnra2vGHj0yhp6ebyjBZpmUCLHWiFhxlzvBCCpAuZ7elsBp1PVAbQN0/04VD/19rfzlBSwLstMw== @@ -12238,6 +12243,15 @@ readable-stream@^3.0.6, readable-stream@^3.6.0: string_decoder "^1.1.1" util-deprecate "^1.0.1" +readable-stream@^3.6.2: + version "3.6.2" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-3.6.2.tgz#56a9b36ea965c00c5a93ef31eb111a0f11056967" + integrity sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA== + dependencies: + inherits "^2.0.3" + string_decoder "^1.1.1" + util-deprecate "^1.0.1" + readdirp@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-2.2.1.tgz#0e87622a3325aa33e892285caf8b4e846529a525" @@ -12627,7 +12641,7 @@ safe-buffer@5.1.2, safe-buffer@~5.1.0, safe-buffer@~5.1.1: resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== -safe-buffer@5.2.1, safe-buffer@>=5.1.0, safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.1, safe-buffer@^5.1.2, safe-buffer@^5.2.0, safe-buffer@~5.2.0: +safe-buffer@5.2.1, safe-buffer@>=5.1.0, safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.1, safe-buffer@^5.1.2, safe-buffer@^5.2.0, safe-buffer@^5.2.1, safe-buffer@~5.2.0: version "5.2.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== From 2929d901602616d894ca4710186c5b3f2810de09 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Nov 2023 14:59:53 -0500 Subject: [PATCH 31/57] Bump chromedriver from 100.0.0 to 119.0.1 in /server (#364) Bumps [chromedriver](https://github.com/giggio/node-chromedriver) from 100.0.0 to 119.0.1. - [Commits](https://github.com/giggio/node-chromedriver/compare/100.0.0...119.0.1) --- updated-dependencies: - dependency-name: chromedriver dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- server/yarn.lock | 120 ++++++++++++++++++++--------------------------- 1 file changed, 50 insertions(+), 70 deletions(-) diff --git a/server/yarn.lock b/server/yarn.lock index bbe224ba..48bc3568 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -1890,10 +1890,10 @@ "@smithy/util-buffer-from" "^1.0.2" tslib "^2.5.0" -"@testim/chrome-version@^1.1.2": - version "1.1.2" - resolved "https://registry.yarnpkg.com/@testim/chrome-version/-/chrome-version-1.1.2.tgz#092005c5b77bd3bb6576a4677110a11485e11864" - integrity sha512-1c4ZOETSRpI0iBfIFUqU4KqwBAB2lHUAlBjZz/YqOHqwM9dTTzjV6Km0ZkiEiSCx/tLr1BtESIKyWWMww+RUqw== +"@testim/chrome-version@^1.1.4": + version "1.1.4" + resolved "https://registry.yarnpkg.com/@testim/chrome-version/-/chrome-version-1.1.4.tgz#86e04e677cd6c05fa230dd15ac223fa72d1d7090" + integrity sha512-kIhULpw9TrGYnHp/8VfdcneIcxKnLixmADtukQRtJUmsVlMg0niMkwV0xZmi8hqa57xqilIHjWFA0GKvEjVU5g== "@tootallnate/once@1": version "1.1.2" @@ -2340,14 +2340,6 @@ agent-base@6: dependencies: debug "4" -aggregate-error@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/aggregate-error/-/aggregate-error-3.1.0.tgz#92670ff50f5359bdb7a3e0d40d0ec30c5737687a" - integrity sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA== - dependencies: - clean-stack "^2.0.0" - indent-string "^4.0.0" - ajv@^6.10.0, ajv@^6.12.4: version "6.12.6" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" @@ -2591,12 +2583,14 @@ axios@>=0.21.2: dependencies: follow-redirects "^1.14.8" -axios@^0.24.0: - version "0.24.0" - resolved "https://registry.yarnpkg.com/axios/-/axios-0.24.0.tgz#804e6fa1e4b9c5288501dd9dff56a7a0940d20d6" - integrity sha512-Q6cWsys88HoPgAaFAVUb0WpPk0O8iTeisR9IMqy9G8AbO4NlpVknrnQS03zzF9PGAWgO3cgletO3VjV/P7VztA== +axios@^1.6.0: + version "1.6.1" + resolved "https://registry.yarnpkg.com/axios/-/axios-1.6.1.tgz#76550d644bf0a2d469a01f9244db6753208397d7" + integrity sha512-vfBmhDpKafglh0EldBEbVuoe7DyAavGSLWhuSm5ZSEKQnHhBf0xAAwybbNH1IkrJNGnS/VG4I5yxig1pCEXE4g== dependencies: - follow-redirects "^1.14.4" + follow-redirects "^1.15.0" + form-data "^4.0.0" + proxy-from-env "^1.1.0" babel-jest@^27.5.1: version "27.5.1" @@ -2869,17 +2863,17 @@ chokidar@^3.5.1: fsevents "~2.3.2" chromedriver@latest: - version "100.0.0" - resolved "https://registry.yarnpkg.com/chromedriver/-/chromedriver-100.0.0.tgz#1b4bf5c89cea12c79f53bc94d8f5bb5aa79ed7be" - integrity sha512-oLfB0IgFEGY9qYpFQO/BNSXbPw7bgfJUN5VX8Okps9W2qNT4IqKh5hDwKWtpUIQNI6K3ToWe2/J5NdpurTY02g== + version "119.0.1" + resolved "https://registry.yarnpkg.com/chromedriver/-/chromedriver-119.0.1.tgz#064f3650790ccea055e9bfd95c600f5ea60295e9" + integrity sha512-lpCFFLaXPpvElTaUOWKdP74pFb/sJhWtWqMjn7Ju1YriWn8dT5JBk84BGXMPvZQs70WfCYWecxdMmwfIu1Mupg== dependencies: - "@testim/chrome-version" "^1.1.2" - axios "^0.24.0" - del "^6.0.0" + "@testim/chrome-version" "^1.1.4" + axios "^1.6.0" + compare-versions "^6.1.0" extract-zip "^2.0.1" - https-proxy-agent "^5.0.0" + https-proxy-agent "^5.0.1" proxy-from-env "^1.1.0" - tcp-port-used "^1.0.1" + tcp-port-used "^1.0.2" ci-info@^3.2.0: version "3.3.0" @@ -2891,11 +2885,6 @@ cjs-module-lexer@^1.0.0: resolved "https://registry.yarnpkg.com/cjs-module-lexer/-/cjs-module-lexer-1.2.2.tgz#9f84ba3244a512f3a54e5277e8eef4c489864e40" integrity sha512-cOU9usZw8/dXIXKtwa8pM0OTJQuJkxMN6w30csNRUerHfeQ5R6U3kkU/FtJeIf3M202OHfY2U8ccInBG7/xogA== -clean-stack@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/clean-stack/-/clean-stack-2.2.0.tgz#ee8472dbb129e727b31e8a10a427dee9dfe4008b" - integrity sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A== - cliui@^7.0.2: version "7.0.4" resolved "https://registry.yarnpkg.com/cliui/-/cliui-7.0.4.tgz#a0265ee655476fc807aea9df3df8df7783808b4f" @@ -2980,6 +2969,11 @@ commander@^2.20.3: resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== +compare-versions@^6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/compare-versions/-/compare-versions-6.1.0.tgz#3f2131e3ae93577df111dba133e6db876ffe127a" + integrity sha512-LNZQXhqUvqUTotpZ00qLSaify3b4VFD588aRr8MKFw4CMUr98ytzCW5wDH5qx/DEY5kCDXcbcRuCqL0szEf2tg== + concat-map@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" @@ -3169,20 +3163,6 @@ define-properties@^1.1.3: dependencies: object-keys "^1.0.12" -del@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/del/-/del-6.0.0.tgz#0b40d0332cea743f1614f818be4feb717714c952" - integrity sha512-1shh9DQ23L16oXSZKB2JxpL7iMy2E0S9d517ptA1P8iw0alkPtQcrKH7ru31rYtKwF499HkTu+DRzq3TCKDFRQ== - dependencies: - globby "^11.0.1" - graceful-fs "^4.2.4" - is-glob "^4.0.1" - is-path-cwd "^2.2.0" - is-path-inside "^3.0.2" - p-map "^4.0.0" - rimraf "^3.0.2" - slash "^3.0.0" - delayed-stream@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" @@ -3855,11 +3835,16 @@ fn.name@1.x.x: resolved "https://registry.yarnpkg.com/fn.name/-/fn.name-1.1.0.tgz#26cad8017967aea8731bc42961d04a3d5988accc" integrity sha512-GRnmB5gPyJpAhTQdSZTSp9uaPSvl09KoYcMQtsB9rQoOmzs9dH6ffeccH+Z+cv6P68Hu5bC6JjRh4Ah/mHSNRw== -follow-redirects@^1.14.4, follow-redirects@^1.14.8: +follow-redirects@^1.14.8: version "1.14.9" resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.14.9.tgz#dd4ea157de7bfaf9ea9b3fbd85aa16951f78d8d7" integrity sha512-MQDfihBQYMcyy5dhRDJUHcw7lb2Pv/TuE6xP1vyraLukNDHKbDxDNaOE3NbCAdKQApno+GPRyo1YAp89yCjK4w== +follow-redirects@^1.15.0: + version "1.15.3" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.3.tgz#fe2f3ef2690afce7e82ed0b44db08165b207123a" + integrity sha512-1VzOtuEM8pC9SFU1E+8KfTjZyMztRsgEfwQl44z8A25uy13jSzTj6dyK2Df52iV0vgHCfBwLhDWevLn95w5v6Q== + form-data-encoder@^1.7.1: version "1.7.2" resolved "https://registry.yarnpkg.com/form-data-encoder/-/form-data-encoder-1.7.2.tgz#1f1ae3dccf58ed4690b86d87e4f57c654fbab040" @@ -3874,6 +3859,15 @@ form-data@^3.0.0: combined-stream "^1.0.8" mime-types "^2.1.12" +form-data@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/form-data/-/form-data-4.0.0.tgz#93919daeaf361ee529584b9b31664dc12c9fa452" + integrity sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww== + dependencies: + asynckit "^0.4.0" + combined-stream "^1.0.8" + mime-types "^2.1.12" + formdata-node@^4.3.1: version "4.3.2" resolved "https://registry.yarnpkg.com/formdata-node/-/formdata-node-4.3.2.tgz#0262e94931e36db7239c2b08bdb6aaf18ec47d21" @@ -4002,7 +3996,7 @@ globals@^13.6.0, globals@^13.9.0: dependencies: type-fest "^0.20.2" -globby@^11.0.1, globby@^11.0.3, globby@^11.0.4: +globby@^11.0.3, globby@^11.0.4: version "11.1.0" resolved "https://registry.yarnpkg.com/globby/-/globby-11.1.0.tgz#bd4be98bb042f83d796f7e3811991fbe82a0d34b" integrity sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g== @@ -4014,7 +4008,7 @@ globby@^11.0.1, globby@^11.0.3, globby@^11.0.4: merge2 "^1.4.1" slash "^3.0.0" -graceful-fs@^4.2.4, graceful-fs@^4.2.9: +graceful-fs@^4.2.9: version "4.2.10" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.10.tgz#147d3a006da4ca3ce14728c7aefc287c367d7a6c" integrity sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA== @@ -4172,6 +4166,14 @@ https-proxy-agent@^5.0.0: agent-base "6" debug "4" +https-proxy-agent@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz#c59ef224a04fe8b754f3db0063a25ea30d0005d6" + integrity sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA== + dependencies: + agent-base "6" + debug "4" + human-signals@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-2.1.0.tgz#dc91fcba42e4d06e4abaed33b3e7a3c02f514ea0" @@ -4215,11 +4217,6 @@ imurmurhash@^0.1.4: resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= -indent-string@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-4.0.0.tgz#624f8f4497d619b2d9768531d58f4122854d7251" - integrity sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg== - inflight@^1.0.4: version "1.0.6" resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" @@ -4347,16 +4344,6 @@ is-number@^7.0.0: resolved "https://registry.yarnpkg.com/is-number/-/is-number-7.0.0.tgz#7535345b896734d5f80c4d06c50955527a14f12b" integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== -is-path-cwd@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/is-path-cwd/-/is-path-cwd-2.2.0.tgz#67d43b82664a7b5191fd9119127eb300048a9fdb" - integrity sha512-w942bTcih8fdJPJmQHFzkS76NEP8Kzzvmw92cXsazb8intwLqPibPPdXf4ANdKV3rYMuuQYGIWtvz9JilB3NFQ== - -is-path-inside@^3.0.2: - version "3.0.3" - resolved "https://registry.yarnpkg.com/is-path-inside/-/is-path-inside-3.0.3.tgz#d231362e53a07ff2b0e0ea7fed049161ffd16283" - integrity sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ== - is-potential-custom-element-name@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz#171ed6f19e3ac554394edf78caa05784a45bebb5" @@ -5511,13 +5498,6 @@ p-locate@^4.1.0: dependencies: p-limit "^2.2.0" -p-map@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/p-map/-/p-map-4.0.0.tgz#bb2f95a5eda2ec168ec9274e06a747c3e2904d2b" - integrity sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ== - dependencies: - aggregate-error "^3.0.0" - p-try@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/p-try/-/p-try-1.0.0.tgz#cbc79cdbaf8fd4228e13f621f2b1a237c1b207b3" @@ -6213,7 +6193,7 @@ sync-fetch@^0.3.1: buffer "^5.7.0" node-fetch "^2.6.1" -tcp-port-used@^1.0.1: +tcp-port-used@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/tcp-port-used/-/tcp-port-used-1.0.2.tgz#9652b7436eb1f4cfae111c79b558a25769f6faea" integrity sha512-l7ar8lLUD3XS1V2lfoJlCBaeoaWo/2xfYt81hM7VlvR4RrMVFqfmzfhLVk40hAb368uitje5gPtBRL1m/DGvLA== From 5c89adb3be26736c1e347a8b446a51843e8932fc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Nov 2023 16:32:01 -0500 Subject: [PATCH 32/57] Bump axios from 0.26.1 to 1.6.0 in /server (#365) * Bump axios from 0.26.1 to 1.6.0 in /server Bumps [axios](https://github.com/axios/axios) from 0.26.1 to 1.6.0. - [Release notes](https://github.com/axios/axios/releases) - [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md) - [Commits](https://github.com/axios/axios/compare/v0.26.1...v1.6.0) --- updated-dependencies: - dependency-name: axios dependency-type: direct:production ... Signed-off-by: dependabot[bot] * Update jest config for new axios version --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Mackenzie Ian Frew --- server/jest.config.ts | 3 +++ server/package.json | 2 +- server/yarn.lock | 17 +++++++---------- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/server/jest.config.ts b/server/jest.config.ts index d626d0eb..21d8d344 100644 --- a/server/jest.config.ts +++ b/server/jest.config.ts @@ -8,6 +8,9 @@ const config: Config.InitialOptions = { '.(ts|tsx)': 'ts-jest', }, verbose: true, + moduleNameMapper: { + axios: '/node_modules/axios/dist/node/axios.cjs', + } }; export default config; diff --git a/server/package.json b/server/package.json index 4470c258..2bafb947 100644 --- a/server/package.json +++ b/server/package.json @@ -17,7 +17,7 @@ "@turf/clusters-kmeans": "^6.5.0", "@turf/helpers": "^6.5.0", "apollo-server-express": "3.x", - "axios": ">=0.21.2", + "axios": ">=1.6.0", "cross-fetch": "^3.1.5", "eslint-config-prettier": "^8.3.0", "express": "^4.17.1", diff --git a/server/yarn.lock b/server/yarn.lock index 48bc3568..888e0c60 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -2576,12 +2576,14 @@ asynckit@^0.4.0: resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" integrity sha1-x57Zf380y48robyXkLzDZkdLS3k= -axios@>=0.21.2: - version "0.26.1" - resolved "https://registry.yarnpkg.com/axios/-/axios-0.26.1.tgz#1ede41c51fcf51bbbd6fd43669caaa4f0495aaa9" - integrity sha512-fPwcX4EvnSHuInCMItEhAGnaSEXRBjtzh9fOtsE6E1G6p7vl7edEeZe11QHf18+6+9gR5PbKV/sGKNaD8YaMeA== +axios@>=1.6.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/axios/-/axios-1.6.0.tgz#f1e5292f26b2fd5c2e66876adc5b06cdbd7d2102" + integrity sha512-EZ1DYihju9pwVB+jg67ogm+Tmqc6JmhamRN6I4Zt8DfZu5lbcQGw3ozH9lFejSJgs/ibaef3A9PMXPLeefFGJg== dependencies: - follow-redirects "^1.14.8" + follow-redirects "^1.15.0" + form-data "^4.0.0" + proxy-from-env "^1.1.0" axios@^1.6.0: version "1.6.1" @@ -3835,11 +3837,6 @@ fn.name@1.x.x: resolved "https://registry.yarnpkg.com/fn.name/-/fn.name-1.1.0.tgz#26cad8017967aea8731bc42961d04a3d5988accc" integrity sha512-GRnmB5gPyJpAhTQdSZTSp9uaPSvl09KoYcMQtsB9rQoOmzs9dH6ffeccH+Z+cv6P68Hu5bC6JjRh4Ah/mHSNRw== -follow-redirects@^1.14.8: - version "1.14.9" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.14.9.tgz#dd4ea157de7bfaf9ea9b3fbd85aa16951f78d8d7" - integrity sha512-MQDfihBQYMcyy5dhRDJUHcw7lb2Pv/TuE6xP1vyraLukNDHKbDxDNaOE3NbCAdKQApno+GPRyo1YAp89yCjK4w== - follow-redirects@^1.15.0: version "1.15.3" resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.3.tgz#fe2f3ef2690afce7e82ed0b44db08165b207123a" From f3baf3c58a52f5d4836ed6610a4a36e232f52900 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Wed, 17 Jan 2024 10:05:05 -0500 Subject: [PATCH 33/57] Add PT Pagination support for G4RD Staging (#366) * Add fetchPhenotipsVariant for collecting paginated results * Don't infinite loop * Finish pagination support for G4RD * Fix linting issues * Formatting * Fix test suite --- server/__tests__/adapters/g4rdAdapter.test.ts | 34 +--- .../adapters/g4rdAdapter.ts | 169 ++++++++---------- .../utils/fetchPhenotipsVariants.ts | 102 +++++++++++ server/src/types.ts | 18 ++ 4 files changed, 208 insertions(+), 115 deletions(-) create mode 100644 server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts diff --git a/server/__tests__/adapters/g4rdAdapter.test.ts b/server/__tests__/adapters/g4rdAdapter.test.ts index 35a52de6..b7dc94f1 100644 --- a/server/__tests__/adapters/g4rdAdapter.test.ts +++ b/server/__tests__/adapters/g4rdAdapter.test.ts @@ -1,14 +1,16 @@ import { makeExecutableSchema } from '@graphql-tools/schema'; import { transformG4RDQueryResponse } from '../../src/resolvers/getVariantsResolver/adapters/g4rdAdapter'; import typeDefs from '../../src/typeDefs'; -import { CombinedVariantQueryResponse, G4RDVariantQueryResult } from '../../src/types'; +import { CombinedVariantQueryResponse, PTPaginatedVariantQueryResult } from '../../src/types'; import { addMocksToSchema } from '@graphql-tools/mock'; import { testGraphQLQuery } from '../testGraphQLQuery'; /* an around the world test here would validate the transformer and pass it to the schema */ -const testResponse: G4RDVariantQueryResult = { +const testResponse: PTPaginatedVariantQueryResult = { exists: true, + page: 1, + limit: 5, numTotalResults: 1, results: [ { @@ -27,21 +29,13 @@ const testResponse: G4RDVariantQueryResult = { }, ], }, - individual: { - individualId: '12345', - diseases: [], - phenotypicFeatures: [ - { phenotypeId: 'HP:0002140', levelSeverity: null }, - { phenotypeId: 'HP:0002326', levelSeverity: null }, - { phenotypeId: 'HP:0012158', levelSeverity: null }, - ], - sex: 'NCIT:C46112', - }, - contactInfo: 'Test User', + individualIds: ['12345'], }, ], }; +const testVariantArray = testResponse.results; + const patientTestResponse = [ { date: new Date('2021-12-14T19:40:50.000Z'), @@ -140,7 +134,7 @@ const patientTestResponse = [ const familyTestResponse = { '12345': '6789' }; const transformed = transformG4RDQueryResponse( - testResponse, + testVariantArray, patientTestResponse, familyTestResponse ); @@ -172,22 +166,12 @@ describe('Test g4rd query response transformer', () => { start } individual { - diseases { - ageOfOnset { - age - ageGroup - } - description - diseaseId - levelSeverity - outcome - stage - } individualId phenotypicFeatures { levelSeverity observed phenotypeId + phenotypeLabel } sex ethnicity diff --git a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts index f306d496..877c721c 100644 --- a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts +++ b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts @@ -12,16 +12,17 @@ import { VariantResponseFields, G4RDFamilyQueryResult, G4RDPatientQueryResult, - G4RDVariantQueryResult, Disorder, IndividualInfoFields, PhenotypicFeaturesFields, NonStandardFeature, Feature, + PTVariantArray, } from '../../../types'; import { getFromCache, putInCache } from '../../../utils/cache'; import { timeit, timeitAsync } from '../../../utils/timeit'; import resolveAssembly from '../utils/resolveAssembly'; +import fetchPhenotipsVariants from '../utils/fetchPhenotipsVariants'; /* eslint-disable camelcase */ @@ -38,7 +39,7 @@ const _getG4rdNodeQuery = async ({ input: { gene: geneInput, variant }, }: QueryInput): Promise => { let G4RDNodeQueryError: G4RDNodeQueryError | null = null; - let G4RDVariantQueryResponse: null | AxiosResponse = null; + let G4RDVariants: null | PTVariantArray = null; let G4RDPatientQueryResponse: null | AxiosResponse = null; const FamilyIds: null | Record = {}; // let Authorization = ''; @@ -53,34 +54,23 @@ const _getG4rdNodeQuery = async ({ source: SOURCE_NAME, }; } - const url = `${process.env.G4RD_URL}/rest/variants/match`; /* eslint-disable @typescript-eslint/no-unused-vars */ - const { position, ...gene } = geneInput; variant.assemblyId = 'GRCh37'; // For g4rd node, assemblyId is a required field as specified in this sample request: // https://github.com/ccmbioinfo/report-scripts/blob/master/docs/phenotips-api.md#matching-endpoint // assemblyId is set to be GRCh37 because g4rd node only contains data in assembly GRCh37. + try { - G4RDVariantQueryResponse = await axios.post( - url, - { - gene, - variant, - }, - { - headers: { - Authorization, - 'Content-Type': 'application/json', - Accept: 'application/json', - }, - } + G4RDVariants = await fetchPhenotipsVariants( + process.env.G4RD_URL as string, + geneInput, + variant, + Authorization ); // Get patients info - if (G4RDVariantQueryResponse) { - let individualIds = G4RDVariantQueryResponse.data.results - .map(v => v.individual.individualId!) - .filter(Boolean); // Filter out undefined and null values. + if (G4RDVariants) { + let individualIds = G4RDVariants.flatMap(v => v.individualIds).filter(Boolean); // Filter out undefined and null values. // Get all unique individual Ids. individualIds = [...new Set(individualIds)]; @@ -132,7 +122,7 @@ const _getG4rdNodeQuery = async ({ return { data: transformG4RDQueryResponse( - (G4RDVariantQueryResponse?.data as G4RDVariantQueryResult) || [], + (G4RDVariants as PTVariantArray) || [], (G4RDPatientQueryResponse?.data as G4RDPatientQueryResult) || [], FamilyIds ), @@ -204,98 +194,97 @@ export const transformG4RDNodeErrorResponse: ErrorTransformer feature.observed === 'yes' ? true : feature.observed === 'no' ? false : undefined; -export const transformG4RDQueryResponse: ResultTransformer = timeit( +export const transformG4RDQueryResponse: ResultTransformer = timeit( 'transformG4RDQueryResponse' )( ( - variantResponse: G4RDVariantQueryResult, + variants: PTVariantArray, patientResponse: G4RDPatientQueryResult[], familyIds: Record ) => { const individualIdsMap = Object.fromEntries(patientResponse.map(p => [p.id, p])); + // Format we want: list where every entry is a variant-patient pair + // Received format: list of variants, and list of patients. Each variant has list of patient IDs associated to it. - return (variantResponse.results || []).map(r => { + return (variants || []).flatMap(r => { /* eslint-disable @typescript-eslint/no-unused-vars */ r.variant.assemblyId = resolveAssembly(r.variant.assemblyId); - const { individual, contactInfo } = r; + const { individualIds } = r; - const patient = individual.individualId ? individualIdsMap[individual.individualId] : null; + return individualIds.map(individualId => { + const patient = individualIdsMap[individualId]; - let info: IndividualInfoFields = {}; - let ethnicity: string = ''; - let disorders: Disorder[] = []; - let phenotypicFeatures: PhenotypicFeaturesFields[] = individual.phenotypicFeatures || []; + const contactInfo: string = patient.contact + ? patient.contact.map(c => c.name).join(' ,') + : ''; - if (patient) { - const candidateGene = (patient.genes ?? []).map(g => g.gene).join('\n'); - const classifications = (patient.genes ?? []).map(g => g.status).join('\n'); - const diagnosis = patient.clinicalStatus; - const solved = patient.solved ? patient.solved.status : ''; - const clinicalStatus = patient.clinicalStatus; - disorders = patient.disorders.filter(({ label }) => label !== 'affected') as Disorder[]; - ethnicity = Object.values(patient.ethnicity) - .flat() - .map(p => p.trim()) - .join(', '); - info = { - solved, - candidateGene, - diagnosis, - classifications, - clinicalStatus, - disorders, - }; - // variant response contains all phenotypic features listed, - // even if some of them are explicitly _not_ observed by clinician and recorded as such - if (individual.phenotypicFeatures !== null && individual.phenotypicFeatures !== undefined) { + let info: IndividualInfoFields = {}; + let ethnicity: string = ''; + let disorders: Disorder[] = []; + let phenotypicFeatures: PhenotypicFeaturesFields[] = []; + + if (patient) { + const candidateGene = (patient.genes ?? []).map(g => g.gene).join('\n'); + const classifications = (patient.genes ?? []).map(g => g.status).join('\n'); + const diagnosis = patient.clinicalStatus; + const solved = patient.solved ? patient.solved.status : ''; + const clinicalStatus = patient.clinicalStatus; + disorders = patient.disorders.filter(({ label }) => label !== 'affected') as Disorder[]; + ethnicity = Object.values(patient.ethnicity) + .flat() + .map(p => p.trim()) + .join(', '); + info = { + solved, + candidateGene, + diagnosis, + classifications, + clinicalStatus, + disorders, + }; + // variant response contains all phenotypic features listed, + // even if some of them are explicitly _not_ observed by clinician and recorded as such + + // UPDATE Dec 2022: variant response no longer contains phenotypic features as of pagination change + // We only have patient query for features + // Some fields are lost (see 'null' fields below), but G4RD approves since they aren't visible on the front-end anyways const features = [...(patient.features ?? []), ...(patient.nonstandard_features ?? [])]; - const detailedFeatures = individual.phenotypicFeatures; - // build list of features the safe way - const detailedFeatureMap = Object.fromEntries( - detailedFeatures.map(feat => [feat.phenotypeId, feat]) - ); const finalFeatures: PhenotypicFeaturesFields[] = features.map(feat => { - if (feat.id === undefined) { - return { - ageOfOnset: null, - dateOfOnset: null, - levelSeverity: null, - onsetType: null, - phenotypeId: feat.id, - phenotypeLabel: feat.label, - observed: isObserved(feat), - }; - } return { - ...detailedFeatureMap[feat.id], + // ageOfOnset: null, + // dateOfOnset: null, + levelSeverity: null, + // onsetType: null, + phenotypeId: feat.id, + phenotypeLabel: feat.label, observed: isObserved(feat), }; }); phenotypicFeatures = finalFeatures; } - } - const variant: VariantResponseFields = { - alt: r.variant.alt, - assemblyId: r.variant.assemblyId, - callsets: r.variant.callsets, - end: r.variant.end, - ref: r.variant.ref, - start: r.variant.start, - chromosome: r.variant.chromosome, - }; + const variant: VariantResponseFields = { + alt: r.variant.alt, + assemblyId: r.variant.assemblyId, + callsets: r.variant.callsets, + end: r.variant.end, + ref: r.variant.ref, + start: r.variant.start, + chromosome: r.variant.chromosome, + }; - let familyId: string = ''; - if (individual.individualId) familyId = familyIds[individual.individualId]; + const familyId: string = familyIds[individualId]; - const individualResponseFields: IndividualResponseFields = { - ...individual, - ethnicity, - info, - familyId, - phenotypicFeatures, - }; - return { individual: individualResponseFields, variant, contactInfo, source: SOURCE_NAME }; + const individualResponseFields: IndividualResponseFields = { + sex: patient.sex, + ethnicity, + info, + familyId, + phenotypicFeatures, + individualId, + }; + return { individual: individualResponseFields, variant, contactInfo, source: SOURCE_NAME }; + }); }); } ); diff --git a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts new file mode 100644 index 00000000..b5120aab --- /dev/null +++ b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts @@ -0,0 +1,102 @@ +/** + * Handles fetching from /rest/variants/match endpoint in Phenotips. + */ +import axios from 'axios'; +import { GeneQueryInput, PTPaginatedVariantQueryResult, VariantQueryInput } from '../../../types'; +import logger from '../../../logger'; +import resolveChromosome from './resolveChromosome'; +import { QueryResponseError } from './queryResponseError'; + +const COUNT = 25; + +/** + * Return a complete list of results from Phenotips with a given query to /rest/variants/match. + * Collects paginated results as a single array of results. + * + * @param baseUrl The URL where the Phenotips instance is hosted. Used as {baseUrl}/rest/variants/match + * @param gene Gene query parameter. + * @param variant Variant query parameter. + * @param authorization Authorization header string to use with query. + * @throws + */ +const fetchPhenotipsVariants = async ( + baseUrl: string, + gene: GeneQueryInput, + variant: VariantQueryInput, + authorization: string +): Promise => { + let currentPage = 1; + let collectedResults: PTPaginatedVariantQueryResult['results'] = []; + let maxResults = Infinity; + const count = COUNT; + const position = resolveChromosome(gene.position); + + logger.debug( + `Begin fetching paginated variants from ${baseUrl}. gene: ${JSON.stringify( + gene + )}, variant: ${JSON.stringify(variant)}` + ); + do { + try { + const variantQueryResponse = await axios.post( + `${baseUrl}/rest/variants/match`, + { + page: currentPage, + limit: count, + variant: { + ...variant, + position: { + chrom: Number(position.chromosome), + start: Number(position.start), + end: Number(position.end), + }, + }, + }, + { + headers: { + Authorization: authorization, // TODO: In future, use function instead to get auth? + 'Content-Type': 'application/json', + Accept: 'application/json', + }, + } + ); + if (variantQueryResponse && variantQueryResponse.data.exists) { + const { results, numTotalResults } = variantQueryResponse.data; + logger.debug( + `Successful query of page ${currentPage}, limit ${count}, total: ${numTotalResults}` + ); + // expect page = currentPage, limit = count + maxResults = numTotalResults; + collectedResults = collectedResults.concat(results); + currentPage += 1; + } else { + if (collectedResults.length === 0) { + logger.warn(`Variant data does not exist at position ${JSON.stringify(position)}`); + return []; + } else { + // it would be really weird if this happened. the error existed on one page but not the next? + logger.error( + `Position '${JSON.stringify( + position + )}' has missing data on page ${currentPage} somehow??` + ); + throw new QueryResponseError({ + code: 500, + message: 'Internal Server Error', + source: 'OSMP', + }); + } + } + } catch (error: any) { + logger.error(JSON.stringify(error)); + throw error; // Adapters will need to handle this error + } + } while (collectedResults.length < maxResults); + logger.debug( + `Fetched ${collectedResults.length} variants across ${currentPage - 1} pages from ${baseUrl}` + ); + + return collectedResults; +}; + +export default fetchPhenotipsVariants; diff --git a/server/src/types.ts b/server/src/types.ts index f2a6ab50..72d368be 100644 --- a/server/src/types.ts +++ b/server/src/types.ts @@ -148,6 +148,19 @@ export interface G4RDVariantQueryResult { }[]; } +export type PTVariantArray = { + individualIds: string[]; + variant: VariantResponseFields; +}[]; + +export interface PTPaginatedVariantQueryResult { + page: number; + limit: number; + exists: boolean; + numTotalResults: number; + results: PTVariantArray; +} + /* G4RD GET patients endpoint schema */ // https://docs.phenotips.com/reference/fetchpatients-1 export interface Contact { @@ -215,6 +228,11 @@ export interface G4RDPatientQueryResult { solved?: Solved; features?: Feature[]; nonstandard_features?: NonStandardFeature[]; + contact?: { + name: string; + id: string; + }[]; + sex?: Maybe; } /* End of G4RD GET patients endpoint schema */ From ae2e5eac54456c6f7628ddb9ce79f57a7acd4343 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Fri, 19 Jan 2024 16:14:38 -0500 Subject: [PATCH 34/57] Server: fix pagination bugs with G4RD (#369) * Fix searching for X, Y chromosomes by position * Add "pagination" for patient queries * Linting and formatting * Use function to get auth token to prevent token expiry mid-query * Better debug messages * format --- .../adapters/g4rdAdapter.ts | 40 ++++++----- .../utils/fetchPhenotipsPatients.ts | 67 +++++++++++++++++++ .../utils/fetchPhenotipsVariants.ts | 24 ++++--- 3 files changed, 101 insertions(+), 30 deletions(-) create mode 100644 server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsPatients.ts diff --git a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts index 877c721c..7e6379b3 100644 --- a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts +++ b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts @@ -1,4 +1,4 @@ -import axios, { AxiosError, AxiosResponse } from 'axios'; +import axios, { AxiosError } from 'axios'; import jwtDecode from 'jwt-decode'; import { URLSearchParams } from 'url'; import { v4 as uuidv4 } from 'uuid'; @@ -23,6 +23,7 @@ import { getFromCache, putInCache } from '../../../utils/cache'; import { timeit, timeitAsync } from '../../../utils/timeit'; import resolveAssembly from '../utils/resolveAssembly'; import fetchPhenotipsVariants from '../utils/fetchPhenotipsVariants'; +import fetchPhenotipsPatients from '../utils/fetchPhenotipsPatients'; /* eslint-disable camelcase */ @@ -40,7 +41,7 @@ const _getG4rdNodeQuery = async ({ }: QueryInput): Promise => { let G4RDNodeQueryError: G4RDNodeQueryError | null = null; let G4RDVariants: null | PTVariantArray = null; - let G4RDPatientQueryResponse: null | AxiosResponse = null; + let G4RDPatientQueryResponse: null | G4RDPatientQueryResult[] = null; const FamilyIds: null | Record = {}; // let Authorization = ''; try { @@ -65,30 +66,22 @@ const _getG4rdNodeQuery = async ({ process.env.G4RD_URL as string, geneInput, variant, - Authorization + getAuthHeader ); // Get patients info if (G4RDVariants) { + logger.debug(`G4RDVariants length: ${G4RDVariants.length}`); let individualIds = G4RDVariants.flatMap(v => v.individualIds).filter(Boolean); // Filter out undefined and null values. // Get all unique individual Ids. individualIds = [...new Set(individualIds)]; if (individualIds.length > 0) { - const patientUrl = `${process.env.G4RD_URL}/rest/patients/fetch?${individualIds - .map(id => `id=${id}`) - .join('&')}`; - - G4RDPatientQueryResponse = await axios.get( - new URL(patientUrl).toString(), - { - headers: { - Authorization, - 'Content-Type': 'application/json', - Accept: 'application/json', - }, - } + G4RDPatientQueryResponse = await fetchPhenotipsPatients( + process.env.G4RD_URL!, + individualIds, + getAuthHeader ); // Get Family Id for each patient. @@ -100,12 +93,17 @@ const _getG4rdNodeQuery = async ({ }, }); + logger.debug('Begin fetching family IDs'); + const familyResponses = await Promise.allSettled( - individualIds.map(id => - patientFamily.get( + individualIds.map((id, i) => { + if (i % 50 === 0 || i === individualIds.length - 1) { + logger.debug(`Fetching family ${i + 1} of ${individualIds.length}`); + } + return patientFamily.get( new URL(`${process.env.G4RD_URL}/rest/patients/${id}/family`).toString() - ) - ) + ); + }) ); familyResponses.forEach((response, index) => { @@ -123,7 +121,7 @@ const _getG4rdNodeQuery = async ({ return { data: transformG4RDQueryResponse( (G4RDVariants as PTVariantArray) || [], - (G4RDPatientQueryResponse?.data as G4RDPatientQueryResult) || [], + G4RDPatientQueryResponse, FamilyIds ), error: transformG4RDNodeErrorResponse(G4RDNodeQueryError), diff --git a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsPatients.ts b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsPatients.ts new file mode 100644 index 00000000..9d28cd5a --- /dev/null +++ b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsPatients.ts @@ -0,0 +1,67 @@ +/** + * Handles fetching from /rest/patients/match endpoint in Phenotips. + */ +import axios from 'axios'; +import { G4RDPatientQueryResult } from '../../../types'; +import logger from '../../../logger'; + +// How many IDs to query at a time? +const COUNT = 50; + +/** + * Fetch patients from /rest/patients/match and return the complete result. + * + * @param baseUrl The URL where the Phenotips instance is hosted. Used as `{baseUrl}/rest/patients/match` + * @param individualIds Individual IDs to query for. + * @param authorization Authorization header string to use with query. + * @throws + */ +const fetchPhenotipsPatients = async ( + baseUrl: string, + individualIds: string[], + getAuthorization: () => Promise +): Promise => { + let currStart = 0; + let currEnd = COUNT; + + let finalPatientQueryResponse: G4RDPatientQueryResult[] = []; + + logger.debug( + `Begin fetching patients from ${baseUrl}/rest/patients/fetch. Total expected patients: ${individualIds.length}` + ); + + try { + while (currStart < individualIds.length) { + const currEndCapped = Math.min(currEnd, individualIds.length); + const queryIds = individualIds.slice(currStart, currEndCapped); + const patientUrl = `${baseUrl}/rest/patients/fetch?${queryIds + .map(id => `id=${id}`) + .join('&')}`; + const patientQueryResponse = await axios.get( + new URL(patientUrl).toString(), + { + headers: { + Authorization: await getAuthorization(), + 'Content-Type': 'application/json', + Accept: 'application/json', + }, + } + ); + finalPatientQueryResponse = finalPatientQueryResponse.concat( + patientQueryResponse?.data || [] + ); + logger.debug( + `Successful query for patients, received ${finalPatientQueryResponse.length} of ${individualIds.length}.` + ); + currStart += COUNT; + currEnd += COUNT; + } + } catch (error: any) { + logger.error(JSON.stringify(error)); + throw error; // Adapters will need to handle this error + } + + return finalPatientQueryResponse; +}; + +export default fetchPhenotipsPatients; diff --git a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts index b5120aab..8bba3235 100644 --- a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts +++ b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts @@ -7,6 +7,7 @@ import logger from '../../../logger'; import resolveChromosome from './resolveChromosome'; import { QueryResponseError } from './queryResponseError'; +// How many variants to query for at a time? const COUNT = 25; /** @@ -23,16 +24,25 @@ const fetchPhenotipsVariants = async ( baseUrl: string, gene: GeneQueryInput, variant: VariantQueryInput, - authorization: string + getAuthorization: () => Promise ): Promise => { let currentPage = 1; let collectedResults: PTPaginatedVariantQueryResult['results'] = []; let maxResults = Infinity; const count = COUNT; - const position = resolveChromosome(gene.position); + const _position = resolveChromosome(gene.position); + const chromosome = + ['X', 'Y'].indexOf(_position.chromosome) !== -1 + ? _position.chromosome + : Number(_position.chromosome); + const position = { + chrom: chromosome, + start: Number(_position.start), + end: Number(_position.end), + }; logger.debug( - `Begin fetching paginated variants from ${baseUrl}. gene: ${JSON.stringify( + `Begin fetching paginated variants from ${baseUrl}/rest/variants/match. gene: ${JSON.stringify( gene )}, variant: ${JSON.stringify(variant)}` ); @@ -45,16 +55,12 @@ const fetchPhenotipsVariants = async ( limit: count, variant: { ...variant, - position: { - chrom: Number(position.chromosome), - start: Number(position.start), - end: Number(position.end), - }, + position, }, }, { headers: { - Authorization: authorization, // TODO: In future, use function instead to get auth? + Authorization: await getAuthorization(), 'Content-Type': 'application/json', Accept: 'application/json', }, From e52db2813902fbb7216e72bd7a2b6bf102e82538 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Tue, 23 Jan 2024 16:32:48 -0500 Subject: [PATCH 35/57] Add retries to fetchPhenotipsVariants (#370) - Add check for failed patient query to prevent uncaught exception --- .../getVariantsResolver/adapters/g4rdAdapter.ts | 16 +++++++++++----- .../utils/fetchPhenotipsVariants.ts | 16 ++++++++++++++-- 2 files changed, 25 insertions(+), 7 deletions(-) diff --git a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts index 7e6379b3..efc191d0 100644 --- a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts +++ b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts @@ -78,11 +78,17 @@ const _getG4rdNodeQuery = async ({ individualIds = [...new Set(individualIds)]; if (individualIds.length > 0) { - G4RDPatientQueryResponse = await fetchPhenotipsPatients( - process.env.G4RD_URL!, - individualIds, - getAuthHeader - ); + try { + G4RDPatientQueryResponse = await fetchPhenotipsPatients( + process.env.G4RD_URL!, + individualIds, + getAuthHeader + ); + } catch (e) { + logger.error(JSON.stringify(e)); + G4RDPatientQueryResponse = []; + } + // Get Family Id for each patient. const patientFamily = axios.create({ diff --git a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts index 8bba3235..9eadd8c7 100644 --- a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts +++ b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts @@ -10,6 +10,9 @@ import { QueryResponseError } from './queryResponseError'; // How many variants to query for at a time? const COUNT = 25; +// How many times to retry a given query before throwing the error back? +const RETRY_COUNT = 3; + /** * Return a complete list of results from Phenotips with a given query to /rest/variants/match. * Collects paginated results as a single array of results. @@ -41,6 +44,8 @@ const fetchPhenotipsVariants = async ( end: Number(_position.end), }; + let numFailedQueries = 0; + logger.debug( `Begin fetching paginated variants from ${baseUrl}/rest/variants/match. gene: ${JSON.stringify( gene @@ -78,6 +83,7 @@ const fetchPhenotipsVariants = async ( } else { if (collectedResults.length === 0) { logger.warn(`Variant data does not exist at position ${JSON.stringify(position)}`); + logger.debug(JSON.stringify(variantQueryResponse)); return []; } else { // it would be really weird if this happened. the error existed on one page but not the next? @@ -94,8 +100,14 @@ const fetchPhenotipsVariants = async ( } } } catch (error: any) { - logger.error(JSON.stringify(error)); - throw error; // Adapters will need to handle this error + numFailedQueries += 1; + if (numFailedQueries > RETRY_COUNT) { + logger.error(JSON.stringify(error)); + throw error; + } else { + logger.warn(`Failed fetch (${numFailedQueries}/${RETRY_COUNT}) to ${baseUrl}/rest/variants/match, page: ${currentPage}`); + logger.warn(JSON.stringify(error)); + } } } while (collectedResults.length < maxResults); logger.debug( From 60dd5abdbba8688eddd9010ae1abd589a71a3835 Mon Sep 17 00:00:00 2001 From: Mackenzie Ian Frew Date: Tue, 23 Jan 2024 16:34:01 -0500 Subject: [PATCH 36/57] Server: formatting --- .../src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts | 1 - .../getVariantsResolver/utils/fetchPhenotipsVariants.ts | 4 +++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts index efc191d0..3aa6b436 100644 --- a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts +++ b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts @@ -88,7 +88,6 @@ const _getG4rdNodeQuery = async ({ logger.error(JSON.stringify(e)); G4RDPatientQueryResponse = []; } - // Get Family Id for each patient. const patientFamily = axios.create({ diff --git a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts index 9eadd8c7..2748dfd1 100644 --- a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts +++ b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts @@ -105,7 +105,9 @@ const fetchPhenotipsVariants = async ( logger.error(JSON.stringify(error)); throw error; } else { - logger.warn(`Failed fetch (${numFailedQueries}/${RETRY_COUNT}) to ${baseUrl}/rest/variants/match, page: ${currentPage}`); + logger.warn( + `Failed fetch (${numFailedQueries}/${RETRY_COUNT}) to ${baseUrl}/rest/variants/match, page: ${currentPage}` + ); logger.warn(JSON.stringify(error)); } } From 377c9f6b611092b7f14e9ae9dfd9d61354e80eaf Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Thu, 1 Feb 2024 11:57:54 -0500 Subject: [PATCH 37/57] Handle null params passed to transform func (#371) --- .../src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts index 3aa6b436..92287721 100644 --- a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts +++ b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts @@ -42,7 +42,7 @@ const _getG4rdNodeQuery = async ({ let G4RDNodeQueryError: G4RDNodeQueryError | null = null; let G4RDVariants: null | PTVariantArray = null; let G4RDPatientQueryResponse: null | G4RDPatientQueryResult[] = null; - const FamilyIds: null | Record = {}; // + const FamilyIds: Record = {}; // let Authorization = ''; try { Authorization = await getAuthHeader(); @@ -126,7 +126,7 @@ const _getG4rdNodeQuery = async ({ return { data: transformG4RDQueryResponse( (G4RDVariants as PTVariantArray) || [], - G4RDPatientQueryResponse, + (G4RDPatientQueryResponse as G4RDPatientQueryResult[]) || [], FamilyIds ), error: transformG4RDNodeErrorResponse(G4RDNodeQueryError), From f9ba57fa0ecced0c9a7a13bcdec0f6e0f12e05c4 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Tue, 6 Feb 2024 09:20:32 -0500 Subject: [PATCH 38/57] TEMPORARY: trace GC in staging/prod server (#372) --- server/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/Dockerfile b/server/Dockerfile index 299197ec..56368c27 100644 --- a/server/Dockerfile +++ b/server/Dockerfile @@ -31,4 +31,4 @@ COPY --from=builder /usr/src/app/dist . ENV NODE_ENV=production USER node EXPOSE 3000 -CMD ["node", "."] +CMD ["node", "--trace-gc", "."] From a0a7fee2ced7789a272afb2e784a8714d6d46739 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Tue, 6 Feb 2024 09:49:13 -0500 Subject: [PATCH 39/57] TEMPORARY: Add heap profiler for staging/prod (#373) --- docker-compose.staging.yaml | 1 + server/Dockerfile | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/docker-compose.staging.yaml b/docker-compose.staging.yaml index fb32a9b1..34576fd1 100644 --- a/docker-compose.staging.yaml +++ b/docker-compose.staging.yaml @@ -37,6 +37,7 @@ services: TEST_NODE_URL: http://test-node:3000/data ports: - 3000:3000 + - 9229:9229 <<: *common test-node: diff --git a/server/Dockerfile b/server/Dockerfile index 56368c27..b5fa99fa 100644 --- a/server/Dockerfile +++ b/server/Dockerfile @@ -30,5 +30,5 @@ FROM base COPY --from=builder /usr/src/app/dist . ENV NODE_ENV=production USER node -EXPOSE 3000 -CMD ["node", "--trace-gc", "."] +EXPOSE 3000 9229 +CMD ["node", "--trace-gc", "--inspect=0.0.0.0:9229", "."] From f03854ee64bf158410deaa4aec110dca27b451cc Mon Sep 17 00:00:00 2001 From: Mackenzie Ian Frew Date: Fri, 9 Feb 2024 12:52:11 -0500 Subject: [PATCH 40/57] TEMPORARY: inspect-brk --- server/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/Dockerfile b/server/Dockerfile index b5fa99fa..c41b4699 100644 --- a/server/Dockerfile +++ b/server/Dockerfile @@ -31,4 +31,4 @@ COPY --from=builder /usr/src/app/dist . ENV NODE_ENV=production USER node EXPOSE 3000 9229 -CMD ["node", "--trace-gc", "--inspect=0.0.0.0:9229", "."] +CMD ["node", "--trace-gc", "--inspect-brk=0.0.0.0:9229", "."] From 59ba0740055e73dcf54fdc8dc4e45138b1f75d47 Mon Sep 17 00:00:00 2001 From: Mackenzie Ian Frew Date: Fri, 9 Feb 2024 13:04:31 -0500 Subject: [PATCH 41/57] TEMPORARY: inspect-brk to localhost --- server/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/Dockerfile b/server/Dockerfile index c41b4699..6f934d16 100644 --- a/server/Dockerfile +++ b/server/Dockerfile @@ -31,4 +31,4 @@ COPY --from=builder /usr/src/app/dist . ENV NODE_ENV=production USER node EXPOSE 3000 9229 -CMD ["node", "--trace-gc", "--inspect-brk=0.0.0.0:9229", "."] +CMD ["node", "--trace-gc", "--inspect-brk", "."] From acd7eac4ca3e7c56823e34658e4b38aa58e88204 Mon Sep 17 00:00:00 2001 From: Mackenzie Ian Frew Date: Fri, 9 Feb 2024 13:15:02 -0500 Subject: [PATCH 42/57] TEMPORARY: put inspect back to global --- server/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/Dockerfile b/server/Dockerfile index 6f934d16..c41b4699 100644 --- a/server/Dockerfile +++ b/server/Dockerfile @@ -31,4 +31,4 @@ COPY --from=builder /usr/src/app/dist . ENV NODE_ENV=production USER node EXPOSE 3000 9229 -CMD ["node", "--trace-gc", "--inspect-brk", "."] +CMD ["node", "--trace-gc", "--inspect-brk=0.0.0.0:9229", "."] From b808eb9dc9a8657a00b346b55d7946c48c43e69a Mon Sep 17 00:00:00 2001 From: Mackenzie Ian Frew Date: Fri, 9 Feb 2024 14:15:27 -0500 Subject: [PATCH 43/57] TEMPORARY: revert to inspect, not inspect-brk --- server/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/Dockerfile b/server/Dockerfile index c41b4699..b5fa99fa 100644 --- a/server/Dockerfile +++ b/server/Dockerfile @@ -31,4 +31,4 @@ COPY --from=builder /usr/src/app/dist . ENV NODE_ENV=production USER node EXPOSE 3000 9229 -CMD ["node", "--trace-gc", "--inspect-brk=0.0.0.0:9229", "."] +CMD ["node", "--trace-gc", "--inspect=0.0.0.0:9229", "."] From ac27bac26fc1a533b805ce37304034e1b9faaae8 Mon Sep 17 00:00:00 2001 From: Mackenzie Ian Frew Date: Fri, 9 Feb 2024 14:35:40 -0500 Subject: [PATCH 44/57] TEMPORARY: make smaller heap to debug --- server/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/Dockerfile b/server/Dockerfile index b5fa99fa..5e211712 100644 --- a/server/Dockerfile +++ b/server/Dockerfile @@ -31,4 +31,4 @@ COPY --from=builder /usr/src/app/dist . ENV NODE_ENV=production USER node EXPOSE 3000 9229 -CMD ["node", "--trace-gc", "--inspect=0.0.0.0:9229", "."] +CMD ["node", "--trace-gc", "--inspect=0.0.0.0:9229", "--max-old-space-size=1000", "--heapsnapshot-near-heap-limit=10", "."] From 17dbe44a9cfdeb46716b5c5afc77bff64ba61dc6 Mon Sep 17 00:00:00 2001 From: Mackenzie Ian Frew Date: Fri, 9 Feb 2024 14:52:15 -0500 Subject: [PATCH 45/57] TEMPORARY: smaller heap limit --- server/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/Dockerfile b/server/Dockerfile index 5e211712..403f9fc1 100644 --- a/server/Dockerfile +++ b/server/Dockerfile @@ -31,4 +31,4 @@ COPY --from=builder /usr/src/app/dist . ENV NODE_ENV=production USER node EXPOSE 3000 9229 -CMD ["node", "--trace-gc", "--inspect=0.0.0.0:9229", "--max-old-space-size=1000", "--heapsnapshot-near-heap-limit=10", "."] +CMD ["node", "--trace-gc", "--inspect=0.0.0.0:9229", "--max-old-space-size=100", "--heapsnapshot-near-heap-limit=10", "."] From 78276a22c058a1f5e307041e3264398fcadd39c8 Mon Sep 17 00:00:00 2001 From: Mackenzie Ian Frew Date: Fri, 9 Feb 2024 15:13:37 -0500 Subject: [PATCH 46/57] Remove node debugging flags --- docker-compose.staging.yaml | 1 - server/Dockerfile | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/docker-compose.staging.yaml b/docker-compose.staging.yaml index 34576fd1..fb32a9b1 100644 --- a/docker-compose.staging.yaml +++ b/docker-compose.staging.yaml @@ -37,7 +37,6 @@ services: TEST_NODE_URL: http://test-node:3000/data ports: - 3000:3000 - - 9229:9229 <<: *common test-node: diff --git a/server/Dockerfile b/server/Dockerfile index 403f9fc1..299197ec 100644 --- a/server/Dockerfile +++ b/server/Dockerfile @@ -30,5 +30,5 @@ FROM base COPY --from=builder /usr/src/app/dist . ENV NODE_ENV=production USER node -EXPOSE 3000 9229 -CMD ["node", "--trace-gc", "--inspect=0.0.0.0:9229", "--max-old-space-size=100", "--heapsnapshot-near-heap-limit=10", "."] +EXPOSE 3000 +CMD ["node", "."] From 54a6ecb3737d992f91d131c47496810371cb365b Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Fri, 1 Mar 2024 10:49:30 -0500 Subject: [PATCH 47/57] All: Merge outstanding dependency updates (#378) * Bump follow-redirects from 1.14.9 to 1.15.4 in /react Bumps [follow-redirects](https://github.com/follow-redirects/follow-redirects) from 1.14.9 to 1.15.4. - [Release notes](https://github.com/follow-redirects/follow-redirects/releases) - [Commits](https://github.com/follow-redirects/follow-redirects/compare/v1.14.9...v1.15.4) --- updated-dependencies: - dependency-name: follow-redirects dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump follow-redirects from 1.15.3 to 1.15.4 in /server Bumps [follow-redirects](https://github.com/follow-redirects/follow-redirects) from 1.15.3 to 1.15.4. - [Release notes](https://github.com/follow-redirects/follow-redirects/releases) - [Commits](https://github.com/follow-redirects/follow-redirects/compare/v1.15.3...v1.15.4) --- updated-dependencies: - dependency-name: follow-redirects dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump undici from 5.26.3 to 5.28.3 in /server Bumps [undici](https://github.com/nodejs/undici) from 5.26.3 to 5.28.3. - [Release notes](https://github.com/nodejs/undici/releases) - [Commits](https://github.com/nodejs/undici/compare/v5.26.3...v5.28.3) --- updated-dependencies: - dependency-name: undici dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump ip from 2.0.0 to 2.0.1 in /server Bumps [ip](https://github.com/indutny/node-ip) from 2.0.0 to 2.0.1. - [Commits](https://github.com/indutny/node-ip/compare/v2.0.0...v2.0.1) --- updated-dependencies: - dependency-name: ip dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump ip from 1.1.5 to 1.1.9 in /react Bumps [ip](https://github.com/indutny/node-ip) from 1.1.5 to 1.1.9. - [Commits](https://github.com/indutny/node-ip/compare/v1.1.5...v1.1.9) --- updated-dependencies: - dependency-name: ip dependency-type: indirect ... Signed-off-by: dependabot[bot] --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- react/yarn.lock | 12 ++++++------ server/yarn.lock | 18 +++++++++--------- 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/react/yarn.lock b/react/yarn.lock index e6fc254b..d1e43b11 100644 --- a/react/yarn.lock +++ b/react/yarn.lock @@ -7315,9 +7315,9 @@ flush-write-stream@^1.0.0: readable-stream "^2.3.6" follow-redirects@^1.0.0: - version "1.14.9" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.14.9.tgz#dd4ea157de7bfaf9ea9b3fbd85aa16951f78d8d7" - integrity sha512-MQDfihBQYMcyy5dhRDJUHcw7lb2Pv/TuE6xP1vyraLukNDHKbDxDNaOE3NbCAdKQApno+GPRyo1YAp89yCjK4w== + version "1.15.4" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.4.tgz#cdc7d308bf6493126b17ea2191ea0ccf3e535adf" + integrity sha512-Cr4D/5wlrb0z9dgERpUL3LrmPKVDsETIJhaCMeDfuFYcqa5bldGV6wBsAN6X/vxlXQtFBMrXdXxdL8CbDTGniw== for-in@^1.0.2: version "1.0.2" @@ -8342,9 +8342,9 @@ invariant@^2.2.4: loose-envify "^1.0.0" ip@^1.1.0, ip@^1.1.5: - version "1.1.5" - resolved "https://registry.yarnpkg.com/ip/-/ip-1.1.5.tgz#bdded70114290828c0a039e72ef25f5aaec4354a" - integrity sha1-vd7XARQpCCjAoDnnLvJfWq7ENUo= + version "1.1.9" + resolved "https://registry.yarnpkg.com/ip/-/ip-1.1.9.tgz#8dfbcc99a754d07f425310b86a99546b1151e396" + integrity sha512-cyRxvOEpNHNtchU3Ln9KC/auJgup87llfQpQ+t5ghoC/UhL16SWzbueiCsdTnWmqAWl7LadfuwhlqmtOaqMHdQ== ipaddr.js@1.9.1: version "1.9.1" diff --git a/server/yarn.lock b/server/yarn.lock index 888e0c60..6b7c0420 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -3838,9 +3838,9 @@ fn.name@1.x.x: integrity sha512-GRnmB5gPyJpAhTQdSZTSp9uaPSvl09KoYcMQtsB9rQoOmzs9dH6ffeccH+Z+cv6P68Hu5bC6JjRh4Ah/mHSNRw== follow-redirects@^1.15.0: - version "1.15.3" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.3.tgz#fe2f3ef2690afce7e82ed0b44db08165b207123a" - integrity sha512-1VzOtuEM8pC9SFU1E+8KfTjZyMztRsgEfwQl44z8A25uy13jSzTj6dyK2Df52iV0vgHCfBwLhDWevLn95w5v6Q== + version "1.15.4" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.4.tgz#cdc7d308bf6493126b17ea2191ea0ccf3e535adf" + integrity sha512-Cr4D/5wlrb0z9dgERpUL3LrmPKVDsETIJhaCMeDfuFYcqa5bldGV6wBsAN6X/vxlXQtFBMrXdXxdL8CbDTGniw== form-data-encoder@^1.7.1: version "1.7.2" @@ -4242,9 +4242,9 @@ ip-regex@^4.1.0: integrity sha512-B9ZWJxHHOHUhUjCPrMpLD4xEq35bUTClHM1S6CBU5ixQnkZmwipwgc96vAd7AAGM9TGHvJR+Uss+/Ak6UphK+Q== ip@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/ip/-/ip-2.0.0.tgz#4cf4ab182fee2314c75ede1276f8c80b479936da" - integrity sha512-WKa+XuLG1A1R0UWhl2+1XQSi+fZWMsYKffMZTTYsiZaUD8k2yDAj5atimTUD2TZkyCkNEeYE5NhFZmupOGtjYQ== + version "2.0.1" + resolved "https://registry.yarnpkg.com/ip/-/ip-2.0.1.tgz#e8f3595d33a3ea66490204234b77636965307105" + integrity sha512-lJUL9imLTNi1ZfXT+DU6rBBdbiKGBuay9B6xGSPVjUeQwaH1RIGqef8RZkUtHioLmSNpPR5M4HVKJGm1j8FWVQ== ipaddr.js@1.9.1: version "1.9.1" @@ -6447,9 +6447,9 @@ unbox-primitive@^1.0.1: which-boxed-primitive "^1.0.2" undici@^5.0.0: - version "5.26.3" - resolved "https://registry.yarnpkg.com/undici/-/undici-5.26.3.tgz#ab3527b3d5bb25b12f898dfd22165d472dd71b79" - integrity sha512-H7n2zmKEWgOllKkIUkLvFmsJQj062lSm3uA4EYApG8gLuiOM0/go9bIoC3HVaSnfg4xunowDE2i9p8drkXuvDw== + version "5.28.3" + resolved "https://registry.yarnpkg.com/undici/-/undici-5.28.3.tgz#a731e0eff2c3fcfd41c1169a869062be222d1e5b" + integrity sha512-3ItfzbrhDlINjaP0duwnNsKpDQk3acHI3gVJ1z4fmwMK31k5G9OVIAMLSIaP6w4FaGkaAkN6zaQO9LUvZ1t7VA== dependencies: "@fastify/busboy" "^2.0.0" From 8ca2dab3d64eb0fcfe158901bd29f47a37b3b872 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Mon, 18 Mar 2024 13:53:45 -0400 Subject: [PATCH 48/57] Frontend: Update search bar to allow search by position only (#382) * Rename from GeneSearch to GeneNameSearch * Move search component to separate folder * Create GenePositionSearch component * Update validator to fail on first rule break * Create combined search bar * Fix no variants found error * Use combobox instead of select element * WIP making new dropdown for search bar styling * Fix styling * Adjust spacing * Formatting + linting * Server formatting --- react/src/components/ComboBox.tsx | 3 +- react/src/components/ErrorText.tsx | 19 +++ .../components/Search/GeneCombinedSearch.tsx | 147 ++++++++++++++++++ .../GeneNameSearch.tsx} | 25 +-- .../components/Search/GenePositionSearch.tsx | 67 ++++++++ react/src/components/index.tsx | 4 +- react/src/hooks/useFormReducer.ts | 20 +-- react/src/pages/VariantQueryPage.tsx | 79 +++++++--- react/src/utils/isCanonicalRegion.tsx | 4 + .../adapters/g4rdAdapter.ts | 14 +- .../utils/fetchPhenotipsVariants.ts | 2 +- 11 files changed, 333 insertions(+), 51 deletions(-) create mode 100644 react/src/components/ErrorText.tsx create mode 100644 react/src/components/Search/GeneCombinedSearch.tsx rename react/src/components/{GeneSearch.tsx => Search/GeneNameSearch.tsx} (91%) create mode 100644 react/src/components/Search/GenePositionSearch.tsx create mode 100644 react/src/utils/isCanonicalRegion.tsx diff --git a/react/src/components/ComboBox.tsx b/react/src/components/ComboBox.tsx index fb497f1d..3918ea15 100644 --- a/react/src/components/ComboBox.tsx +++ b/react/src/components/ComboBox.tsx @@ -30,7 +30,6 @@ interface ComboBoxProps { } export const Wrapper = styled(Flex)` - position: relative min-height: 38px; flex-wrap: wrap; flex-grow: 0; @@ -128,7 +127,7 @@ export default function ComboBox({ )} - + {open && ( props.theme.space[2]}; + padding: ${props => props.theme.space[4]} 0.75rem 0; +`; + +const ErrorText: React.FC<{ error?: string }> = ({ error }) => + error ? ( + + + {error} + + + ) : null; + +export default ErrorText; diff --git a/react/src/components/Search/GeneCombinedSearch.tsx b/react/src/components/Search/GeneCombinedSearch.tsx new file mode 100644 index 00000000..7175dcdd --- /dev/null +++ b/react/src/components/Search/GeneCombinedSearch.tsx @@ -0,0 +1,147 @@ +import React, { useState } from 'react'; +import { FaCaretDown } from 'react-icons/fa'; +import styled from 'styled-components/macro'; +import { useClickAway } from '../../hooks'; +import { AssemblyId } from '../../types'; +import { Flex } from '../Layout'; +import SelectableList, { SelectableListItem, SelectableListWrapper } from '../SelectableList'; +import GeneNameSearch, { GeneSelectionValue } from './GeneNameSearch'; +import GenePositionSearch from './GenePositionSearch'; + +const SearchWrapper = styled(Flex)` + position: relative + min-height: 40px; + flex-wrap: nowrap; + flex-grow: 1; + position: relative; + width: 100%; +`; + +const DropdownWrapper = styled(Flex)` + position: relative; + min-height: 38px; + flex-grow: 0; +`; + +const DropdownHeader = styled(Flex)` + background-color: ${props => props.theme.background.main}; + border: ${props => props.theme.borders.thin}; + border-color: ${props => props.theme.colors.muted}; + border-radius: ${props => props.theme.radii.base}; + box-shadow: ${props => props.theme.boxShadow}; + color: ${props => props.theme.colors.muted}; + padding: 0 ${props => props.theme.space[4]}; + flex-wrap: nowrap; + text-wrap: nowrap; + overflow: hidden; + white-space: nowrap; + min-height: 40px; + align-items: center; + justify-content: space-between; + cursor: pointer; +`; + +const DropdownHeaderText = styled.div` + color: ${props => props.theme.colors.text}; + cursor: pointer; + font-size: 14px; +`; + +interface DropdownProps { + options: SelectableListItem[]; + value: string; + onSelect: (option: string) => void; +} + +/** + * Dropdown component for selecting search type. + */ +const Dropdown: React.FC = props => { + // ComboBox styling is too deep, so we need our own dropdown + + const [open, setOpen] = useState(false); + + const ignoreRef = React.useRef() as React.MutableRefObject; + const ref = React.useRef() as React.MutableRefObject; + + useClickAway(ref, () => setOpen(false), ignoreRef); + + console.log(JSON.stringify(props)); + + return ( + + setOpen(true)}> + {props.value} + + + + {open && ( + { + props.onSelect(item as string); + setOpen(false); + }} + /> + )} + + + ); +}; + +interface GeneCombinedSearchProps { + assembly: AssemblyId; + geneName: string; + onNameChange: (geneName: string) => void; + onNameSelect: (gene: GeneSelectionValue) => void; + genePosition: string; + onPositionChange: (genePosition: string) => void; + onError?: (errorText: string | undefined) => void; +} + +const OPTIONS = ['Gene Name', 'Position']; + +/** + * Combined search component for searching by gene name or by position. + * Contains a dropdown integrated into the search bar where the user can + * switch between search modes. + */ +const GeneCombinedSearch: React.FC = props => { + const [searchMode, setSearchMode] = useState(OPTIONS[0]); + + return ( + + ({ + id, + value: a, + label: a, + }))} + onSelect={option => setSearchMode(option)} + value={searchMode} + /> + {searchMode === 'Gene Name' && ( + + )} + {searchMode === 'Position' && ( + + )} + + ); +}; + +export default GeneCombinedSearch; diff --git a/react/src/components/GeneSearch.tsx b/react/src/components/Search/GeneNameSearch.tsx similarity index 91% rename from react/src/components/GeneSearch.tsx rename to react/src/components/Search/GeneNameSearch.tsx index 42491738..4861b5a3 100644 --- a/react/src/components/GeneSearch.tsx +++ b/react/src/components/Search/GeneNameSearch.tsx @@ -1,11 +1,12 @@ import React, { useCallback, useEffect, useState } from 'react'; import { NetworkStatus } from '@apollo/client'; import { useAsyncDebounce } from 'react-table'; -import { useFetchAutocompleteQuery } from '../apollo/hooks'; -import { Background, Typography } from '../components'; -import { AssemblyId } from '../types'; -import ComboBox from './ComboBox'; -import { SelectableListItem } from './SelectableList'; +import { Background, Typography } from '..'; +import { useFetchAutocompleteQuery } from '../../apollo/hooks'; +import { AssemblyId } from '../../types'; +import isCanonicalRegion from '../../utils/isCanonicalRegion'; +import ComboBox from '../ComboBox'; +import { SelectableListItem } from '../SelectableList'; interface HitPosition { chr: string; start: number; @@ -30,17 +31,19 @@ export interface GeneSelectionValue { position: string; } -interface GeneSearchProps { +interface GeneNameSearchProps { assembly: AssemblyId; geneName: string; onSelect: (gene: GeneSelectionValue) => void; onChange: (geneName: string) => void; } -const isCanonicalRegion = (chr: string) => - ['X', 'Y', ...Array.from({ length: 22 }, (_, i) => (i + 1).toString())].includes(chr); - -const GeneSearch: React.FC = ({ assembly, geneName, onChange, onSelect }) => { +const GeneNameSearch: React.FC = ({ + assembly, + geneName, + onChange, + onSelect, +}) => { const [options, setOptions] = useState[]>([]); const [ @@ -164,4 +167,4 @@ const GeneSearch: React.FC = ({ assembly, geneName, onChange, o ); }; -export default GeneSearch; +export default GeneNameSearch; diff --git a/react/src/components/Search/GenePositionSearch.tsx b/react/src/components/Search/GenePositionSearch.tsx new file mode 100644 index 00000000..5b41adcc --- /dev/null +++ b/react/src/components/Search/GenePositionSearch.tsx @@ -0,0 +1,67 @@ +import React from 'react'; +import styled from 'styled-components/macro'; +import { Flex, Input } from '..'; +import isCanonicalRegion from '../../utils/isCanonicalRegion'; + +export const Wrapper = styled(Flex)` + position: relative + min-height: 38px; + flex-wrap: nowrap; + flex-shrink: 1; + position: relative; + width: 100%; +`; +interface GenePositionSearchProps { + position: string; + onChange: (position: string) => void; + onError?: (errorText: string | undefined) => void; +} + +const GenePositionSearch: React.FC = props => { + // Update error text based on position format + const validatePosition = (position: string) => { + position = position.replaceAll(',', ''); + if (position === '') { + return undefined; + } + const chromStartEnd = position.split(':'); + if (chromStartEnd.length !== 2) { + return "Invalid format: expected 1 ':' separator between chromosome and start-end"; + } + + const [chrom, region] = chromStartEnd; + const startEnd = region.split('-'); + if (startEnd.length !== 2) { + return "Invalid format: expected 1 '-' separator between start and end positions"; + } + if (!isCanonicalRegion(chrom)) { + return "Invalid chromosome: expected '1'-'22', 'X' or 'Y'"; + } + + let [start, end] = startEnd.map(s => Number(s.replaceAll(',', ''))); + if (start > end) { + return 'Invalid region: start position should be less than or equal to end position'; + } + return undefined; + }; + + const handlePositionChange = (position: string) => { + if (props.onError) props.onError(validatePosition(position)); + props.onChange(position); + }; + + return ( + <> + + handlePositionChange(e.currentTarget.value)} + value={props.position} + placeholder="eg. 1:10,000,000-20,000,000" + /> + + + ); +}; + +export default GenePositionSearch; diff --git a/react/src/components/index.tsx b/react/src/components/index.tsx index 3eb6479b..d232f1e4 100644 --- a/react/src/components/index.tsx +++ b/react/src/components/index.tsx @@ -14,7 +14,6 @@ import ErrorProvider, { } from './Error/ErrorProvider'; import ErrorFallback from './ErrorFallback'; import ErrorIndicator from './ErrorIndicator'; -import GeneSearch from './GeneSearch'; import IconButton from './IconButton'; import Input from './Input'; import { Background, Body, ButtonWrapper, Column, Container, Flex, InlineFlex } from './Layout'; @@ -22,6 +21,7 @@ import Modal from './Modal/Modal'; import Navbar from './Navbar/Navbar'; import Popover from './Popover/Popover'; import { RequiredIndicator, RequiredTextBox } from './RequiredIndicator'; +import GeneCombinedSearch from './Search/GeneCombinedSearch'; import SelectableList, { SelectableListWrapper } from './SelectableList'; import Snackbar from './Snackbar/Snackbar'; import Spinner from './Spinner'; @@ -50,7 +50,7 @@ export { ErrorFallback, ErrorIndicator, Flex, - GeneSearch, + GeneCombinedSearch, InlineFlex, IconButton, Input, diff --git a/react/src/hooks/useFormReducer.ts b/react/src/hooks/useFormReducer.ts index bbfe8a31..bb1f49e5 100644 --- a/react/src/hooks/useFormReducer.ts +++ b/react/src/hooks/useFormReducer.ts @@ -113,16 +113,18 @@ const validateField = ( } } let error: Error | null = null; - validator[field]?.rules?.forEach(rule => { - if (!rule.valid(state, value) && getFieldRequired(state, field, validator)) { - const { displayError = true, error: errorText } = rule; - error = { - displayError, - errorText, - }; - return; + if (validator[field]?.rules !== undefined) { + for (let rule of validator[field]!.rules!) { + if (!rule.valid(state, value) && getFieldRequired(state, field, validator)) { + const { displayError = true, error: errorText } = rule; + error = { + displayError, + errorText, + }; + break; + } } - }); + } return error; }; diff --git a/react/src/pages/VariantQueryPage.tsx b/react/src/pages/VariantQueryPage.tsx index c410d34e..d9e1a418 100644 --- a/react/src/pages/VariantQueryPage.tsx +++ b/react/src/pages/VariantQueryPage.tsx @@ -1,7 +1,6 @@ import React from 'react'; import { NetworkStatus, useApolloClient } from '@apollo/client'; import { RiInformationFill } from 'react-icons/ri'; -import styled from 'styled-components/macro'; import { useFetchVariantsQuery } from '../apollo/hooks'; import { Background, @@ -13,7 +12,7 @@ import { ComboBox, ErrorIndicator, Flex, - GeneSearch, + GeneCombinedSearch, Input, RequiredIndicator, RequiredTextBox, @@ -22,6 +21,7 @@ import { Tooltip, Typography, } from '../components'; +import ErrorText from '../components/ErrorText'; import { IconPadder } from '../components/Table/Table.styles'; import SOURCES from '../constants/sources'; import theme from '../constants/theme'; @@ -29,6 +29,7 @@ import { useErrorContext, useFormReducer } from '../hooks'; import { formIsValid, FormState, Validator } from '../hooks/useFormReducer'; import { AssemblyId } from '../types'; import { formatErrorMessage, resolveAssembly } from '../utils'; +import isCanonicalRegion from '../utils/isCanonicalRegion'; const queryOptionsFormValidator: Validator = { assemblyId: { @@ -36,7 +37,7 @@ const queryOptionsFormValidator: Validator = { displayRequiredError: false, }, gene: { - required: true, + required: false, displayRequiredError: false, rules: [ { @@ -46,6 +47,35 @@ const queryOptionsFormValidator: Validator = { }, ], }, + position: { + required: true, + displayRequiredError: false, + rules: [ + { + valid: state => state.position.value.split(':').length === 2, + error: "Invalid format: expected 1 ':' separator between chromosome and start-end", + }, + { + valid: state => state.position.value.split(':').at(1)?.split('-').length === 2, + error: "Invalid format: expected 1 '-' separator between start and end positions", + }, + { + valid: state => isCanonicalRegion(state.position.value.split(':').at(0)!), + error: "Invalid format: chromosome expected between 1-22, or 'X' or 'Y'", + }, + { + valid: state => { + let [start, end] = state.position.value + .split(':') + .at(1)! + .split('-')! + .map(num => Number(num.replaceAll(',', ''))); + return start <= end; + }, + error: 'Invalid format: start position cannot be greater than end position', + }, + ], + }, maxFrequency: { required: true, displayRequiredError: false, @@ -84,20 +114,6 @@ interface QueryOptionsFormState { sources: string[]; } -const ErrorWrapper = styled.div` - margin: 0 0 ${props => props.theme.space[2]}; - padding: ${props => props.theme.space[4]} 0.75rem 0; -`; - -const ErrorText: React.FC<{ error?: string }> = ({ error }) => - error ? ( - - - {error} - - - ) : null; - const VariantQueryPage: React.FC<{}> = () => { const [queryOptionsForm, updateQueryOptionsForm, resetQueryOptionsForm] = useFormReducer( @@ -120,7 +136,7 @@ const VariantQueryPage: React.FC<{}> = () => { }, gene: { geneName: queryOptionsForm.gene.value, - position: queryOptionsForm.position.value, + position: queryOptionsForm.position.value.replaceAll(',', ''), }, sources: queryOptionsForm.sources.value, }, @@ -175,7 +191,7 @@ const VariantQueryPage: React.FC<{}> = () => { @@ -201,24 +217,37 @@ const VariantQueryPage: React.FC<{}> = () => { alignItems="flex-start" style={{ flexGrow: 1, - minWidth: 200, + minWidth: 240, }} > - Gene Name + Gene Name / Position - updateQueryOptionsForm({ gene: geneName })} - onSelect={({ name, position }) => + onNameChange={geneName => + updateQueryOptionsForm({ gene: geneName }) + } + onNameSelect={({ name, position }) => updateQueryOptionsForm({ gene: name, position, }) } + genePosition={queryOptionsForm.position.value} + onPositionChange={position => + updateQueryOptionsForm({ + gene: '', + position, + }) + } + /> + - + ['X', 'Y', ...Array.from({ length: 22 }, (_, i) => (i + 1).toString())].includes(chr); + +export default isCanonicalRegion; diff --git a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts index 92287721..dacae973 100644 --- a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts +++ b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts @@ -70,7 +70,7 @@ const _getG4rdNodeQuery = async ({ ); // Get patients info - if (G4RDVariants) { + if (G4RDVariants && G4RDVariants.length > 0) { logger.debug(`G4RDVariants length: ${G4RDVariants.length}`); let individualIds = G4RDVariants.flatMap(v => v.individualIds).filter(Boolean); // Filter out undefined and null values. @@ -118,6 +118,18 @@ const _getG4rdNodeQuery = async ({ }); } } + if (G4RDVariants?.length === 0) { + // No variants, hence no point in processing anything else + return { + data: [], + source: SOURCE_NAME, + error: { + code: 404, + id: uuidv4(), + message: 'No variants found matching your query.', + }, + }; + } } catch (e: any) { logger.error(e); G4RDNodeQueryError = e; diff --git a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts index 2748dfd1..755a5f95 100644 --- a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts +++ b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts @@ -83,7 +83,7 @@ const fetchPhenotipsVariants = async ( } else { if (collectedResults.length === 0) { logger.warn(`Variant data does not exist at position ${JSON.stringify(position)}`); - logger.debug(JSON.stringify(variantQueryResponse)); + logger.debug(JSON.stringify(variantQueryResponse.data)); return []; } else { // it would be really weird if this happened. the error existed on one page but not the next? From 6a66d680fa0a449682dfbdc66e63281f085e6624 Mon Sep 17 00:00:00 2001 From: Mackenzie Ian Frew Date: Mon, 18 Mar 2024 14:57:56 -0400 Subject: [PATCH 49/57] React: Remove errant console.log --- react/src/components/Search/GeneCombinedSearch.tsx | 2 -- 1 file changed, 2 deletions(-) diff --git a/react/src/components/Search/GeneCombinedSearch.tsx b/react/src/components/Search/GeneCombinedSearch.tsx index 7175dcdd..64351bb8 100644 --- a/react/src/components/Search/GeneCombinedSearch.tsx +++ b/react/src/components/Search/GeneCombinedSearch.tsx @@ -66,8 +66,6 @@ const Dropdown: React.FC = props => { useClickAway(ref, () => setOpen(false), ignoreRef); - console.log(JSON.stringify(props)); - return ( setOpen(true)}> From 5ceb6e959d5c8e0233d531963786108ec0cb5db2 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Mon, 18 Mar 2024 16:45:49 -0400 Subject: [PATCH 50/57] React/Server: Add Gene Name to results table (#383) * Add Gene Name to results table * Formatting --- react/src/components/Table/Table.tsx | 8 +++++++- react/src/utils/tableHelpers.ts | 1 + .../resolvers/getVariantsResolver/adapters/cmhAdapter.ts | 1 + .../resolvers/getVariantsResolver/adapters/g4rdAdapter.ts | 1 + .../getVariantsResolver/adapters/remoteTestNodeAdapter.ts | 1 + 5 files changed, 11 insertions(+), 1 deletion(-) diff --git a/react/src/components/Table/Table.tsx b/react/src/components/Table/Table.tsx index d7419589..0098adf4 100644 --- a/react/src/components/Table/Table.tsx +++ b/react/src/components/Table/Table.tsx @@ -62,7 +62,7 @@ export type FlattenedQueryResponse = Omit & CallsetInfoFields & - VariantResponseInfoFields & { source: string; diseases: string }; + VariantResponseInfoFields & { source: string; diseases: string; geneName: string }; export interface ResultTableColumns extends FlattenedQueryResponse { maleCount: number; emptyCaseDetails: string; @@ -142,6 +142,12 @@ const Table: React.FC = ({ variantData }) => { disableFilters: true, disableSortBy: true, }, + { + accessor: 'geneName', + id: 'geneName', + Header: 'Gene Name', + width: getColumnWidth('Gene Name'), + }, { accessor: 'start', id: 'start', diff --git a/react/src/utils/tableHelpers.ts b/react/src/utils/tableHelpers.ts index e517c510..05c9ac14 100644 --- a/react/src/utils/tableHelpers.ts +++ b/react/src/utils/tableHelpers.ts @@ -60,6 +60,7 @@ const addAdditionalFieldsAndFormatNulls = ( gnomadHom: results.gnomadHom || 0, // gnomadHet: results.gnomadHet || 0, maleCount: 0, + geneName: !!results.geneName ? results.geneName! : 'Not Specified', }); export const calculateColumnWidth = ( diff --git a/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts index 3d8c4dc4..0b89cbe7 100644 --- a/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts +++ b/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts @@ -283,6 +283,7 @@ export const transformCMHQueryResponse: ResultTransformer = tim ref: r.variant.ref, start: r.variant.start, chromosome: r.variant.chromosome, + info: r.variant.info, }; const familyId: string = familyIds[individualId]; diff --git a/server/src/resolvers/getVariantsResolver/adapters/remoteTestNodeAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/remoteTestNodeAdapter.ts index c88b6d3e..c1960461 100644 --- a/server/src/resolvers/getVariantsResolver/adapters/remoteTestNodeAdapter.ts +++ b/server/src/resolvers/getVariantsResolver/adapters/remoteTestNodeAdapter.ts @@ -163,6 +163,7 @@ const transformStagerQueryResponse: ResultTransformer Date: Mon, 15 Apr 2024 15:16:02 -0400 Subject: [PATCH 51/57] Server: implement support for Pagination API on CMH (#390) * Update /rest/variants/match request * Do the pagination * Update to support CMH * Fix 2nd page fetch fail * Add liftover for positions * Fix requests --- .../adapters/cmhAdapter.ts | 221 +++++++++--------- .../adapters/g4rdAdapter.ts | 30 ++- .../getVariantsResolver.ts | 2 +- .../utils/fetchPhenotipsPatients.ts | 4 +- .../utils/fetchPhenotipsVariants.ts | 31 ++- .../getVariantsResolver/utils/liftOver.ts | 125 ++++++---- 6 files changed, 247 insertions(+), 166 deletions(-) diff --git a/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts index 0b89cbe7..f49b77ae 100644 --- a/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts +++ b/server/src/resolvers/getVariantsResolver/adapters/cmhAdapter.ts @@ -1,4 +1,4 @@ -import axios, { AxiosError, AxiosResponse } from 'axios'; +import axios, { AxiosError } from 'axios'; import jwtDecode from 'jwt-decode'; import { URLSearchParams } from 'url'; import { v4 as uuidv4 } from 'uuid'; @@ -12,16 +12,21 @@ import { VariantResponseFields, G4RDFamilyQueryResult, G4RDPatientQueryResult, - G4RDVariantQueryResult, Disorder, IndividualInfoFields, PhenotypicFeaturesFields, NonStandardFeature, Feature, + PTVariantArray, } from '../../../types'; import { getFromCache, putInCache } from '../../../utils/cache'; import { timeit, timeitAsync } from '../../../utils/timeit'; import resolveAssembly from '../utils/resolveAssembly'; +import fetchPhenotipsVariants from '../utils/fetchPhenotipsVariants'; +import fetchPhenotipsPatients from '../utils/fetchPhenotipsPatients'; +import { QueryResponseError } from '../utils/queryResponseError'; +import resolveChromosome from '../utils/resolveChromosome'; +import { liftoverOne } from '../utils/liftOver'; /* eslint-disable camelcase */ @@ -45,8 +50,8 @@ const _getCMHNodeQuery = async ({ input: { gene: geneInput, variant }, }: QueryInput): Promise => { let CMHNodeQueryError: CMHNodeQueryError | null = null; - let CMHVariantQueryResponse: null | AxiosResponse = null; - let CMHPatientQueryResponse: null | AxiosResponse = null; + let CMHVariants: null | PTVariantArray = null; + let CMHPatientQueryResponse: null | G4RDPatientQueryResult[] = null; const FamilyIds: null | Record = {}; // let Authorization = ''; try { @@ -60,52 +65,57 @@ const _getCMHNodeQuery = async ({ source: SOURCE_NAME, }; } - const url = `${process.env.CMH_URL}/rest/variants/match`; + + if (!variant.assemblyId.includes('38')) { + // convert to GRCh38 if the position isn't in 38 + const pos = resolveChromosome(geneInput.position); + const lifted = await liftoverOne( + { + chromosome: pos.chromosome, + start: Number(pos.start), + end: Number(pos.end), + }, + 'GRCh38', + variant.assemblyId + ); + geneInput.position = `${pos.chromosome}:${lifted.start}-${lifted.end}`; + } + /* eslint-disable @typescript-eslint/no-unused-vars */ - const { position, ...gene } = geneInput; variant.assemblyId = 'GRCh38'; + // the replacement try { - CMHVariantQueryResponse = await axios.post( - url, + CMHVariants = await fetchPhenotipsVariants( + process.env.CMH_URL as string, + geneInput, + variant, + getAuthHeader, { - gene, - variant, - }, - { - headers: { - Authorization, - 'Content-Type': 'application/json', - Accept: 'application/json', - 'X-Gene42-Secret': `${process.env.CMH_GENE42_SECRET}`, // - }, + 'X-Gene42-Secret': `${process.env.CMH_GENE42_SECRET}`, } ); // Get patients info - if (CMHVariantQueryResponse) { - let individualIds = CMHVariantQueryResponse.data.results - .map(v => v.individual.individualId!) - .filter(Boolean); // Filter out undefined and null values. + if (CMHVariants && CMHVariants.length > 0) { + let individualIds = CMHVariants.flatMap(v => v.individualIds).filter(Boolean); // Filter out undefined and null values. // Get all unique individual Ids. individualIds = [...new Set(individualIds)]; if (individualIds.length > 0) { - const patientUrl = `${process.env.CMH_URL}/rest/patients/fetch?${individualIds - .map(id => `id=${id}`) - .join('&')}`; - - CMHPatientQueryResponse = await axios.get( - new URL(patientUrl).toString(), - { - headers: { - Authorization, - 'Content-Type': 'application/json', - Accept: 'application/json', + try { + CMHPatientQueryResponse = await fetchPhenotipsPatients( + process.env.CMH_URL!, + individualIds, + getAuthHeader, + { 'X-Gene42-Secret': `${process.env.CMH_GENE42_SECRET}`, - }, - } - ); + } + ); + } catch (e) { + logger.error(JSON.stringify(e)); + CMHPatientQueryResponse = []; + } // Get Family Id for each patient. const patientFamily = axios.create({ @@ -133,14 +143,18 @@ const _getCMHNodeQuery = async ({ } } } catch (e: any) { + if (e instanceof QueryResponseError) { + e.source = SOURCE_NAME; + } logger.error(e); + logger.debug(JSON.stringify(e)); CMHNodeQueryError = e; } return { data: transformCMHQueryResponse( - (CMHVariantQueryResponse?.data as G4RDVariantQueryResult) || [], - (CMHPatientQueryResponse?.data as G4RDPatientQueryResult) || [], + (CMHVariants as PTVariantArray) || [], + (CMHPatientQueryResponse as G4RDPatientQueryResult[]) || [], FamilyIds ), error: transformCMHNodeErrorResponse(CMHNodeQueryError), @@ -204,99 +218,92 @@ export const transformCMHNodeErrorResponse: ErrorTransformer const isObserved = (feature: Feature | NonStandardFeature) => feature.observed === 'yes' ? true : feature.observed === 'no' ? false : undefined; -export const transformCMHQueryResponse: ResultTransformer = timeit( +export const transformCMHQueryResponse: ResultTransformer = timeit( 'transformCMHQueryResponse' )( ( - variantResponse: G4RDVariantQueryResult, + variants: PTVariantArray, patientResponse: G4RDPatientQueryResult[], familyIds: Record ) => { const individualIdsMap = Object.fromEntries(patientResponse.map(p => [p.id, p])); - return (variantResponse.results || []).map(r => { + return (variants || []).flatMap(r => { /* eslint-disable @typescript-eslint/no-unused-vars */ r.variant.assemblyId = resolveAssembly(r.variant.assemblyId); - const { individual, contactInfo } = r; + const { individualIds } = r; - const patient = individual.individualId ? individualIdsMap[individual.individualId] : null; + return individualIds.map(individualId => { + const patient = individualIdsMap[individualId]; - let info: IndividualInfoFields = {}; - let ethnicity: string = ''; - let disorders: Disorder[] = []; - let phenotypicFeatures: PhenotypicFeaturesFields[] = individual.phenotypicFeatures || []; + const contactInfo: string = patient.contact + ? patient.contact.map(c => c.name).join(', ') + : ''; - if (patient) { - const candidateGene = (patient.genes ?? []).map(g => g.gene).join('\n'); - const classifications = (patient.genes ?? []).map(g => g.status).join('\n'); - const diagnosis = patient.clinicalStatus; - const solved = patient.solved ? patient.solved.status : ''; - const clinicalStatus = patient.clinicalStatus; - disorders = patient.disorders.filter(({ label }) => label !== 'affected') as Disorder[]; - ethnicity = Object.values(patient.ethnicity) - .flat() - .map(p => p.trim()) - .join(', '); - info = { - solved, - candidateGene, - diagnosis, - classifications, - clinicalStatus, - disorders, - }; - // variant response contains all phenotypic features listed, - // even if some of them are explicitly _not_ observed by clinician and recorded as such - if (individual.phenotypicFeatures !== null && individual.phenotypicFeatures !== undefined) { + let info: IndividualInfoFields = {}; + let ethnicity: string = ''; + let disorders: Disorder[] = []; + let phenotypicFeatures: PhenotypicFeaturesFields[] = []; + + if (patient) { + const candidateGene = (patient.genes ?? []).map(g => g.gene).join('\n'); + const classifications = (patient.genes ?? []).map(g => g.status).join('\n'); + const diagnosis = patient.clinicalStatus; + const solved = patient.solved ? patient.solved.status : ''; + const clinicalStatus = patient.clinicalStatus; + disorders = patient.disorders.filter(({ label }) => label !== 'affected') as Disorder[]; + ethnicity = Object.values(patient.ethnicity) + .flat() + .map(p => p.trim()) + .join(', '); + info = { + solved, + candidateGene, + diagnosis, + classifications, + clinicalStatus, + disorders, + }; + // variant response contains all phenotypic features listed, + // even if some of them are explicitly _not_ observed by clinician and recorded as such const features = [...(patient.features ?? []), ...(patient.nonstandard_features ?? [])]; - const detailedFeatures = individual.phenotypicFeatures; - // build list of features the safe way - const detailedFeatureMap = Object.fromEntries( - detailedFeatures.map(feat => [feat.phenotypeId, feat]) - ); const finalFeatures: PhenotypicFeaturesFields[] = features.map(feat => { - if (feat.id === undefined) { - return { - ageOfOnset: null, - dateOfOnset: null, - levelSeverity: null, - onsetType: null, - phenotypeId: feat.id, - phenotypeLabel: feat.label, - observed: isObserved(feat), - }; - } return { - ...detailedFeatureMap[feat.id], + // ageOfOnset: null, + // dateOfOnset: null, + levelSeverity: null, + // onsetType: null, + phenotypeId: feat.id, + phenotypeLabel: feat.label, observed: isObserved(feat), }; }); phenotypicFeatures = finalFeatures; } - } - const variant: VariantResponseFields = { - alt: r.variant.alt, - assemblyId: r.variant.assemblyId, - callsets: r.variant.callsets, - end: r.variant.end, - ref: r.variant.ref, - start: r.variant.start, - chromosome: r.variant.chromosome, - info: r.variant.info, - }; + const variant: VariantResponseFields = { + alt: r.variant.alt, + assemblyId: r.variant.assemblyId, + callsets: r.variant.callsets, + end: r.variant.end, + ref: r.variant.ref, + start: r.variant.start, + chromosome: r.variant.chromosome, + info: r.variant.info, + }; - let familyId: string = ''; - if (individual.individualId) familyId = familyIds[individual.individualId]; + const familyId: string = familyIds[individualId]; - const individualResponseFields: IndividualResponseFields = { - ...individual, - ethnicity, - info, - familyId, - phenotypicFeatures, - }; - return { individual: individualResponseFields, variant, contactInfo, source: SOURCE_NAME }; + const individualResponseFields: IndividualResponseFields = { + sex: patient.sex, + ethnicity, + info, + familyId, + phenotypicFeatures, + individualId, + }; + return { individual: individualResponseFields, variant, contactInfo, source: SOURCE_NAME }; + }); }); } ); diff --git a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts index c561de1a..92d578a0 100644 --- a/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts +++ b/server/src/resolvers/getVariantsResolver/adapters/g4rdAdapter.ts @@ -24,6 +24,9 @@ import { timeit, timeitAsync } from '../../../utils/timeit'; import resolveAssembly from '../utils/resolveAssembly'; import fetchPhenotipsVariants from '../utils/fetchPhenotipsVariants'; import fetchPhenotipsPatients from '../utils/fetchPhenotipsPatients'; +import { QueryResponseError } from '../utils/queryResponseError'; +import { liftoverOne } from '../utils/liftOver'; +import resolveChromosome from '../utils/resolveChromosome'; /* eslint-disable camelcase */ @@ -55,6 +58,22 @@ const _getG4rdNodeQuery = async ({ source: SOURCE_NAME, }; } + + if (variant.assemblyId.includes('38')) { + // convert to 37 if the position is in 38 + const pos = resolveChromosome(geneInput.position); + const lifted = await liftoverOne( + { + chromosome: pos.chromosome, + start: Number(pos.start), + end: Number(pos.end), + }, + 'GRCh37', + variant.assemblyId + ); + geneInput.position = `${pos.chromosome}:${lifted.start}-${lifted.end}`; + } + /* eslint-disable @typescript-eslint/no-unused-vars */ variant.assemblyId = 'GRCh37'; // For g4rd node, assemblyId is a required field as specified in this sample request: @@ -71,7 +90,6 @@ const _getG4rdNodeQuery = async ({ // Get patients info if (G4RDVariants && G4RDVariants.length > 0) { - logger.debug(`G4RDVariants length: ${G4RDVariants.length}`); let individualIds = G4RDVariants.flatMap(v => v.individualIds).filter(Boolean); // Filter out undefined and null values. // Get all unique individual Ids. @@ -98,13 +116,8 @@ const _getG4rdNodeQuery = async ({ }, }); - logger.debug('Begin fetching family IDs'); - const familyResponses = await Promise.allSettled( individualIds.map((id, i) => { - if (i % 50 === 0 || i === individualIds.length - 1) { - logger.debug(`Fetching family ${i + 1} of ${individualIds.length}`); - } return patientFamily.get( new URL(`${process.env.G4RD_URL}/rest/patients/${id}/family`).toString() ); @@ -131,6 +144,9 @@ const _getG4rdNodeQuery = async ({ }; } } catch (e: any) { + if (e instanceof QueryResponseError) { + e.source = SOURCE_NAME; + } logger.error(e); G4RDNodeQueryError = e; } @@ -230,7 +246,7 @@ export const transformG4RDQueryResponse: ResultTransformer = tim const patient = individualIdsMap[individualId]; const contactInfo: string = patient.contact - ? patient.contact.map(c => c.name).join(' ,') + ? patient.contact.map(c => c.name).join(', ') : ''; let info: IndividualInfoFields = {}; diff --git a/server/src/resolvers/getVariantsResolver/getVariantsResolver.ts b/server/src/resolvers/getVariantsResolver/getVariantsResolver.ts index c2e9e480..e2e3c43a 100644 --- a/server/src/resolvers/getVariantsResolver/getVariantsResolver.ts +++ b/server/src/resolvers/getVariantsResolver/getVariantsResolver.ts @@ -14,7 +14,7 @@ import fetchCaddAnnotations from './utils/fetchCaddAnnotations'; import annotateCadd from './utils/annotateCadd'; import fetchGnomadAnnotations from './utils/fetchGnomadAnnotations'; import annotateGnomad from './utils/annotateGnomad'; -import liftover from './utils/liftOver'; +import { liftover } from './utils/liftOver'; import { QueryResponseError } from './utils/queryResponseError'; import getG4rdNodeQuery from './adapters/g4rdAdapter'; import { timeitAsync } from '../../utils/timeit'; diff --git a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsPatients.ts b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsPatients.ts index 9d28cd5a..df32bcae 100644 --- a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsPatients.ts +++ b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsPatients.ts @@ -19,7 +19,8 @@ const COUNT = 50; const fetchPhenotipsPatients = async ( baseUrl: string, individualIds: string[], - getAuthorization: () => Promise + getAuthorization: () => Promise, + additionalHeaders: { [k: string]: string } = {} ): Promise => { let currStart = 0; let currEnd = COUNT; @@ -44,6 +45,7 @@ const fetchPhenotipsPatients = async ( Authorization: await getAuthorization(), 'Content-Type': 'application/json', Accept: 'application/json', + ...additionalHeaders, }, } ); diff --git a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts index 755a5f95..fb2ff078 100644 --- a/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts +++ b/server/src/resolvers/getVariantsResolver/utils/fetchPhenotipsVariants.ts @@ -27,19 +27,25 @@ const fetchPhenotipsVariants = async ( baseUrl: string, gene: GeneQueryInput, variant: VariantQueryInput, - getAuthorization: () => Promise + getAuthorization: () => Promise, + additionalHeaders: { [k: string]: string } = {} ): Promise => { let currentPage = 1; let collectedResults: PTPaginatedVariantQueryResult['results'] = []; let maxResults = Infinity; const count = COUNT; const _position = resolveChromosome(gene.position); + const isGRCh38 = (['38', 'GRCh38', 'hg38'] as VariantQueryInput['assemblyId'][]).includes( + variant.assemblyId + ); + const chromosome = ['X', 'Y'].indexOf(_position.chromosome) !== -1 ? _position.chromosome : Number(_position.chromosome); + const position = { - chrom: chromosome, + chrom: isGRCh38 ? `chr${chromosome}` : chromosome, start: Number(_position.start), end: Number(_position.end), }; @@ -53,21 +59,24 @@ const fetchPhenotipsVariants = async ( ); do { try { + const payload = { + page: currentPage, + limit: count, + variant: { + ...variant, + position, + assemblyId: isGRCh38 ? 'GRCh38' : 'GRCh37', + }, + }; const variantQueryResponse = await axios.post( `${baseUrl}/rest/variants/match`, - { - page: currentPage, - limit: count, - variant: { - ...variant, - position, - }, - }, + payload, { headers: { Authorization: await getAuthorization(), 'Content-Type': 'application/json', Accept: 'application/json', + ...additionalHeaders, }, } ); @@ -95,7 +104,7 @@ const fetchPhenotipsVariants = async ( throw new QueryResponseError({ code: 500, message: 'Internal Server Error', - source: 'OSMP', + source: 'PhenoTips', // should be updated in error catch }); } } diff --git a/server/src/resolvers/getVariantsResolver/utils/liftOver.ts b/server/src/resolvers/getVariantsResolver/utils/liftOver.ts index eb722948..e4469d5e 100644 --- a/server/src/resolvers/getVariantsResolver/utils/liftOver.ts +++ b/server/src/resolvers/getVariantsResolver/utils/liftOver.ts @@ -5,6 +5,8 @@ import { AssemblyId, VariantQueryDataResult } from '../../../types'; import { timeitAsync } from '../../../utils/timeit'; const exec = require('util').promisify(require('child_process').exec); +type Position = { chromosome: string; start: number; end: number }; + const createTmpFile = async () => { const dir = await promises.mkdtemp(path.join(tmpdir(), 'liftover-')); return path.join(dir, 'temp'); @@ -24,59 +26,95 @@ const parseBedEnd = (bed: String) => .filter(l => !!l && !l.startsWith('#')) .map(v => v.split('\t')[2]); +/** + * Function wrapper for running liftOver with generic positions. + * + * @param positions List of positions. Do not convert to BED format in advance. + * @param desiredAssemblyId Desired assembly ID to convert to. Assumes conversion between hg19 and hg38. + * + * @returns Object containing lifted and unlifted positions, converted from BED format to position format. + */ +const _runLiftOver = async (positions: Position[], desiredAssemblyId: AssemblyId) => { + // Convert variants from JSON format to BED format. + // Note that position format is 1-based and BED format is half-open 0-based: https://genome.ucsc.edu/FAQ/FAQformat.html#format1 + const bedstring = positions + .map( + v => + `${v.chromosome.startsWith('chr') ? v.chromosome : 'chr' + v.chromosome}\t${v.start - 1}\t${ + v.end + }` + ) + .join('\n'); + const lifted = await createTmpFile(); + const unlifted = await createTmpFile(); + const bedfile = await createTmpFile(); + await promises.writeFile(bedfile, bedstring); + + let chain: string; + if (desiredAssemblyId.includes('38')) { + chain = '/home/node/hg19ToHg38.over.chain'; + } else { + chain = '/home/node/hg38ToHg19.over.chain'; + } + + const liftOverCommand = `liftOver ${bedfile} ${chain} ${lifted} ${unlifted}`; + try { + await exec(liftOverCommand); + const _liftedVars = await promises.readFile(lifted); + const _unliftedVars = await promises.readFile(unlifted); + const liftedVars = parseBedStart(_liftedVars.toString()); + const unliftedVars = parseBedStart(_unliftedVars.toString()); + const liftedVarsEnd = parseBedEnd(_liftedVars.toString()); + const unliftedVarsEnd = parseBedEnd(_unliftedVars.toString()); + + return { + lifted: liftedVars.map((start, i) => ({ + start: Number(start) + 1, + end: Number(liftedVarsEnd[i]), + })), + unlifted: unliftedVars.map((start, i) => ({ + start: Number(start) + 1, + end: Number(unliftedVarsEnd[i]), + })), + }; + } finally { + promises.rm(lifted, { force: true }); + promises.rm(unlifted, { force: true }); + promises.rm(bedfile, { force: true }); + } +}; + const liftover = timeitAsync('liftover')( async ( dataForAnnotation: VariantQueryDataResult[], dataForLiftover: VariantQueryDataResult[], assemblyIdInput: AssemblyId ) => { - // Convert variants from JSON format to BED format. - // Note that position format is 1-based and BED format is half-open 0-based: https://genome.ucsc.edu/FAQ/FAQformat.html#format1 - const bedstring = dataForLiftover - .map( - v => - `${ - // if coming from GRCh38, probably starts with chr already - v.variant.chromosome.startsWith('chr') - ? v.variant.chromosome - : 'chr' + v.variant.chromosome - }\t${v.variant.start - 1}\t${v.variant.end}` - ) - .join('\n'); - const lifted = await createTmpFile(); - const unlifted = await createTmpFile(); - const bedfile = await createTmpFile(); - await promises.writeFile(bedfile, bedstring); - - let chain: string; - if (assemblyIdInput === 'GRCh37') { - chain = '/home/node/hg38ToHg19.over.chain'; - } else { - chain = '/home/node/hg19ToHg38.over.chain'; - } - const liftOverCommand = `liftOver ${bedfile} ${chain} ${lifted} ${unlifted}`; try { - await exec(liftOverCommand); - const _liftedVars = await promises.readFile(lifted); - const _unliftedVars = await promises.readFile(unlifted); - const liftedVars = parseBedStart(_liftedVars.toString()); - const unliftedVars = parseBedStart(_unliftedVars.toString()); - const liftedVarsEnd = parseBedEnd(_liftedVars.toString()); + const positions: Position[] = dataForLiftover.map(v => ({ + chromosome: v.variant.chromosome, + start: v.variant.start, + end: v.variant.end, + })); + const { lifted: liftedVars, unlifted: unliftedVars } = await _runLiftOver( + positions, + assemblyIdInput + ); const unliftedMap: { [key: string]: boolean } = unliftedVars.reduce( - (acc, curr) => ({ ...acc, [curr]: true }), + (acc, curr) => ({ ...acc, [curr.start]: true }), {} ); const unliftedVariants: VariantQueryDataResult[] = []; // Merge lifted variants with dataForAnnotation. Filter unmapped variants. dataForLiftover.forEach((v, i) => { - if (unliftedMap[(v.variant.start - 1).toString()]) { + if (unliftedMap[v.variant.start.toString()]) { v.variant.assemblyIdCurrent = v.variant.assemblyId; unliftedVariants.push(v); } else { - v.variant.start = Number(liftedVars[i]) + 1; // Convert from BED format to position format. - v.variant.end = Number(liftedVarsEnd[i]); + v.variant.start = Number(liftedVars[i].start); // Convert from BED format to position format. + v.variant.end = Number(liftedVars[i].end); v.variant.assemblyIdCurrent = assemblyIdInput; dataForAnnotation.push(v); } @@ -97,9 +135,6 @@ const liftover = timeitAsync('liftover')( let annotationPosition = ''; if (dataForAnnotation.length > 0) annotationPosition = `${dataForAnnotation[0].variant.chromosome}:${geneStart}-${geneEnd}`; - promises.rm(lifted); - promises.rm(unlifted); - promises.rm(bedfile); return { dataForAnnotation, unliftedVariants, annotationPosition }; } catch (e) { @@ -109,4 +144,16 @@ const liftover = timeitAsync('liftover')( } ); -export default liftover; +const liftoverOne = timeitAsync('liftoverOne')( + async (position: Position, desiredAssemblyId: AssemblyId, currentAssemblyId: AssemblyId) => { + // skip if both IDs are the same + if (desiredAssemblyId.includes('38') === currentAssemblyId.includes('38')) { + return { start: position.start, end: position.end }; + } + + const { lifted, unlifted } = await _runLiftOver([position], desiredAssemblyId); + return [lifted, unlifted].flat()[0]; + } +); + +export { liftover, liftoverOne }; From c597d0fb1bea258ed3442b0ced1f0abec27b25c6 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Tue, 16 Apr 2024 17:51:02 -0400 Subject: [PATCH 52/57] CI/CD: Fix deprecated workflow commands in GitHub Actions workflows (#391) * Replace deprecated set-output with GITHUB_OUTPUT env file append * Update actions versions --- .github/workflows/node-prod.yml | 14 +++++++------- .github/workflows/node.yml | 22 +++++++++++----------- .github/workflows/react-prod.yml | 16 ++++++++-------- .github/workflows/react.yml | 16 ++++++++-------- 4 files changed, 34 insertions(+), 34 deletions(-) diff --git a/.github/workflows/node-prod.yml b/.github/workflows/node-prod.yml index f666dd67..a5a8932e 100644 --- a/.github/workflows/node-prod.yml +++ b/.github/workflows/node-prod.yml @@ -31,17 +31,17 @@ jobs: run: working-directory: server steps: - - uses: actions/checkout@v3 - - uses: docker/setup-buildx-action@v1 + - uses: actions/checkout@v4 + - uses: docker/setup-buildx-action@v3 with: buildkitd-flags: --debug - - uses: actions/cache@v3 + - uses: actions/cache@v4 with: path: /tmp/.buildx-cache key: ${{ runner.os }}-buildx-${{ github.sha }} restore-keys: | ${{ runner.os }}-buildx- - - uses: actions/setup-node@v3 + - uses: actions/setup-node@v4 with: node-version: 16 cache: yarn @@ -78,7 +78,7 @@ jobs: environment: OSMP_PROD concurrency: OSMP_PROD steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: docker/login-action@v1 with: registry: ghcr.io @@ -96,8 +96,8 @@ jobs: SSH_AGENT_EVAL=$(ssh-agent -s) eval "$SSH_AGENT_EVAL" ssh-add - <<< "${{ secrets.DEPLOY_PRIVATE_KEY }}" - echo "::set-output name=ssh-agent-eval::$SSH_AGENT_EVAL" - echo "::set-output name=ssh-agent-pid::$SSH_AGENT_PID" + echo "ssh-agent-eval=$SSH_AGENT_EVAL" >> "$GITHUB_OUTPUT" + echo "ssh-agent-pid=$SSH_AGENT_PID" >> "$GITHUB_OUTPUT" mkdir -p ~/.ssh echo "${{ secrets.DEPLOY_HOST_KEY }}" > ~/.ssh/known_hosts chmod -R g-rwx,o-rwx ~/.ssh diff --git a/.github/workflows/node.yml b/.github/workflows/node.yml index 0116cf01..592dd4ad 100644 --- a/.github/workflows/node.yml +++ b/.github/workflows/node.yml @@ -33,17 +33,17 @@ jobs: run: working-directory: server steps: - - uses: actions/checkout@v3 - - uses: docker/setup-buildx-action@v1 + - uses: actions/checkout@v4 + - uses: docker/setup-buildx-action@v3 with: buildkitd-flags: --debug - - uses: actions/cache@v3 + - uses: actions/cache@v4 with: path: /tmp/.buildx-cache key: ${{ runner.os }}-buildx-${{ github.sha }} restore-keys: | ${{ runner.os }}-buildx- - - uses: actions/setup-node@v3 + - uses: actions/setup-node@v4 with: node-version: 16 cache: yarn @@ -77,17 +77,17 @@ jobs: run: working-directory: test-node steps: - - uses: actions/checkout@v3 - - uses: docker/setup-buildx-action@v1 + - uses: actions/checkout@v4 + - uses: docker/setup-buildx-action@v3 with: buildkitd-flags: --debug - - uses: actions/cache@v3 + - uses: actions/cache@v4 with: path: /tmp/.buildx-cache key: ${{ runner.os }}-buildx-${{ github.sha }} restore-keys: | ${{ runner.os }}-buildx- - - uses: actions/setup-node@v3 + - uses: actions/setup-node@v4 with: node-version: 16 cache: yarn @@ -123,7 +123,7 @@ jobs: environment: SSMP_SERVER_DEV concurrency: SSMP_SERVER_DEV steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: docker/login-action@v1 with: registry: ghcr.io @@ -141,8 +141,8 @@ jobs: SSH_AGENT_EVAL=$(ssh-agent -s) eval "$SSH_AGENT_EVAL" ssh-add - <<< "${{ secrets.DEPLOY_PRIVATE_KEY }}" - echo "::set-output name=ssh-agent-eval::$SSH_AGENT_EVAL" - echo "::set-output name=ssh-agent-pid::$SSH_AGENT_PID" + echo "ssh-agent-eval=$SSH_AGENT_EVAL" >> "$GITHUB_OUTPUT" + echo "ssh-agent-pid=$SSH_AGENT_PID" >> "$GITHUB_OUTPUT" mkdir -p ~/.ssh echo "${{ secrets.DEPLOY_HOST_KEY }}" > ~/.ssh/known_hosts chmod -R g-rwx,o-rwx ~/.ssh diff --git a/.github/workflows/react-prod.yml b/.github/workflows/react-prod.yml index 3898b66a..f96832bc 100644 --- a/.github/workflows/react-prod.yml +++ b/.github/workflows/react-prod.yml @@ -32,14 +32,14 @@ jobs: shell: bash working-directory: react steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: node-version: 16 - name: Get yarn cache directory path id: yarn-cache-dir-path - run: echo "::set-output name=dir::$(yarn cache dir)" - - uses: actions/cache@v2 + run: echo "dir=$(yarn cache dir)" >> "$GITHUB_OUTPUT" + - uses: actions/cache@v4 id: yarn-cache with: path: ${{ steps.yarn-cache-dir-path.outputs.dir }} @@ -69,14 +69,14 @@ jobs: concurrency: OSMP_PROD if: github.ref == 'refs/heads/production' steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: node-version: 16 - name: Get yarn cache path id: yarn-cache-path - run: echo "::set-output name=dir::$(yarn cache dir)" - - uses: actions/cache@v2 + run: echo "dir=$(yarn cache dir)" >> "$GITHUB_OUTPUT" + - uses: actions/cache@v4 id: restore with: path: | diff --git a/.github/workflows/react.yml b/.github/workflows/react.yml index df022b92..d2dfa40a 100644 --- a/.github/workflows/react.yml +++ b/.github/workflows/react.yml @@ -21,14 +21,14 @@ jobs: shell: bash working-directory: react steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: node-version: 16 - name: Get yarn cache directory path id: yarn-cache-dir-path - run: echo "::set-output name=dir::$(yarn cache dir)" - - uses: actions/cache@v2 + run: echo "dir=$(yarn cache dir)" >> "$GITHUB_OUTPUT" + - uses: actions/cache@v4 id: yarn-cache with: path: ${{ steps.yarn-cache-dir-path.outputs.dir }} @@ -58,14 +58,14 @@ jobs: concurrency: SSMP_BUILD if: github.ref == 'refs/heads/develop' steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: node-version: 16 - name: Get yarn cache path id: yarn-cache-path - run: echo "::set-output name=dir::$(yarn cache dir)" - - uses: actions/cache@v2 + run: echo "dir=$(yarn cache dir)" >> "$GITHUB_OUTPUT" + - uses: actions/cache@v4 id: restore with: path: | From 5621d05a9c52c125dbf5f77c222571a8ead336e9 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Wed, 17 Apr 2024 13:36:15 -0400 Subject: [PATCH 53/57] Undo SSH configure workflow change (#392) --- .github/workflows/node-prod.yml | 4 ++-- .github/workflows/node.yml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/node-prod.yml b/.github/workflows/node-prod.yml index a5a8932e..cfc5a06f 100644 --- a/.github/workflows/node-prod.yml +++ b/.github/workflows/node-prod.yml @@ -96,8 +96,8 @@ jobs: SSH_AGENT_EVAL=$(ssh-agent -s) eval "$SSH_AGENT_EVAL" ssh-add - <<< "${{ secrets.DEPLOY_PRIVATE_KEY }}" - echo "ssh-agent-eval=$SSH_AGENT_EVAL" >> "$GITHUB_OUTPUT" - echo "ssh-agent-pid=$SSH_AGENT_PID" >> "$GITHUB_OUTPUT" + echo "::set-output name=ssh-agent-eval::$SSH_AGENT_EVAL" + echo "::set-output name=ssh-agent-pid::$SSH_AGENT_PID" mkdir -p ~/.ssh echo "${{ secrets.DEPLOY_HOST_KEY }}" > ~/.ssh/known_hosts chmod -R g-rwx,o-rwx ~/.ssh diff --git a/.github/workflows/node.yml b/.github/workflows/node.yml index 592dd4ad..b0d9a365 100644 --- a/.github/workflows/node.yml +++ b/.github/workflows/node.yml @@ -141,8 +141,8 @@ jobs: SSH_AGENT_EVAL=$(ssh-agent -s) eval "$SSH_AGENT_EVAL" ssh-add - <<< "${{ secrets.DEPLOY_PRIVATE_KEY }}" - echo "ssh-agent-eval=$SSH_AGENT_EVAL" >> "$GITHUB_OUTPUT" - echo "ssh-agent-pid=$SSH_AGENT_PID" >> "$GITHUB_OUTPUT" + echo "::set-output name=ssh-agent-eval::$SSH_AGENT_EVAL" + echo "::set-output name=ssh-agent-pid::$SSH_AGENT_PID" mkdir -p ~/.ssh echo "${{ secrets.DEPLOY_HOST_KEY }}" > ~/.ssh/known_hosts chmod -R g-rwx,o-rwx ~/.ssh From 4a225f87c53048876dbf20d2caa5881af278e879 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Tue, 21 May 2024 11:04:55 -0400 Subject: [PATCH 54/57] Server: Fix Gnomad annotation bug with GRCh38 + CMH (#395) * Fix form to clear gene when switching assemblies * Update Gnomad model handling to use factory functions * format --- react/src/pages/VariantQueryPage.tsx | 2 + server/src/models/GnomadAnnotationModel.ts | 51 +++++++++++-------- server/src/models/index.ts | 4 +- .../utils/fetchGnomadAnnotations.ts | 10 ++-- 4 files changed, 37 insertions(+), 30 deletions(-) diff --git a/react/src/pages/VariantQueryPage.tsx b/react/src/pages/VariantQueryPage.tsx index d9e1a418..7439fad2 100644 --- a/react/src/pages/VariantQueryPage.tsx +++ b/react/src/pages/VariantQueryPage.tsx @@ -202,6 +202,8 @@ const VariantQueryPage: React.FC<{}> = () => { onSelect={val => updateQueryOptionsForm({ assemblyId: val as AssemblyId, + gene: '', + position: '', }) } options={['GRCh37', 'GRCh38'].map((a, id) => ({ diff --git a/server/src/models/GnomadAnnotationModel.ts b/server/src/models/GnomadAnnotationModel.ts index c8533711..519f207c 100644 --- a/server/src/models/GnomadAnnotationModel.ts +++ b/server/src/models/GnomadAnnotationModel.ts @@ -1,6 +1,7 @@ import mongoose, { Model, model } from 'mongoose'; import logger from '../logger'; import { + AssemblyId, CMHVariantIndelCoordinate, GnomadBaseAnnotation, GnomadGenomeAnnotation, @@ -155,7 +156,7 @@ GnomadGRCh37AnnotationSchema.statics.getAnnotations = async function (ids: Annot 'gene', 'transcript', ]); - const genomeAnnotations = await getAnnotations(GnomadGRCh37GenomeAnnotationModel, ids, [ + const genomeAnnotations = await getAnnotations(getGnomadGRCh37GenomeAnnotationModel(), ids, [ 'cdna', 'gene', 'source', @@ -194,26 +195,32 @@ GnomadGRCh38AnnotationSchema.statics.getAnnotations = async function (ids: Annot }; }; -export const GnomadGRCh37AnnotationModel = model< - GnomadGRCh37ExomeAnnotation, - GnomadGRCh37ExomeAnnotationModel ->('GnomadGRCh37ExomeAnnotation', GnomadGRCh37AnnotationSchema, 'GRCh37ExomeAnnotations'); - -const GnomadGRCh37GenomeAnnotationModel = model< - GnomadGenomeAnnotation, - GnomadGenomeAnnotationModel ->('GnomadGRCh37GenomeAnnotation', GnomadGRCh37GenomeAnnotationSchema, 'GRCh37GenomeAnnotations'); - -export const GnomadGRCh38AnnotationModels = [ - ...Array.from({ length: 22 }, (_, i) => `${i + 1}`), - 'X', - 'Y', -].reduce((modelMapping, chr) => { - modelMapping[chr] = model( - `GnomadGRCh38GenomeAnnotation_chr${chr}`, - GnomadGRCh38AnnotationSchema, - `GRCh38GenomeAnnotations_chr${chr}` +const getGnomadGRCh37GenomeAnnotationModel = () => + model( + 'GnomadGRCh37GenomeAnnotation', + GnomadGRCh37GenomeAnnotationSchema, + 'GRCh37GenomeAnnotations' ); - return modelMapping; -}, {} as { [key: string]: GnomadGenomeAnnotationModel }); +export const getGnomadAnnotationModel = (assembly: AssemblyId, chromosome: string) => { + chromosome = chromosome.replace('chr', ''); + if (assembly.includes('38')) { + // GRCh38 + if ([...Array.from({ length: 22 }, (_, i) => `${i + 1}`), 'X', 'Y'].includes(chromosome)) { + return model( + `GnomadGRCh38GenomeAnnotation_chr${chromosome}`, + GnomadGRCh38AnnotationSchema, + `GRCh38GenomeAnnotations_chr${chromosome}` + ); + } else { + throw Error(`Chromosome '${chromosome}' invalid; cannot fetch Gnomad annotation model`); + } + } else { + // GRCh37 + return model( + 'GnomadGRCh37ExomeAnnotation', + GnomadGRCh37AnnotationSchema, + 'GRCh37ExomeAnnotations' + ); + } +}; diff --git a/server/src/models/index.ts b/server/src/models/index.ts index 66823725..c8a699ae 100644 --- a/server/src/models/index.ts +++ b/server/src/models/index.ts @@ -1,3 +1,3 @@ -import { GnomadGRCh37AnnotationModel, GnomadGRCh38AnnotationModels } from './GnomadAnnotationModel'; +import { getGnomadAnnotationModel } from './GnomadAnnotationModel'; -export { GnomadGRCh37AnnotationModel, GnomadGRCh38AnnotationModels }; +export { getGnomadAnnotationModel }; diff --git a/server/src/resolvers/getVariantsResolver/utils/fetchGnomadAnnotations.ts b/server/src/resolvers/getVariantsResolver/utils/fetchGnomadAnnotations.ts index 454ff2d2..3a96d3c0c 100644 --- a/server/src/resolvers/getVariantsResolver/utils/fetchGnomadAnnotations.ts +++ b/server/src/resolvers/getVariantsResolver/utils/fetchGnomadAnnotations.ts @@ -1,10 +1,11 @@ -import { GnomadGRCh37AnnotationModel, GnomadGRCh38AnnotationModels } from '../../../models'; +import { getGnomadAnnotationModel } from '../../../models'; import getCoordinates from '../../../models/utils/getCoordinates'; import resolveAssembly from './resolveAssembly'; import resolveChromosome from './resolveChromosome'; import { GnomadAnnotationQueryResponse, VariantQueryDataResult } from '../../../types'; import { QueryResponseError } from './queryResponseError'; import { timeitAsync } from '../../../utils/timeit'; +import logger from '../../../logger'; const fetchGnomadAnnotations = timeitAsync('annotateGnomad')( async ( @@ -18,11 +19,8 @@ const fetchGnomadAnnotations = timeitAsync('annotateGnomad')( const resolvedAssemblyId = resolveAssembly(assemblyId); const { chromosome } = resolveChromosome(position); const annotationCoordinates = getCoordinates(queryResponse); - const GnomadAnnotationModel = - resolvedAssemblyId === 'GRCh37' - ? GnomadGRCh37AnnotationModel - : GnomadGRCh38AnnotationModels[chromosome]; - + const GnomadAnnotationModel = getGnomadAnnotationModel(resolvedAssemblyId, chromosome); + logger.debug(`model: '${typeof GnomadAnnotationModel}'`); const annotations = await GnomadAnnotationModel.getAnnotations(annotationCoordinates); return { source, data: annotations }; From f816617fe033a3d252a49d9de0e031a8f2dcc8cd Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Tue, 21 May 2024 12:04:58 -0400 Subject: [PATCH 55/57] All: merge outstanding dependencies (#396) * Bump jose from 2.0.6 to 2.0.7 in /test-node Bumps [jose](https://github.com/panva/jose) from 2.0.6 to 2.0.7. - [Release notes](https://github.com/panva/jose/releases) - [Changelog](https://github.com/panva/jose/blob/v2.0.7/CHANGELOG.md) - [Commits](https://github.com/panva/jose/compare/v2.0.6...v2.0.7) --- updated-dependencies: - dependency-name: jose dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump follow-redirects from 1.15.4 to 1.15.6 in /server Bumps [follow-redirects](https://github.com/follow-redirects/follow-redirects) from 1.15.4 to 1.15.6. - [Release notes](https://github.com/follow-redirects/follow-redirects/releases) - [Commits](https://github.com/follow-redirects/follow-redirects/compare/v1.15.4...v1.15.6) --- updated-dependencies: - dependency-name: follow-redirects dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump follow-redirects from 1.15.4 to 1.15.6 in /react Bumps [follow-redirects](https://github.com/follow-redirects/follow-redirects) from 1.15.4 to 1.15.6. - [Release notes](https://github.com/follow-redirects/follow-redirects/releases) - [Commits](https://github.com/follow-redirects/follow-redirects/compare/v1.15.4...v1.15.6) --- updated-dependencies: - dependency-name: follow-redirects dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump express from 4.17.3 to 4.19.2 in /server Bumps [express](https://github.com/expressjs/express) from 4.17.3 to 4.19.2. - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/master/History.md) - [Commits](https://github.com/expressjs/express/compare/4.17.3...4.19.2) --- updated-dependencies: - dependency-name: express dependency-type: direct:production ... Signed-off-by: dependabot[bot] * Bump express from 4.17.3 to 4.19.2 in /react Bumps [express](https://github.com/expressjs/express) from 4.17.3 to 4.19.2. - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/master/History.md) - [Commits](https://github.com/expressjs/express/compare/4.17.3...4.19.2) --- updated-dependencies: - dependency-name: express dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump express from 4.17.3 to 4.19.2 in /test-node Bumps [express](https://github.com/expressjs/express) from 4.17.3 to 4.19.2. - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/master/History.md) - [Commits](https://github.com/expressjs/express/compare/4.17.3...4.19.2) --- updated-dependencies: - dependency-name: express dependency-type: direct:production ... Signed-off-by: dependabot[bot] * Bump undici from 5.28.3 to 5.28.4 in /server Bumps [undici](https://github.com/nodejs/undici) from 5.28.3 to 5.28.4. - [Release notes](https://github.com/nodejs/undici/releases) - [Commits](https://github.com/nodejs/undici/compare/v5.28.3...v5.28.4) --- updated-dependencies: - dependency-name: undici dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump tar from 6.1.11 to 6.2.1 in /react Bumps [tar](https://github.com/isaacs/node-tar) from 6.1.11 to 6.2.1. - [Release notes](https://github.com/isaacs/node-tar/releases) - [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md) - [Commits](https://github.com/isaacs/node-tar/compare/v6.1.11...v6.2.1) --- updated-dependencies: - dependency-name: tar dependency-type: indirect ... Signed-off-by: dependabot[bot] * Bump mysql2 from 2.3.3 to 3.9.7 in /test-node Bumps [mysql2](https://github.com/sidorares/node-mysql2) from 2.3.3 to 3.9.7. - [Release notes](https://github.com/sidorares/node-mysql2/releases) - [Changelog](https://github.com/sidorares/node-mysql2/blob/master/Changelog.md) - [Commits](https://github.com/sidorares/node-mysql2/compare/v2.3.3...v3.9.7) --- updated-dependencies: - dependency-name: mysql2 dependency-type: direct:production ... Signed-off-by: dependabot[bot] * Bump ejs from 3.1.7 to 3.1.10 in /react Bumps [ejs](https://github.com/mde/ejs) from 3.1.7 to 3.1.10. - [Release notes](https://github.com/mde/ejs/releases) - [Commits](https://github.com/mde/ejs/compare/v3.1.7...v3.1.10) --- updated-dependencies: - dependency-name: ejs dependency-type: indirect ... Signed-off-by: dependabot[bot] --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- react/yarn.lock | 185 +++++++++++++++++-------------- server/package.json | 2 +- server/yarn.lock | 189 +++++++++++--------------------- test-node/package.json | 4 +- test-node/yarn.lock | 239 +++++++++++++++++++++-------------------- 5 files changed, 294 insertions(+), 325 deletions(-) diff --git a/react/yarn.lock b/react/yarn.lock index d1e43b11..ce4062bc 100644 --- a/react/yarn.lock +++ b/react/yarn.lock @@ -4785,21 +4785,23 @@ bn.js@^5.2.1: resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-5.2.1.tgz#0bc527a6a0d18d0aa8d5b0538ce4a77dccfa7b70" integrity sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ== -body-parser@1.19.2: - version "1.19.2" - resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.19.2.tgz#4714ccd9c157d44797b8b5607d72c0b89952f26e" - integrity sha512-SAAwOxgoCKMGs9uUAUFHygfLAyaniaoun6I8mFY9pRAJL9+Kec34aU+oIjDhTycub1jozEfEwx1W1IuOYxVSFw== +body-parser@1.20.2: + version "1.20.2" + resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.20.2.tgz#6feb0e21c4724d06de7ff38da36dad4f57a747fd" + integrity sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA== dependencies: bytes "3.1.2" - content-type "~1.0.4" + content-type "~1.0.5" debug "2.6.9" - depd "~1.1.2" - http-errors "1.8.1" + depd "2.0.0" + destroy "1.2.0" + http-errors "2.0.0" iconv-lite "0.4.24" - on-finished "~2.3.0" - qs "6.9.7" - raw-body "2.4.3" + on-finished "2.4.1" + qs "6.11.0" + raw-body "2.5.2" type-is "~1.6.18" + unpipe "1.0.0" bonjour@^3.5.0: version "3.5.0" @@ -5572,6 +5574,11 @@ content-type@~1.0.4: resolved "https://registry.yarnpkg.com/content-type/-/content-type-1.0.4.tgz#e138cc75e040c727b1966fe5e5f8c9aee256fe3b" integrity sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA== +content-type@~1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/content-type/-/content-type-1.0.5.tgz#8b773162656d1d1086784c8f23a54ce6d73d7918" + integrity sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA== + convert-source-map@^1.4.0, convert-source-map@^1.5.0, convert-source-map@^1.6.0, convert-source-map@^1.7.0: version "1.8.0" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.8.0.tgz#f3373c32d21b4d780dd8004514684fb791ca4369" @@ -5584,10 +5591,10 @@ cookie-signature@1.0.6: resolved "https://registry.yarnpkg.com/cookie-signature/-/cookie-signature-1.0.6.tgz#e303a882b342cc3ee8ca513a79999734dab3ae2c" integrity sha1-4wOogrNCzD7oylE6eZmXNNqzriw= -cookie@0.4.2: - version "0.4.2" - resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.4.2.tgz#0e41f24de5ecf317947c82fc789e06a884824432" - integrity sha512-aSWTXFzaKWkvHO1Ny/s+ePFpvKsPnjc551iI41v3ny/ow6tBG5Vd+FuqGNhh1LxOmVzOlGUriIlOaokOvhaStA== +cookie@0.6.0: + version "0.6.0" + resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.6.0.tgz#2798b04b071b0ecbff0dbb62a505a8efa4e19051" + integrity sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw== copy-concurrently@^1.0.0: version "1.0.5" @@ -6162,6 +6169,11 @@ delegates@^1.0.0: resolved "https://registry.yarnpkg.com/delegates/-/delegates-1.0.0.tgz#84c6e159b81904fdca59a0ef44cd870d31250f9a" integrity sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o= +depd@2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/depd/-/depd-2.0.0.tgz#b696163cc757560d09cf22cc8fad1571b79e76df" + integrity sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw== + depd@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/depd/-/depd-1.1.2.tgz#9bcd52e14c097763e749b274c4346ed2e560b5a9" @@ -6175,10 +6187,10 @@ des.js@^1.0.0: inherits "^2.0.1" minimalistic-assert "^1.0.0" -destroy@~1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/destroy/-/destroy-1.0.4.tgz#978857442c44749e4206613e37946205826abd80" - integrity sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA= +destroy@1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/destroy/-/destroy-1.2.0.tgz#4803735509ad8be552934c67df614f94e66fa015" + integrity sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg== detab@2.0.4: version "2.0.4" @@ -6439,9 +6451,9 @@ ee-first@1.1.1: integrity sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0= ejs@^3.1.6: - version "3.1.7" - resolved "https://registry.yarnpkg.com/ejs/-/ejs-3.1.7.tgz#c544d9c7f715783dd92f0bddcf73a59e6962d006" - integrity sha512-BIar7R6abbUxDA3bfXrO4DSgwo8I+fB5/1zgujl3HLLjwd6+9iOnrT+t3grn2qbk9vOgBubXOFwX2m9axoFaGw== + version "3.1.10" + resolved "https://registry.yarnpkg.com/ejs/-/ejs-3.1.10.tgz#69ab8358b14e896f80cc39e62087b88500c3ac3b" + integrity sha512-UeJmFfOrAQS8OJWPZ4qtgHyWExa088/MtK5UEyoJGFH67cDEXkZSviOiKRCZ4Xij0zxI3JECgYs3oKx+AizQBA== dependencies: jake "^10.8.5" @@ -7024,37 +7036,38 @@ expect@^27.5.1: jest-message-util "^27.5.1" express@^4.17.1: - version "4.17.3" - resolved "https://registry.yarnpkg.com/express/-/express-4.17.3.tgz#f6c7302194a4fb54271b73a1fe7a06478c8f85a1" - integrity sha512-yuSQpz5I+Ch7gFrPCk4/c+dIBKlQUxtgwqzph132bsT6qhuzss6I8cLJQz7B3rFblzd6wtcI0ZbGltH/C4LjUg== + version "4.19.2" + resolved "https://registry.yarnpkg.com/express/-/express-4.19.2.tgz#e25437827a3aa7f2a827bc8171bbbb664a356465" + integrity sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q== dependencies: accepts "~1.3.8" array-flatten "1.1.1" - body-parser "1.19.2" + body-parser "1.20.2" content-disposition "0.5.4" content-type "~1.0.4" - cookie "0.4.2" + cookie "0.6.0" cookie-signature "1.0.6" debug "2.6.9" - depd "~1.1.2" + depd "2.0.0" encodeurl "~1.0.2" escape-html "~1.0.3" etag "~1.8.1" - finalhandler "~1.1.2" + finalhandler "1.2.0" fresh "0.5.2" + http-errors "2.0.0" merge-descriptors "1.0.1" methods "~1.1.2" - on-finished "~2.3.0" + on-finished "2.4.1" parseurl "~1.3.3" path-to-regexp "0.1.7" proxy-addr "~2.0.7" - qs "6.9.7" + qs "6.11.0" range-parser "~1.2.1" safe-buffer "5.2.1" - send "0.17.2" - serve-static "1.14.2" + send "0.18.0" + serve-static "1.15.0" setprototypeof "1.2.0" - statuses "~1.5.0" + statuses "2.0.1" type-is "~1.6.18" utils-merge "1.0.1" vary "~1.1.2" @@ -7227,17 +7240,17 @@ fill-range@^7.0.1: dependencies: to-regex-range "^5.0.1" -finalhandler@~1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.1.2.tgz#b7e7d000ffd11938d0fdb053506f6ebabe9f587d" - integrity sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA== +finalhandler@1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.2.0.tgz#7d23fe5731b207b4640e4fcd00aec1f9207a7b32" + integrity sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg== dependencies: debug "2.6.9" encodeurl "~1.0.2" escape-html "~1.0.3" - on-finished "~2.3.0" + on-finished "2.4.1" parseurl "~1.3.3" - statuses "~1.5.0" + statuses "2.0.1" unpipe "~1.0.0" find-cache-dir@^2.0.0, find-cache-dir@^2.1.0: @@ -7315,9 +7328,9 @@ flush-write-stream@^1.0.0: readable-stream "^2.3.6" follow-redirects@^1.0.0: - version "1.15.4" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.4.tgz#cdc7d308bf6493126b17ea2191ea0ccf3e535adf" - integrity sha512-Cr4D/5wlrb0z9dgERpUL3LrmPKVDsETIJhaCMeDfuFYcqa5bldGV6wBsAN6X/vxlXQtFBMrXdXxdL8CbDTGniw== + version "1.15.6" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.6.tgz#7f815c0cda4249c74ff09e95ef97c23b5fd0399b" + integrity sha512-wWN62YITEaOpSK584EZXJafH1AGpO8RVgElfkuXbTOrPX4fIfOyEpW/CsiNd8JdYrAoOvafRTOEnvsO++qCqFA== for-in@^1.0.2: version "1.0.2" @@ -8120,15 +8133,15 @@ http-deceiver@^1.2.7: resolved "https://registry.yarnpkg.com/http-deceiver/-/http-deceiver-1.2.7.tgz#fa7168944ab9a519d337cb0bec7284dc3e723d87" integrity sha1-+nFolEq5pRnTN8sL7HKE3D5yPYc= -http-errors@1.8.1: - version "1.8.1" - resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-1.8.1.tgz#7c3f28577cbc8a207388455dbd62295ed07bd68c" - integrity sha512-Kpk9Sm7NmI+RHhnj6OIWDI1d6fIoFAtFt9RLaTMRlg/8w49juAStsrBgp0Dp4OdxdVbRIeKhtCUvoi/RuAhO4g== +http-errors@2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-2.0.0.tgz#b7774a1486ef73cf7667ac9ae0858c012c57b9d3" + integrity sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ== dependencies: - depd "~1.1.2" + depd "2.0.0" inherits "2.0.4" setprototypeof "1.2.0" - statuses ">= 1.5.0 < 2" + statuses "2.0.1" toidentifier "1.0.1" http-errors@~1.6.2: @@ -10060,6 +10073,11 @@ minipass@^3.0.0, minipass@^3.1.1: dependencies: yallist "^4.0.0" +minipass@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/minipass/-/minipass-5.0.0.tgz#3e9788ffb90b694a5d0ec94479a45b5d8738133d" + integrity sha512-3FnjYuehv9k6ovOEbyOswadCDPX1piCfhV8ncmYtHOjuPwylVWsghTLo7rabjC3Rx5xD4HDx8Wm1xnMF7S5qFQ== + minizlib@^2.1.1: version "2.1.2" resolved "https://registry.yarnpkg.com/minizlib/-/minizlib-2.1.2.tgz#e90d3466ba209b932451508a11ce3d3632145931" @@ -10469,10 +10487,10 @@ obuf@^1.0.0, obuf@^1.1.2: resolved "https://registry.yarnpkg.com/obuf/-/obuf-1.1.2.tgz#09bea3343d41859ebd446292d11c9d4db619084e" integrity sha512-PX1wu0AmAdPqOL1mWhqmlOd8kOIZQwGZw6rh7uby9fTc5lhaOWFLX3I6R1hrF9k3zUY40e6igsLGkDXK92LJNg== -on-finished@~2.3.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/on-finished/-/on-finished-2.3.0.tgz#20f1336481b083cd75337992a16971aa2d906947" - integrity sha1-IPEzZIGwg811M3mSoWlxqi2QaUc= +on-finished@2.4.1: + version "2.4.1" + resolved "https://registry.yarnpkg.com/on-finished/-/on-finished-2.4.1.tgz#58c8c44116e54845ad57f14ab10b03533184ac3f" + integrity sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg== dependencies: ee-first "1.1.1" @@ -11735,10 +11753,12 @@ q@^1.1.2: resolved "https://registry.yarnpkg.com/q/-/q-1.5.1.tgz#7e32f75b41381291d04611f1bf14109ac00651d7" integrity sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc= -qs@6.9.7: - version "6.9.7" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.9.7.tgz#4610846871485e1e048f44ae3b94033f0e675afe" - integrity sha512-IhMFgUmuNpyRfxA90umL7ByLlgRXu6tIfKPpF5TmcfRLlLCckfP/g3IQmju6jjpu+Hh8rA+2p6A27ZSPOOHdKw== +qs@6.11.0: + version "6.11.0" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.0.tgz#fd0d963446f7a65e1367e01abd85429453f0c37a" + integrity sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q== + dependencies: + side-channel "^1.0.4" qs@^6.10.0: version "6.10.3" @@ -11814,13 +11834,13 @@ range-parser@^1.2.1, range-parser@~1.2.1: resolved "https://registry.yarnpkg.com/range-parser/-/range-parser-1.2.1.tgz#3cf37023d199e1c24d1a55b84800c2f3e6468031" integrity sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg== -raw-body@2.4.3: - version "2.4.3" - resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.4.3.tgz#8f80305d11c2a0a545c2d9d89d7a0286fcead43c" - integrity sha512-UlTNLIcu0uzb4D2f4WltY6cVjLi+/jEN4lgEUj3E04tpMDpUlkBo/eSn6zou9hum2VMNpCCUone0O0WeJim07g== +raw-body@2.5.2: + version "2.5.2" + resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.5.2.tgz#99febd83b90e08975087e8f1f9419a149366b68a" + integrity sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA== dependencies: bytes "3.1.2" - http-errors "1.8.1" + http-errors "2.0.0" iconv-lite "0.4.24" unpipe "1.0.0" @@ -12786,24 +12806,24 @@ semver@^7.3.2, semver@^7.3.4, semver@^7.3.5: dependencies: lru-cache "^6.0.0" -send@0.17.2: - version "0.17.2" - resolved "https://registry.yarnpkg.com/send/-/send-0.17.2.tgz#926622f76601c41808012c8bf1688fe3906f7820" - integrity sha512-UJYB6wFSJE3G00nEivR5rgWp8c2xXvJ3OPWPhmuteU0IKj8nKbG3DrjiOmLwpnHGYWAVwA69zmTm++YG0Hmwww== +send@0.18.0: + version "0.18.0" + resolved "https://registry.yarnpkg.com/send/-/send-0.18.0.tgz#670167cc654b05f5aa4a767f9113bb371bc706be" + integrity sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg== dependencies: debug "2.6.9" - depd "~1.1.2" - destroy "~1.0.4" + depd "2.0.0" + destroy "1.2.0" encodeurl "~1.0.2" escape-html "~1.0.3" etag "~1.8.1" fresh "0.5.2" - http-errors "1.8.1" + http-errors "2.0.0" mime "1.6.0" ms "2.1.3" - on-finished "~2.3.0" + on-finished "2.4.1" range-parser "~1.2.1" - statuses "~1.5.0" + statuses "2.0.1" serialize-javascript@^4.0.0: version "4.0.0" @@ -12850,15 +12870,15 @@ serve-index@^1.9.1: mime-types "~2.1.17" parseurl "~1.3.2" -serve-static@1.14.2: - version "1.14.2" - resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.14.2.tgz#722d6294b1d62626d41b43a013ece4598d292bfa" - integrity sha512-+TMNA9AFxUEGuC0z2mevogSnn9MXKb4fa7ngeRMJaaGv8vTwnIEkKi+QGvPt33HSnf8pRS+WGM0EbMtCJLKMBQ== +serve-static@1.15.0: + version "1.15.0" + resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.15.0.tgz#faaef08cffe0a1a62f60cad0c4e513cff0ac9540" + integrity sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g== dependencies: encodeurl "~1.0.2" escape-html "~1.0.3" parseurl "~1.3.3" - send "0.17.2" + send "0.18.0" set-blocking@^2.0.0: version "2.0.0" @@ -13200,7 +13220,12 @@ static-extend@^0.1.1: define-property "^0.2.5" object-copy "^0.1.0" -"statuses@>= 1.4.0 < 2", "statuses@>= 1.5.0 < 2", statuses@~1.5.0: +statuses@2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/statuses/-/statuses-2.0.1.tgz#55cb000ccf1d48728bd23c685a063998cf1a1b63" + integrity sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ== + +"statuses@>= 1.4.0 < 2": version "1.5.0" resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.5.0.tgz#161c7dac177659fd9811f43771fa99381478628c" integrity sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow= @@ -13592,13 +13617,13 @@ tapable@^2.0.0, tapable@^2.1.1, tapable@^2.2.0: integrity sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ== tar@^6.0.2: - version "6.1.11" - resolved "https://registry.yarnpkg.com/tar/-/tar-6.1.11.tgz#6760a38f003afa1b2ffd0ffe9e9abbd0eab3d621" - integrity sha512-an/KZQzQUkZCkuoAA64hM92X0Urb6VpRhAFllDzz44U2mcD5scmT3zBc4VgVpkugF580+DQn8eAFSyoQt0tznA== + version "6.2.1" + resolved "https://registry.yarnpkg.com/tar/-/tar-6.2.1.tgz#717549c541bc3c2af15751bea94b1dd068d4b03a" + integrity sha512-DZ4yORTwrbTj/7MZYq2w+/ZFdI6OZ/f9SFHR+71gIVUZhOQPHzVCLpvRnPgyaMpfWxxk/4ONva3GQSyNIKRv6A== dependencies: chownr "^2.0.0" fs-minipass "^2.0.0" - minipass "^3.0.0" + minipass "^5.0.0" minizlib "^2.1.1" mkdirp "^1.0.3" yallist "^4.0.0" diff --git a/server/package.json b/server/package.json index 2bafb947..d865df62 100644 --- a/server/package.json +++ b/server/package.json @@ -20,7 +20,7 @@ "axios": ">=1.6.0", "cross-fetch": "^3.1.5", "eslint-config-prettier": "^8.3.0", - "express": "^4.17.1", + "express": "^4.19.2", "express-session": "^1.17.2", "generic-filehandle": "^2.2.2", "graphql": "^16.8.1", diff --git a/server/yarn.lock b/server/yarn.lock index 6b7c0420..07f1c90d 100644 --- a/server/yarn.lock +++ b/server/yarn.lock @@ -2680,37 +2680,21 @@ bn.js@^4.0.0, bn.js@^4.11.9: resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.12.0.tgz#775b3f278efbb9718eec7361f483fb36fbbfea88" integrity sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA== -body-parser@1.19.2: - version "1.19.2" - resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.19.2.tgz#4714ccd9c157d44797b8b5607d72c0b89952f26e" - integrity sha512-SAAwOxgoCKMGs9uUAUFHygfLAyaniaoun6I8mFY9pRAJL9+Kec34aU+oIjDhTycub1jozEfEwx1W1IuOYxVSFw== +body-parser@1.20.2, body-parser@^1.19.0: + version "1.20.2" + resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.20.2.tgz#6feb0e21c4724d06de7ff38da36dad4f57a747fd" + integrity sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA== dependencies: bytes "3.1.2" - content-type "~1.0.4" - debug "2.6.9" - depd "~1.1.2" - http-errors "1.8.1" - iconv-lite "0.4.24" - on-finished "~2.3.0" - qs "6.9.7" - raw-body "2.4.3" - type-is "~1.6.18" - -body-parser@^1.19.0: - version "1.20.0" - resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.20.0.tgz#3de69bd89011c11573d7bfee6a64f11b6bd27cc5" - integrity sha512-DfJ+q6EPcGKZD1QWUjSpqp+Q7bDQTsQIF4zfUAtZ6qk+H/3/QRhg9CEp39ss+/T2vw0+HaidC0ecJj/DRLIaKg== - dependencies: - bytes "3.1.2" - content-type "~1.0.4" + content-type "~1.0.5" debug "2.6.9" depd "2.0.0" destroy "1.2.0" http-errors "2.0.0" iconv-lite "0.4.24" on-finished "2.4.1" - qs "6.10.3" - raw-body "2.5.1" + qs "6.11.0" + raw-body "2.5.2" type-is "~1.6.18" unpipe "1.0.0" @@ -2988,10 +2972,10 @@ content-disposition@0.5.4: dependencies: safe-buffer "5.2.1" -content-type@~1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/content-type/-/content-type-1.0.4.tgz#e138cc75e040c727b1966fe5e5f8c9aee256fe3b" - integrity sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA== +content-type@~1.0.4, content-type@~1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/content-type/-/content-type-1.0.5.tgz#8b773162656d1d1086784c8f23a54ce6d73d7918" + integrity sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA== convert-source-map@^1.4.0, convert-source-map@^1.6.0, convert-source-map@^1.7.0: version "1.8.0" @@ -3010,10 +2994,10 @@ cookie@0.4.1: resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.4.1.tgz#afd713fe26ebd21ba95ceb61f9a8116e50a537d1" integrity sha512-ZwrFkGJxUR3EIoXtO+yVE69Eb7KlixbaeAWfBQB9vVsNn/o+Yw69gBWSSDK825hQNdN+wF8zELf3dFNl/kxkUA== -cookie@0.4.2: - version "0.4.2" - resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.4.2.tgz#0e41f24de5ecf317947c82fc789e06a884824432" - integrity sha512-aSWTXFzaKWkvHO1Ny/s+ePFpvKsPnjc551iI41v3ny/ow6tBG5Vd+FuqGNhh1LxOmVzOlGUriIlOaokOvhaStA== +cookie@0.6.0: + version "0.6.0" + resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.6.0.tgz#2798b04b071b0ecbff0dbb62a505a8efa4e19051" + integrity sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw== cors@^2.8.5: version "2.8.5" @@ -3175,21 +3159,11 @@ depd@2.0.0, depd@~2.0.0: resolved "https://registry.yarnpkg.com/depd/-/depd-2.0.0.tgz#b696163cc757560d09cf22cc8fad1571b79e76df" integrity sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw== -depd@~1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/depd/-/depd-1.1.2.tgz#9bcd52e14c097763e749b274c4346ed2e560b5a9" - integrity sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak= - destroy@1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/destroy/-/destroy-1.2.0.tgz#4803735509ad8be552934c67df614f94e66fa015" integrity sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg== -destroy@~1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/destroy/-/destroy-1.0.4.tgz#978857442c44749e4206613e37946205826abd80" - integrity sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA= - detect-newline@^3.0.0: version "3.1.0" resolved "https://registry.yarnpkg.com/detect-newline/-/detect-newline-3.1.0.tgz#576f5dfc63ae1a192ff192d8ad3af6308991b651" @@ -3656,38 +3630,39 @@ express-session@^1.17.2: safe-buffer "5.2.1" uid-safe "~2.1.5" -express@^4.17.1: - version "4.17.3" - resolved "https://registry.yarnpkg.com/express/-/express-4.17.3.tgz#f6c7302194a4fb54271b73a1fe7a06478c8f85a1" - integrity sha512-yuSQpz5I+Ch7gFrPCk4/c+dIBKlQUxtgwqzph132bsT6qhuzss6I8cLJQz7B3rFblzd6wtcI0ZbGltH/C4LjUg== +express@^4.19.2: + version "4.19.2" + resolved "https://registry.yarnpkg.com/express/-/express-4.19.2.tgz#e25437827a3aa7f2a827bc8171bbbb664a356465" + integrity sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q== dependencies: accepts "~1.3.8" array-flatten "1.1.1" - body-parser "1.19.2" + body-parser "1.20.2" content-disposition "0.5.4" content-type "~1.0.4" - cookie "0.4.2" + cookie "0.6.0" cookie-signature "1.0.6" debug "2.6.9" - depd "~1.1.2" + depd "2.0.0" encodeurl "~1.0.2" escape-html "~1.0.3" etag "~1.8.1" - finalhandler "~1.1.2" + finalhandler "1.2.0" fresh "0.5.2" + http-errors "2.0.0" merge-descriptors "1.0.1" methods "~1.1.2" - on-finished "~2.3.0" + on-finished "2.4.1" parseurl "~1.3.3" path-to-regexp "0.1.7" proxy-addr "~2.0.7" - qs "6.9.7" + qs "6.11.0" range-parser "~1.2.1" safe-buffer "5.2.1" - send "0.17.2" - serve-static "1.14.2" + send "0.18.0" + serve-static "1.15.0" setprototypeof "1.2.0" - statuses "~1.5.0" + statuses "2.0.1" type-is "~1.6.18" utils-merge "1.0.1" vary "~1.1.2" @@ -3791,17 +3766,17 @@ fill-range@^7.0.1: dependencies: to-regex-range "^5.0.1" -finalhandler@~1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.1.2.tgz#b7e7d000ffd11938d0fdb053506f6ebabe9f587d" - integrity sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA== +finalhandler@1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.2.0.tgz#7d23fe5731b207b4640e4fcd00aec1f9207a7b32" + integrity sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg== dependencies: debug "2.6.9" encodeurl "~1.0.2" escape-html "~1.0.3" - on-finished "~2.3.0" + on-finished "2.4.1" parseurl "~1.3.3" - statuses "~1.5.0" + statuses "2.0.1" unpipe "~1.0.0" find-up@^2.1.0: @@ -3838,9 +3813,9 @@ fn.name@1.x.x: integrity sha512-GRnmB5gPyJpAhTQdSZTSp9uaPSvl09KoYcMQtsB9rQoOmzs9dH6ffeccH+Z+cv6P68Hu5bC6JjRh4Ah/mHSNRw== follow-redirects@^1.15.0: - version "1.15.4" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.4.tgz#cdc7d308bf6493126b17ea2191ea0ccf3e535adf" - integrity sha512-Cr4D/5wlrb0z9dgERpUL3LrmPKVDsETIJhaCMeDfuFYcqa5bldGV6wBsAN6X/vxlXQtFBMrXdXxdL8CbDTGniw== + version "1.15.6" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.6.tgz#7f815c0cda4249c74ff09e95ef97c23b5fd0399b" + integrity sha512-wWN62YITEaOpSK584EZXJafH1AGpO8RVgElfkuXbTOrPX4fIfOyEpW/CsiNd8JdYrAoOvafRTOEnvsO++qCqFA== form-data-encoder@^1.7.1: version "1.7.2" @@ -4124,17 +4099,6 @@ html-escaper@^2.0.0: resolved "https://registry.yarnpkg.com/html-escaper/-/html-escaper-2.0.2.tgz#dfd60027da36a36dfcbe236262c00a5822681453" integrity sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg== -http-errors@1.8.1: - version "1.8.1" - resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-1.8.1.tgz#7c3f28577cbc8a207388455dbd62295ed07bd68c" - integrity sha512-Kpk9Sm7NmI+RHhnj6OIWDI1d6fIoFAtFt9RLaTMRlg/8w49juAStsrBgp0Dp4OdxdVbRIeKhtCUvoi/RuAhO4g== - dependencies: - depd "~1.1.2" - inherits "2.0.4" - setprototypeof "1.2.0" - statuses ">= 1.5.0 < 2" - toidentifier "1.0.1" - http-errors@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-2.0.0.tgz#b7774a1486ef73cf7667ac9ae0858c012c57b9d3" @@ -5403,13 +5367,6 @@ on-finished@2.4.1: dependencies: ee-first "1.1.1" -on-finished@~2.3.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/on-finished/-/on-finished-2.3.0.tgz#20f1336481b083cd75337992a16971aa2d906947" - integrity sha1-IPEzZIGwg811M3mSoWlxqi2QaUc= - dependencies: - ee-first "1.1.1" - on-headers@~1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/on-headers/-/on-headers-1.0.2.tgz#772b0ae6aaa525c399e489adfad90c403eb3c28f" @@ -5674,18 +5631,13 @@ punycode@^2.1.0, punycode@^2.1.1: resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== -qs@6.10.3: - version "6.10.3" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.10.3.tgz#d6cde1b2ffca87b5aa57889816c5f81535e22e8e" - integrity sha512-wr7M2E0OFRfIfJZjKGieI8lBKb7fRCH4Fv5KNPEs7gJ8jadvotdsS08PzOKR7opXhZ/Xkjtt3WF9g38drmyRqQ== +qs@6.11.0: + version "6.11.0" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.0.tgz#fd0d963446f7a65e1367e01abd85429453f0c37a" + integrity sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q== dependencies: side-channel "^1.0.4" -qs@6.9.7: - version "6.9.7" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.9.7.tgz#4610846871485e1e048f44ae3b94033f0e675afe" - integrity sha512-IhMFgUmuNpyRfxA90umL7ByLlgRXu6tIfKPpF5TmcfRLlLCckfP/g3IQmju6jjpu+Hh8rA+2p6A27ZSPOOHdKw== - querystringify@^2.1.1: version "2.2.0" resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-2.2.0.tgz#3345941b4153cb9d082d8eee4cda2016a9aef7f6" @@ -5711,20 +5663,10 @@ range-parser@~1.2.1: resolved "https://registry.yarnpkg.com/range-parser/-/range-parser-1.2.1.tgz#3cf37023d199e1c24d1a55b84800c2f3e6468031" integrity sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg== -raw-body@2.4.3: - version "2.4.3" - resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.4.3.tgz#8f80305d11c2a0a545c2d9d89d7a0286fcead43c" - integrity sha512-UlTNLIcu0uzb4D2f4WltY6cVjLi+/jEN4lgEUj3E04tpMDpUlkBo/eSn6zou9hum2VMNpCCUone0O0WeJim07g== - dependencies: - bytes "3.1.2" - http-errors "1.8.1" - iconv-lite "0.4.24" - unpipe "1.0.0" - -raw-body@2.5.1: - version "2.5.1" - resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.5.1.tgz#fe1b1628b181b700215e5fd42389f98b71392857" - integrity sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig== +raw-body@2.5.2: + version "2.5.2" + resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.5.2.tgz#99febd83b90e08975087e8f1f9419a149366b68a" + integrity sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA== dependencies: bytes "3.1.2" http-errors "2.0.0" @@ -5880,34 +5822,34 @@ semver@^6.0.0, semver@^6.1.0, semver@^6.3.0: resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== -send@0.17.2: - version "0.17.2" - resolved "https://registry.yarnpkg.com/send/-/send-0.17.2.tgz#926622f76601c41808012c8bf1688fe3906f7820" - integrity sha512-UJYB6wFSJE3G00nEivR5rgWp8c2xXvJ3OPWPhmuteU0IKj8nKbG3DrjiOmLwpnHGYWAVwA69zmTm++YG0Hmwww== +send@0.18.0: + version "0.18.0" + resolved "https://registry.yarnpkg.com/send/-/send-0.18.0.tgz#670167cc654b05f5aa4a767f9113bb371bc706be" + integrity sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg== dependencies: debug "2.6.9" - depd "~1.1.2" - destroy "~1.0.4" + depd "2.0.0" + destroy "1.2.0" encodeurl "~1.0.2" escape-html "~1.0.3" etag "~1.8.1" fresh "0.5.2" - http-errors "1.8.1" + http-errors "2.0.0" mime "1.6.0" ms "2.1.3" - on-finished "~2.3.0" + on-finished "2.4.1" range-parser "~1.2.1" - statuses "~1.5.0" + statuses "2.0.1" -serve-static@1.14.2: - version "1.14.2" - resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.14.2.tgz#722d6294b1d62626d41b43a013ece4598d292bfa" - integrity sha512-+TMNA9AFxUEGuC0z2mevogSnn9MXKb4fa7ngeRMJaaGv8vTwnIEkKi+QGvPt33HSnf8pRS+WGM0EbMtCJLKMBQ== +serve-static@1.15.0: + version "1.15.0" + resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.15.0.tgz#faaef08cffe0a1a62f60cad0c4e513cff0ac9540" + integrity sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g== dependencies: encodeurl "~1.0.2" escape-html "~1.0.3" parseurl "~1.3.3" - send "0.17.2" + send "0.18.0" setprototypeof@1.2.0: version "1.2.0" @@ -6040,11 +5982,6 @@ statuses@2.0.1: resolved "https://registry.yarnpkg.com/statuses/-/statuses-2.0.1.tgz#55cb000ccf1d48728bd23c685a063998cf1a1b63" integrity sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ== -"statuses@>= 1.5.0 < 2", statuses@~1.5.0: - version "1.5.0" - resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.5.0.tgz#161c7dac177659fd9811f43771fa99381478628c" - integrity sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow= - string-env-interpolation@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/string-env-interpolation/-/string-env-interpolation-1.0.1.tgz#ad4397ae4ac53fe6c91d1402ad6f6a52862c7152" @@ -6447,9 +6384,9 @@ unbox-primitive@^1.0.1: which-boxed-primitive "^1.0.2" undici@^5.0.0: - version "5.28.3" - resolved "https://registry.yarnpkg.com/undici/-/undici-5.28.3.tgz#a731e0eff2c3fcfd41c1169a869062be222d1e5b" - integrity sha512-3ItfzbrhDlINjaP0duwnNsKpDQk3acHI3gVJ1z4fmwMK31k5G9OVIAMLSIaP6w4FaGkaAkN6zaQO9LUvZ1t7VA== + version "5.28.4" + resolved "https://registry.yarnpkg.com/undici/-/undici-5.28.4.tgz#6b280408edb6a1a604a9b20340f45b422e373068" + integrity sha512-72RFADWFqKmUb2hmmvNODKL3p9hcB6Gt2DOQMis1SEBaV6a4MH8soBvzg+95CYhCKPFedut2JY9bMfrDl9D23g== dependencies: "@fastify/busboy" "^2.0.0" diff --git a/test-node/package.json b/test-node/package.json index e6087bca..4d4212a0 100644 --- a/test-node/package.json +++ b/test-node/package.json @@ -10,10 +10,10 @@ "lint": "eslint --max-warnings=0 'src/**/*.ts'" }, "dependencies": { - "express": "^4.17.1", + "express": "^4.19.2", "express-jwt": "^6.1.0", "jwks-rsa": "^2.0.4", - "mysql2": "^2.3.0" + "mysql2": "^3.9.7" }, "devDependencies": { "@tsconfig/node16": "^1.0.2", diff --git a/test-node/yarn.lock b/test-node/yarn.lock index d100faef..e3d4e452 100644 --- a/test-node/yarn.lock +++ b/test-node/yarn.lock @@ -388,21 +388,23 @@ binary-extensions@^2.0.0: resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-2.2.0.tgz#75f502eeaf9ffde42fc98829645be4ea76bd9e2d" integrity sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA== -body-parser@1.19.2: - version "1.19.2" - resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.19.2.tgz#4714ccd9c157d44797b8b5607d72c0b89952f26e" - integrity sha512-SAAwOxgoCKMGs9uUAUFHygfLAyaniaoun6I8mFY9pRAJL9+Kec34aU+oIjDhTycub1jozEfEwx1W1IuOYxVSFw== +body-parser@1.20.2: + version "1.20.2" + resolved "https://registry.yarnpkg.com/body-parser/-/body-parser-1.20.2.tgz#6feb0e21c4724d06de7ff38da36dad4f57a747fd" + integrity sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA== dependencies: bytes "3.1.2" - content-type "~1.0.4" + content-type "~1.0.5" debug "2.6.9" - depd "~1.1.2" - http-errors "1.8.1" + depd "2.0.0" + destroy "1.2.0" + http-errors "2.0.0" iconv-lite "0.4.24" - on-finished "~2.3.0" - qs "6.9.7" - raw-body "2.4.3" + on-finished "2.4.1" + qs "6.11.0" + raw-body "2.5.2" type-is "~1.6.18" + unpipe "1.0.0" brace-expansion@^1.1.7: version "1.1.11" @@ -515,20 +517,20 @@ content-disposition@0.5.4: dependencies: safe-buffer "5.2.1" -content-type@~1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/content-type/-/content-type-1.0.4.tgz#e138cc75e040c727b1966fe5e5f8c9aee256fe3b" - integrity sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA== +content-type@~1.0.4, content-type@~1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/content-type/-/content-type-1.0.5.tgz#8b773162656d1d1086784c8f23a54ce6d73d7918" + integrity sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA== cookie-signature@1.0.6: version "1.0.6" resolved "https://registry.yarnpkg.com/cookie-signature/-/cookie-signature-1.0.6.tgz#e303a882b342cc3ee8ca513a79999734dab3ae2c" integrity sha1-4wOogrNCzD7oylE6eZmXNNqzriw= -cookie@0.4.2: - version "0.4.2" - resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.4.2.tgz#0e41f24de5ecf317947c82fc789e06a884824432" - integrity sha512-aSWTXFzaKWkvHO1Ny/s+ePFpvKsPnjc551iI41v3ny/ow6tBG5Vd+FuqGNhh1LxOmVzOlGUriIlOaokOvhaStA== +cookie@0.6.0: + version "0.6.0" + resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.6.0.tgz#2798b04b071b0ecbff0dbb62a505a8efa4e19051" + integrity sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw== create-require@^1.1.0: version "1.1.1" @@ -577,20 +579,20 @@ define-properties@^1.1.3: dependencies: object-keys "^1.0.12" -denque@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/denque/-/denque-2.0.1.tgz#bcef4c1b80dc32efe97515744f21a4229ab8934a" - integrity sha512-tfiWc6BQLXNLpNiR5iGd0Ocu3P3VpxfzFiqubLgMfhfOw9WyvgJBd46CClNn9k3qfbjvT//0cf7AlYRX/OslMQ== +denque@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/denque/-/denque-2.1.0.tgz#e93e1a6569fb5e66f16a3c2a2964617d349d6ab1" + integrity sha512-HVQE3AAb/pxF8fQAoiqpvg9i3evqug3hoiwakOyZAwJm+6vZehbkYXZ0l4JxS+I3QxM97v5aaRNhj8v5oBhekw== -depd@~1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/depd/-/depd-1.1.2.tgz#9bcd52e14c097763e749b274c4346ed2e560b5a9" - integrity sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak= +depd@2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/depd/-/depd-2.0.0.tgz#b696163cc757560d09cf22cc8fad1571b79e76df" + integrity sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw== -destroy@~1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/destroy/-/destroy-1.0.4.tgz#978857442c44749e4206613e37946205826abd80" - integrity sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA= +destroy@1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/destroy/-/destroy-1.2.0.tgz#4803735509ad8be552934c67df614f94e66fa015" + integrity sha512-2sJGJTaXIIaR1w4iJSNoN0hnMY7Gpc/n8D4qSCJw8QqFWXf7cuAgnEHxBpweaVcPevC2l3KpjYCx3NypQQgaJg== diff@^4.0.1: version "4.0.2" @@ -924,38 +926,39 @@ express-unless@^1.0.0: resolved "https://registry.yarnpkg.com/express-unless/-/express-unless-1.0.0.tgz#ecd1c354c5ccf7709a8a17ece617934e037cccd8" integrity sha512-zXSSClWBPfcSYjg0hcQNompkFN/MxQQ53eyrzm9BYgik2ut2I7PxAf2foVqBRMYCwWaZx/aWodi+uk76npdSAw== -express@^4.17.1: - version "4.17.3" - resolved "https://registry.yarnpkg.com/express/-/express-4.17.3.tgz#f6c7302194a4fb54271b73a1fe7a06478c8f85a1" - integrity sha512-yuSQpz5I+Ch7gFrPCk4/c+dIBKlQUxtgwqzph132bsT6qhuzss6I8cLJQz7B3rFblzd6wtcI0ZbGltH/C4LjUg== +express@^4.19.2: + version "4.19.2" + resolved "https://registry.yarnpkg.com/express/-/express-4.19.2.tgz#e25437827a3aa7f2a827bc8171bbbb664a356465" + integrity sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q== dependencies: accepts "~1.3.8" array-flatten "1.1.1" - body-parser "1.19.2" + body-parser "1.20.2" content-disposition "0.5.4" content-type "~1.0.4" - cookie "0.4.2" + cookie "0.6.0" cookie-signature "1.0.6" debug "2.6.9" - depd "~1.1.2" + depd "2.0.0" encodeurl "~1.0.2" escape-html "~1.0.3" etag "~1.8.1" - finalhandler "~1.1.2" + finalhandler "1.2.0" fresh "0.5.2" + http-errors "2.0.0" merge-descriptors "1.0.1" methods "~1.1.2" - on-finished "~2.3.0" + on-finished "2.4.1" parseurl "~1.3.3" path-to-regexp "0.1.7" proxy-addr "~2.0.7" - qs "6.9.7" + qs "6.11.0" range-parser "~1.2.1" safe-buffer "5.2.1" - send "0.17.2" - serve-static "1.14.2" + send "0.18.0" + serve-static "1.15.0" setprototypeof "1.2.0" - statuses "~1.5.0" + statuses "2.0.1" type-is "~1.6.18" utils-merge "1.0.1" vary "~1.1.2" @@ -1012,17 +1015,17 @@ fill-range@^7.0.1: dependencies: to-regex-range "^5.0.1" -finalhandler@~1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.1.2.tgz#b7e7d000ffd11938d0fdb053506f6ebabe9f587d" - integrity sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA== +finalhandler@1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/finalhandler/-/finalhandler-1.2.0.tgz#7d23fe5731b207b4640e4fcd00aec1f9207a7b32" + integrity sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg== dependencies: debug "2.6.9" encodeurl "~1.0.2" escape-html "~1.0.3" - on-finished "~2.3.0" + on-finished "2.4.1" parseurl "~1.3.3" - statuses "~1.5.0" + statuses "2.0.1" unpipe "~1.0.0" find-up@^2.1.0: @@ -1171,15 +1174,15 @@ has@^1.0.3: dependencies: function-bind "^1.1.1" -http-errors@1.8.1: - version "1.8.1" - resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-1.8.1.tgz#7c3f28577cbc8a207388455dbd62295ed07bd68c" - integrity sha512-Kpk9Sm7NmI+RHhnj6OIWDI1d6fIoFAtFt9RLaTMRlg/8w49juAStsrBgp0Dp4OdxdVbRIeKhtCUvoi/RuAhO4g== +http-errors@2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-2.0.0.tgz#b7774a1486ef73cf7667ac9ae0858c012c57b9d3" + integrity sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ== dependencies: - depd "~1.1.2" + depd "2.0.0" inherits "2.0.4" setprototypeof "1.2.0" - statuses ">= 1.5.0 < 2" + statuses "2.0.1" toidentifier "1.0.1" iconv-lite@0.4.24: @@ -1368,9 +1371,9 @@ isexe@^2.0.0: integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= jose@^2.0.5: - version "2.0.6" - resolved "https://registry.yarnpkg.com/jose/-/jose-2.0.6.tgz#894ba19169af339d3911be933f913dd02fc57c7c" - integrity sha512-FVoPY7SflDodE4lknJmbAHSUjLCzE2H1F6MS0RYKMQ8SR+lNccpMf8R4eqkNYyyUjR5qZReOzZo5C5YiHOCjjg== + version "2.0.7" + resolved "https://registry.yarnpkg.com/jose/-/jose-2.0.7.tgz#3aabbaec70bff313c108b9406498a163737b16ba" + integrity sha512-5hFWIigKqC+e/lRyQhfnirrAqUdIPMB7SJRqflJaO29dW7q5DFvH1XCSTmv6PQ6pb++0k6MJlLRoS0Wv4s38Wg== dependencies: "@panva/asn1.js" "^1.0.0" @@ -1529,18 +1532,10 @@ lodash@^4.17.21: resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== -long@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/long/-/long-4.0.0.tgz#9a7b71cfb7d361a194ea555241c92f7468d5bf28" - integrity sha512-XsP+KhQif4bjX1kbuSiySJFNAehNxgLb6hPRGJ9QsUr8ajHkuXGdrHmFUTUUXhDwVX2R5bY4JNZEwbUiMhV+MA== - -lru-cache@^4.1.3: - version "4.1.5" - resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.5.tgz#8bbe50ea85bed59bc9e33dcab8235ee9bcf443cd" - integrity sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g== - dependencies: - pseudomap "^1.0.2" - yallist "^2.1.2" +long@^5.2.1: + version "5.2.3" + resolved "https://registry.yarnpkg.com/long/-/long-5.2.3.tgz#a3ba97f3877cf1d778eccbcb048525ebb77499e1" + integrity sha512-lcHwpNoggQTObv5apGNCTdJrO69eHOZMi4BNC+rTLER8iHAqGrUVeLh/irVIM7zTw2bOXA8T6uNPeujwOLg/2Q== lru-cache@^6.0.0: version "6.0.0" @@ -1549,6 +1544,16 @@ lru-cache@^6.0.0: dependencies: yallist "^4.0.0" +lru-cache@^7.14.1: + version "7.18.3" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-7.18.3.tgz#f793896e0fd0e954a59dfdd82f0773808df6aa89" + integrity sha512-jumlc0BIUrS3qJGgIkWZsyfAM7NCWiBcCDhnd+3NNM5KbBmLTgHVfWBcg6W+rLUsIpzpERPsvwUP7CckAQSOoA== + +lru-cache@^8.0.0: + version "8.0.5" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-8.0.5.tgz#983fe337f3e176667f8e567cfcce7cb064ea214e" + integrity sha512-MhWWlVnuab1RG5/zMRRcVGXZLCXrZTgfwMikgzCegsPnG62yDQo5JnqKkrK4jO5iKqDAZGItAqN5CtKBCBWRUA== + lru-cache@~4.0.0: version "4.0.2" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.0.2.tgz#1d17679c069cda5d040991a09dbc2c0db377e55e" @@ -1647,26 +1652,26 @@ ms@2.1.3, ms@^2.1.1: resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== -mysql2@^2.3.0: - version "2.3.3" - resolved "https://registry.yarnpkg.com/mysql2/-/mysql2-2.3.3.tgz#944f3deca4b16629052ff8614fbf89d5552545a0" - integrity sha512-wxJUev6LgMSgACDkb/InIFxDprRa6T95+VEoR+xPvtngtccNH2dGjEB/fVZ8yg1gWv1510c9CvXuJHi5zUm0ZA== +mysql2@^3.9.7: + version "3.9.7" + resolved "https://registry.yarnpkg.com/mysql2/-/mysql2-3.9.7.tgz#843755daf65b5ef08afe545fe14b8fb62824741a" + integrity sha512-KnJT8vYRcNAZv73uf9zpXqNbvBG7DJrs+1nACsjZP1HMJ1TgXEy8wnNilXAn/5i57JizXKtrUtwDB7HxT9DDpw== dependencies: - denque "^2.0.1" + denque "^2.1.0" generate-function "^2.3.1" iconv-lite "^0.6.3" - long "^4.0.0" - lru-cache "^6.0.0" - named-placeholders "^1.1.2" + long "^5.2.1" + lru-cache "^8.0.0" + named-placeholders "^1.1.3" seq-queue "^0.0.5" sqlstring "^2.3.2" -named-placeholders@^1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/named-placeholders/-/named-placeholders-1.1.2.tgz#ceb1fbff50b6b33492b5cf214ccf5e39cef3d0e8" - integrity sha512-wiFWqxoLL3PGVReSZpjLVxyJ1bRqe+KKJVbr4hGs1KWfTZTQyezHFBbuKj9hsizHyGV2ne7EMjHdxEGAybD5SA== +named-placeholders@^1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/named-placeholders/-/named-placeholders-1.1.3.tgz#df595799a36654da55dda6152ba7a137ad1d9351" + integrity sha512-eLoBxg6wE/rZkJPhU/xRX1WTpkFEwDJEN96oxFrTsqBdbT5ec295Q+CoHrL9IT0DipqKhmGcaZmwOt8OON5x1w== dependencies: - lru-cache "^4.1.3" + lru-cache "^7.14.1" natural-compare@^1.4.0: version "1.4.0" @@ -1712,10 +1717,10 @@ object.values@^1.1.5: define-properties "^1.1.3" es-abstract "^1.19.1" -on-finished@~2.3.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/on-finished/-/on-finished-2.3.0.tgz#20f1336481b083cd75337992a16971aa2d906947" - integrity sha1-IPEzZIGwg811M3mSoWlxqi2QaUc= +on-finished@2.4.1: + version "2.4.1" + resolved "https://registry.yarnpkg.com/on-finished/-/on-finished-2.4.1.tgz#58c8c44116e54845ad57f14ab10b03533184ac3f" + integrity sha512-oVlzkg3ENAhCk2zdv7IJwd/QUD4z2RxRwpkcGY8psCVcCYZNq4wYnVWALHM+brtuJjePWiYF/ClmuDr8Ch5+kg== dependencies: ee-first "1.1.1" @@ -1834,7 +1839,7 @@ proxy-addr@~2.0.7: forwarded "0.2.0" ipaddr.js "1.9.1" -pseudomap@^1.0.1, pseudomap@^1.0.2: +pseudomap@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3" integrity sha1-8FKijacOYYkX7wqKw0wa5aaChrM= @@ -1844,10 +1849,12 @@ punycode@^2.1.0: resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== -qs@6.9.7: - version "6.9.7" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.9.7.tgz#4610846871485e1e048f44ae3b94033f0e675afe" - integrity sha512-IhMFgUmuNpyRfxA90umL7ByLlgRXu6tIfKPpF5TmcfRLlLCckfP/g3IQmju6jjpu+Hh8rA+2p6A27ZSPOOHdKw== +qs@6.11.0: + version "6.11.0" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.0.tgz#fd0d963446f7a65e1367e01abd85429453f0c37a" + integrity sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q== + dependencies: + side-channel "^1.0.4" queue-microtask@^1.2.2: version "1.2.3" @@ -1859,13 +1866,13 @@ range-parser@~1.2.1: resolved "https://registry.yarnpkg.com/range-parser/-/range-parser-1.2.1.tgz#3cf37023d199e1c24d1a55b84800c2f3e6468031" integrity sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg== -raw-body@2.4.3: - version "2.4.3" - resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.4.3.tgz#8f80305d11c2a0a545c2d9d89d7a0286fcead43c" - integrity sha512-UlTNLIcu0uzb4D2f4WltY6cVjLi+/jEN4lgEUj3E04tpMDpUlkBo/eSn6zou9hum2VMNpCCUone0O0WeJim07g== +raw-body@2.5.2: + version "2.5.2" + resolved "https://registry.yarnpkg.com/raw-body/-/raw-body-2.5.2.tgz#99febd83b90e08975087e8f1f9419a149366b68a" + integrity sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA== dependencies: bytes "3.1.2" - http-errors "1.8.1" + http-errors "2.0.0" iconv-lite "0.4.24" unpipe "1.0.0" @@ -1953,39 +1960,39 @@ semver@^7.2.1, semver@^7.3.5: dependencies: lru-cache "^6.0.0" -send@0.17.2: - version "0.17.2" - resolved "https://registry.yarnpkg.com/send/-/send-0.17.2.tgz#926622f76601c41808012c8bf1688fe3906f7820" - integrity sha512-UJYB6wFSJE3G00nEivR5rgWp8c2xXvJ3OPWPhmuteU0IKj8nKbG3DrjiOmLwpnHGYWAVwA69zmTm++YG0Hmwww== +send@0.18.0: + version "0.18.0" + resolved "https://registry.yarnpkg.com/send/-/send-0.18.0.tgz#670167cc654b05f5aa4a767f9113bb371bc706be" + integrity sha512-qqWzuOjSFOuqPjFe4NOsMLafToQQwBSOEpS+FwEt3A2V3vKubTquT3vmLTQpFgMXp8AlFWFuP1qKaJZOtPpVXg== dependencies: debug "2.6.9" - depd "~1.1.2" - destroy "~1.0.4" + depd "2.0.0" + destroy "1.2.0" encodeurl "~1.0.2" escape-html "~1.0.3" etag "~1.8.1" fresh "0.5.2" - http-errors "1.8.1" + http-errors "2.0.0" mime "1.6.0" ms "2.1.3" - on-finished "~2.3.0" + on-finished "2.4.1" range-parser "~1.2.1" - statuses "~1.5.0" + statuses "2.0.1" seq-queue@^0.0.5: version "0.0.5" resolved "https://registry.yarnpkg.com/seq-queue/-/seq-queue-0.0.5.tgz#d56812e1c017a6e4e7c3e3a37a1da6d78dd3c93e" integrity sha1-1WgS4cAXpuTnw+Ojeh2m143TyT4= -serve-static@1.14.2: - version "1.14.2" - resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.14.2.tgz#722d6294b1d62626d41b43a013ece4598d292bfa" - integrity sha512-+TMNA9AFxUEGuC0z2mevogSnn9MXKb4fa7ngeRMJaaGv8vTwnIEkKi+QGvPt33HSnf8pRS+WGM0EbMtCJLKMBQ== +serve-static@1.15.0: + version "1.15.0" + resolved "https://registry.yarnpkg.com/serve-static/-/serve-static-1.15.0.tgz#faaef08cffe0a1a62f60cad0c4e513cff0ac9540" + integrity sha512-XGuRDNjXUijsUL0vl6nSD7cwURuzEgglbOaFuZM9g3kwDXOWVTck0jLzjPzGD+TazWbboZYu52/9/XPdUgne9g== dependencies: encodeurl "~1.0.2" escape-html "~1.0.3" parseurl "~1.3.3" - send "0.17.2" + send "0.18.0" setprototypeof@1.2.0: version "1.2.0" @@ -2050,10 +2057,10 @@ sqlstring@^2.3.2: resolved "https://registry.yarnpkg.com/sqlstring/-/sqlstring-2.3.3.tgz#2ddc21f03bce2c387ed60680e739922c65751d0c" integrity sha512-qC9iz2FlN7DQl3+wjwn3802RTyjCx7sDvfQEXchwa6CWOx07/WVfh91gBmQ9fahw8snwGEWU3xGzOt4tFyHLxg== -"statuses@>= 1.5.0 < 2", statuses@~1.5.0: - version "1.5.0" - resolved "https://registry.yarnpkg.com/statuses/-/statuses-1.5.0.tgz#161c7dac177659fd9811f43771fa99381478628c" - integrity sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow= +statuses@2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/statuses/-/statuses-2.0.1.tgz#55cb000ccf1d48728bd23c685a063998cf1a1b63" + integrity sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ== string-width@^4.2.3: version "4.2.3" @@ -2309,7 +2316,7 @@ xtend@^4.0.0: resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== -yallist@^2.0.0, yallist@^2.1.2: +yallist@^2.0.0: version "2.1.2" resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52" integrity sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI= From 728e5754ea0e785ce1772b6b46b47c6ce1553e4a Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Tue, 21 May 2024 14:49:53 -0400 Subject: [PATCH 56/57] Add CMH environment to node prod workflow (#397) --- .github/workflows/node-prod.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/node-prod.yml b/.github/workflows/node-prod.yml index cfc5a06f..51f76955 100644 --- a/.github/workflows/node-prod.yml +++ b/.github/workflows/node-prod.yml @@ -118,6 +118,14 @@ jobs: G4RD_GRANT_TYPE: ${{ secrets.G4RD_GRANT_TYPE }} G4RD_TOKEN_URL: ${{ secrets.G4RD_TOKEN_URL }} G4RD_CLIENT_ID: ${{ secrets.G4RD_CLIENT_ID }} + CMH_AZURE_CLIENT_ID: ${{ secrets.CMH_AZURE_CLIENT_ID }} + CMH_AZURE_CLIENT_SECRET: ${{ secrets.CMH_AZURE_CLIENT_SECRET }} + CMH_TOKEN_URL: ${{ secrets.CMH_TOKEN_URL }} + CMH_RESOURCE: ${{ secrets.CMH_RESOURCE }} + CMH_SCOPE: ${{ secrets.CMH_SCOPE }} + CMH_GRANT_TYPE: ${{ secrets.CMH_GRANT_TYPE }} + CMH_GENE42_SECRET: ${{ secrets.CMH_GENE42_SECRET }} + CMH_URL: ${{ secrets.CMH_URL }} KEYCLOAK_AUTH_URL: ${{ secrets.KEYCLOAK_AUTH_URL }} KEYCLOAK_REALM: ${{ secrets.KEYCLOAK_REALM }} KEYCLOAK_CLIENT_ID: ${{ secrets.KEYCLOAK_CLIENT_ID }} From 3a83926450ad4383b37f7c6a47de49ef5f62bf92 Mon Sep 17 00:00:00 2001 From: Mack <11793063+frewmack@users.noreply.github.com> Date: Mon, 27 May 2024 10:31:01 -0400 Subject: [PATCH 57/57] Trim whitespace from sources in environment (#399) --- react/src/constants/sources.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/react/src/constants/sources.ts b/react/src/constants/sources.ts index a8c3972e..d2d3d67f 100644 --- a/react/src/constants/sources.ts +++ b/react/src/constants/sources.ts @@ -1,3 +1,3 @@ -const SOURCES = (process.env.REACT_APP_SOURCE_LIST || '').split(','); +const SOURCES = (process.env.REACT_APP_SOURCE_LIST || '').split(',').map(v => v.trim()); export default SOURCES;