diff --git a/breadbox/README.md b/breadbox/README.md index 0c08e163..3ecf7208 100644 --- a/breadbox/README.md +++ b/breadbox/README.md @@ -1,6 +1,6 @@ # Breadbox -Breadbox is a persistent service for storing and retrieving data for the [DepMap portal](https://github.com/broadinstitute/depmap). It aims to simplify and consolidate formats across datasets that are uploaded by CDS during portal database re-builds, by users transiently, and by users for private groups. It consists of a persistent database to store the datasets and an API for uploading and fetching from the dataset. +Breadbox is a persistent service for storing and retrieving data for the [DepMap portal](https://github.com/broadinstitute/depmap-portal). It aims to simplify and consolidate formats across datasets that are uploaded by CDS during portal database re-builds, by users transiently, and by users for private groups. It consists of a persistent database to store the datasets and an API for uploading and fetching from the dataset. ## Setup @@ -54,7 +54,7 @@ To run tests, run ### Running Elara -Elara is the UI containing tools that use and interface with the Breadbox service. To run the elara app, see instructions for setup at https://github.com/broadinstitute/depmap/tree/master/frontend/packages/elara-frontend. +Elara is the UI containing tools that use and interface with the Breadbox service. To run the elara app, see instructions for setup at https://github.com/broadinstitute/depmap-portal/tree/master/frontend/packages/elara-frontend/README.md If trying to access Elara from the Depmap app (behind the `/breadbox` url prefix) locally, the Elara static files must exist at `depmap/breadbox/app/static/elara/` which are produced by running `yarn build` from the `elara/` directory. Additionally, the environment variable `HOST_SCHEME_OVERRIDE=http:127.0.0.1:5000` should be added to the `depmap/breadbox/.env` file. The Breadbox app must also be running first with the flag option `--use_proxy`. See instructions below for running Breadbox behind a proxy. diff --git a/frontend/README.md b/frontend/README.md index 44405609..2f811e82 100644 --- a/frontend/README.md +++ b/frontend/README.md @@ -13,15 +13,15 @@ directory. If two different packages share the same dependency, only one copy is installed in frontend/node_modules. But you won't often need to do this because it's run for you as part of the -[portal-backend/install_prereqs.sh](https://github.com/broadinstitute/depmap/blob/master/portal-backend/install_prereqs.sh#L16) +[portal-backend/install_prereqs.sh](https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/portal-backend/install_prereqs.sh#L39) script. ## Main packages In the ./packages directory you'll find two main projects: -- [elara-frontend](https://github.com/broadinstitute/depmap/tree/master/frontend/packages/elara-frontend#readme) -- [portal-frontend](https://github.com/broadinstitute/depmap/tree/master/frontend/packages/portal-frontend#readme) +- [elara-frontend](https://github.com/broadinstitute/depmap-portal/tree/master/frontend/packages/elara-frontend#readme) +- [portal-frontend](https://github.com/broadinstitute/depmap-portal/tree/master/frontend/packages/portal-frontend#readme) Each of these represents a different set of UI features. The Elara frontend is limited to Data Explorer (the original version, also known as the "interactive @@ -50,7 +50,7 @@ that's what you're used to. All it does is call `yarn dev:portal` for you). The two main frontends described above share a fair amount of code. The shared code is distributed across several libraries, scoped under the -[@depmap](https://github.com/broadinstitute/depmap/tree/master/frontend/packages/%40depmap) +[@depmap](https://github.com/broadinstitute/depmap-portal/tree/master/frontend/packages/%40depmap) directory. This is a naming convention to make them easily distinguishable from 3rd party libraries. diff --git a/frontend/packages/@depmap/data-explorer-2/README.md b/frontend/packages/@depmap/data-explorer-2/README.md index 411bd3ad..1a120fa0 100644 --- a/frontend/packages/@depmap/data-explorer-2/README.md +++ b/frontend/packages/@depmap/data-explorer-2/README.md @@ -5,7 +5,7 @@ Data Explorer 2.0 is the replacement for the original Data Explorer (a.k.a. original. Note that most of of the DE2 UI code is located in the -[../../portal-frontend/src/data-explorer-2/](https://github.com/broadinstitute/depmap/tree/0fa2d2e/frontend/packages/portal-frontend/src/data-explorer-2) +[../../portal-frontend/src/data-explorer-2/](https://github.com/broadinstitute/depmap-portal/tree/master/frontend/packages/portal-frontend/src/data-explorer-2) directory. That code will be migrated here over time. For now, only the ContextSelector is exported from this package. diff --git a/frontend/packages/@depmap/data-explorer-2/src/utils/misc.ts b/frontend/packages/@depmap/data-explorer-2/src/utils/misc.ts index d1279494..237635bf 100644 --- a/frontend/packages/@depmap/data-explorer-2/src/utils/misc.ts +++ b/frontend/packages/@depmap/data-explorer-2/src/utils/misc.ts @@ -93,7 +93,7 @@ export const isPartialSliceId = (value: string | null) => { }; // A more aggressive version of encodeURIComponent() to match this: -// https://github.com/broadinstitute/depmap/blob/af83d4d/portal-backend/depmap/vector_catalog/models.py#L358 +// https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/portal-backend/depmap/vector_catalog/models.py#L358 export const urlLibEncode = (s: string) => { return encodeURIComponent(s).replace( /[()*!']/g, diff --git a/frontend/packages/@depmap/globals/src/globals.ts b/frontend/packages/@depmap/globals/src/globals.ts index 2f4b11a7..66319fb8 100644 --- a/frontend/packages/@depmap/globals/src/globals.ts +++ b/frontend/packages/@depmap/globals/src/globals.ts @@ -20,15 +20,15 @@ function makeMockEnabledFeatures() { } // In the Portal, this is defined here: -// https://github.com/broadinstitute/depmap/blob/c1ecacb/portal-backend/depmap/templates/nav_footer/layout.html#L88 +// https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/portal-backend/depmap/templates/nav_footer/layout.html#L88 // In Elara, it's defined here: -// https://github.com/broadinstitute/depmap/blob/c1ecacb/frontend/packages/elara-frontend/webpack.common.js#L34-L36 +// https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/frontend/packages/elara-frontend/webpack.common.js#L34-L36 export const depmapContactUrl: string = (window as any).depmapContactUrl; // This is injected into the HTML by the Portal backend: -// https://github.com/broadinstitute/depmap/blob/c1ecacb/portal-backend/depmap/templates/nav_footer/layout.html#L87 +// https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/portal-backend/depmap/templates/nav_footer/layout.html#L88 // In Elara, it's instead "baked in" as a hardcoded feature list at build time: -// https://github.com/broadinstitute/depmap/blob/c1ecacb/frontend/packages/elara-frontend/webpack.common.js#L29-L33 +// https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/frontend/packages/elara-frontend/webpack.common.js#L29-L33 // If it doesn't exist on `window` then we assume we're running in a test // environment (like Jest or Storybook) and return a mock. export const enabledFeatures: Record = @@ -36,9 +36,9 @@ export const enabledFeatures: Record = // Currently, the `errorHandler` doesn't really do anything special outside of // logging to the console. In the Portal, it's defined here: -// https://github.com/broadinstitute/depmap/blob/c1ecacb/portal-backend/depmap/templates/nav_footer/layout.html#L102 +// https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/portal-backend/depmap/templates/nav_footer/layout.html#L103 // In Elara, it's defined here: -// https://github.com/broadinstitute/depmap/blob/c1ecacb/frontend/packages/elara-frontend/webpack.common.js#L37 +// https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/frontend/packages/elara-frontend/webpack.common.js#L37 export const errorHandler: { report: (message: string) => void; } = (window as any).errorHandler; @@ -46,9 +46,9 @@ export const errorHandler: { // The DepMap global is created by the portal-frontend's Webpack config. // There is no equivalent in elara-frontend and should be avoided there. // This is "set" by Webpack as part of its module loader. -// https://github.com/broadinstitute/depmap/blob/70396b2/frontend/packages/portal-frontend/webpack.common.js#L7-L13 -// All exported functions in file become its properties: -// https://github.com/broadinstitute/depmap/blob/70396b2/frontend/packages/portal-frontend/src/index.tsx +// https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/frontend/packages/portal-frontend/webpack.common.js#L7-L13 +// All exported functions in this file become its properties: +// https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/frontend/packages/portal-frontend/src/index.tsx // eslint-disable-next-line @typescript-eslint/ban-types export const DepMap: Record = "Proxy" in window diff --git a/portal-backend/README.md b/portal-backend/README.md index cbcef467..982e25ae 100644 --- a/portal-backend/README.md +++ b/portal-backend/README.md @@ -622,9 +622,9 @@ def view_MY_APP(): ``` 👉 Make sure to -[import it here](https://github.com/broadinstitute/depmap/blob/54005fb/portal-backend/depmap/app.py#L37) +[import it here](https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/portal-backend/depmap/app.py#L36) and -[register it here](https://github.com/broadinstitute/depmap/blob/54005fb/portal-backend/depmap/app.py#L383). +[register it here](https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/portal-backend/depmap/app.py#L382). #### Step #3: Create a new React app @@ -665,7 +665,7 @@ ReactDOM.render(, container); #### Step #4: Configure Webpack Now Webpack needs to know that your app should be considered its own bundle. To the -[webpack config](https://github.com/broadinstitute/depmap/blob/54005fb/frontend/packages/portal-frontend/webpack.common.js#L31), +[webpack config](https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/frontend/packages/portal-frontend/webpack.common.js#L31), add this line: ```js diff --git a/portal-backend/depmap/data_explorer_2/views.py b/portal-backend/depmap/data_explorer_2/views.py index 69997815..269b6c13 100644 --- a/portal-backend/depmap/data_explorer_2/views.py +++ b/portal-backend/depmap/data_explorer_2/views.py @@ -422,7 +422,7 @@ def unique_values_or_range(): # HACK: Infer if the values are lists by looking at the first member of the # series. If so, we assume it's a list of strings. When we rework this to # use BreadBox, we can take advantage of its "list_strings" AnnotationType. - # https://github.com/broadinstitute/depmap/blob/6f2b043/breadbox/app/models/dataset.py#L66 + # https://github.com/broadinstitute/depmap-portal/blob/a2e2cc9/breadbox-client/breadbox_client/models/annotation_type.py#L8 if isinstance(series[0], list): all_values = series.explode() if dataset_id == "mutation_protein_change_by_gene": diff --git a/portal-backend/depmap/package.json b/portal-backend/depmap/package.json index 9360a2d1..aaa7ed22 100644 --- a/portal-backend/depmap/package.json +++ b/portal-backend/depmap/package.json @@ -6,7 +6,7 @@ "scripts": { "test": "jest" }, - "repository": "https://github.com/broadinstitute/depmap", + "repository": "https://github.com/broadinstitute/depmap-portal", "author": "CDS Team ", "license": "MIT", "dependencies": {