Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

1902 remove project from redux #752

Merged
merged 57 commits into from
Jul 4, 2022
Merged

Conversation

cosa65
Copy link
Member

@cosa65 cosa65 commented Jun 29, 2022

Description

This is a pretty big PR, so talk to me to have a call and go over it together

But as a brief explanation of the general rule I followed:
I focused on replacing the project-related redux slice/action creators/actions/reducers with experiment counterparts.

I didn't try to remove the word project from every place where it was, but rather focus on just removing the core part of project (redux). My reasoning for this is that the project redux slice is the part that involves changing a lot of different files without any way around that while cleaning it up from every place (for example, from the samples side of redux) is simpler and doesn't have as much coupling with a lot of different parts of the code.

Details

URL to issue

https://biomage.atlassian.net/browse/BIOMAGE-1902

Link to staging deployment URL (or set N/A)

https://ui-martinfosco-ui752.scp-staging.biomage.net/

Links to any PRs or resources related to this PR

Integration test branch

master

Merge checklist

Your changes will be ready for merging after all of the steps below have been completed.

Code updates

Have best practices and ongoing refactors being observed in this PR

  • Migrated any selector / reducer used to the new format.

Manual/unit testing

  • Tested changes using InfraMock locally or no tests required for change, e.g. Kubernetes chart updates.
  • Validated that current unit tests for code work as expected and are sufficient for code coverage or no unit tests required for change, e.g. documentation update.
  • Unit tests written or no unit tests required for change, e.g. documentation update.

Integration testing

You must check the box below to run integration tests on the latest commit on your PR branch.
Integration tests have to pass before the PR can be merged. Without checking the box, your PR
will not pass the required status checks for merging.

  • Started end-to-end tests on the latest commit.

Documentation updates

  • Relevant Github READMEs updated or no GitHub README updates required.
  • Relevant Wiki pages created/updated or no Wiki updates required.

Optional

  • Staging environment is unstaged before merging.
  • Photo of a cute animal attached to this PR.

@cosa65 cosa65 changed the title 1902 remove project from code [DRAFT] 1902 remove project from code Jun 29, 2022
@github-actions
Copy link
Contributor

github-actions bot commented Jun 30, 2022

📦 Next.js Bundle Analysis

This analysis was generated by the next.js bundle analysis action 🤖

🎉 Global Bundle Size Decreased

Page Size (compressed)
global 516.73 KB (🟢 -1.81 KB)
Details

The global bundle is the javascript bundle that loads alongside every page. It is in its own category because its impact is much higher - an increase to its size means that every page on your website loads slower, and a decrease means every page loads faster.

Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis

If you want further insight into what is behind the changes, give @next/bundle-analyzer a try!

Twelve Pages Changed Size

The following pages changed size from the code in this PR compared to its base branch:

Page Size (compressed) First Load
/data-management 248.41 KB (🟢 -314 B) 765.14 KB
/experiments/[experimentId]/data-exploration 535.28 KB (🟢 -274 B) 1.03 MB
/experiments/[experimentId]/data-processing 499.26 KB (🟢 -254 B) 1015.99 KB
/experiments/[experimentId]/plots-and-tables/dot-plot 476.67 KB (🟢 -274 B) 993.41 KB
/experiments/[experimentId]/plots-and-tables/embedding-categorical 473.2 KB (🟢 -274 B) 989.93 KB
/experiments/[experimentId]/plots-and-tables/embedding-continuous 473.9 KB (🟢 -274 B) 990.63 KB
/experiments/[experimentId]/plots-and-tables/frequency 475.09 KB (🟢 -274 B) 991.82 KB
/experiments/[experimentId]/plots-and-tables/heatmap 547.26 KB (🟢 -274 B) 1.04 MB
/experiments/[experimentId]/plots-and-tables/marker-heatmap 572.93 KB (🟢 -274 B) 1.06 MB
/experiments/[experimentId]/plots-and-tables/violin 474.13 KB (🟢 -274 B) 990.87 KB
/experiments/[experimentId]/plots-and-tables/volcano 477.47 KB (🟢 -274 B) 994.2 KB
/settings/profile 26.11 KB (🟡 +746 B) 542.85 KB
Details

Only the gzipped size is provided here based on an expert tip.

First Load is the size of the global bundle plus the bundle for the individual page. If a user were to show up to your website and land on a given page, the first load size represents the amount of javascript that user would need to download. If next/link is used, subsequent page loads would only need to download that page's bundle (the number in the "Size" column), since the global bundle has already been downloaded.

Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis

Next to the size is how much the size has increased or decreased compared with the base branch of this PR. If this percentage has increased by 20% or more, there will be a red status indicator applied, indicating that special attention should be given to this.

@cosa65 cosa65 changed the title [DRAFT] 1902 remove project from code 1902 remove project from code Jun 30, 2022
@cosa65 cosa65 marked this pull request as ready for review June 30, 2022 20:14
@codecov
Copy link

codecov bot commented Jun 30, 2022

Codecov Report

Merging #752 (e06969f) into master (a689608) will decrease coverage by 0.10%.
The diff coverage is 91.50%.

@@            Coverage Diff             @@
##           master     #752      +/-   ##
==========================================
- Coverage   83.50%   83.40%   -0.11%     
==========================================
  Files         478      463      -15     
  Lines        7956     7844     -112     
  Branches     1549     1534      -15     
==========================================
- Hits         6644     6542     -102     
+ Misses       1258     1249       -9     
+ Partials       54       53       -1     
Impacted Files Coverage Δ
src/components/data-management/MetadataColumn.jsx 63.15% <0.00%> (ø)
.../actions/experiments/updateValueInMetadataTrack.js 100.00% <ø> (ø)
src/redux/actions/samples/loadSamples.js 96.55% <ø> (ø)
...rc/redux/reducers/experiments/experimentsCreate.js 100.00% <ø> (ø)
...rc/redux/reducers/experiments/experimentsDelete.js 100.00% <ø> (ø)
...rc/redux/reducers/experiments/experimentsSaving.js 100.00% <ø> (ø)
src/redux/reducers/samples/initialState.js 100.00% <ø> (ø)
src/utils/AppRouteProvider.jsx 91.89% <ø> (ø)
...utils/data-management/calculateGem2sRerunStatus.js 100.00% <ø> (ø)
...s/data-management/experimentSharing/sendInvites.js 87.50% <ø> (ø)
... and 37 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a689608...e06969f. Read the comment docs.

@cosa65 cosa65 changed the title 1902 remove project from code 1902 remove project from redux Jun 30, 2022
@cosa65 cosa65 requested a review from aerlaut July 1, 2022 11:06
Copy link
Contributor

@aerlaut aerlaut left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Made comments

src/components/data-management/NewProjectModal.jsx Outdated Show resolved Hide resolved
src/pages/data-management/index.jsx Outdated Show resolved Hide resolved
src/redux/actions/experiments/deleteMetadataTrack.js Outdated Show resolved Hide resolved
src/__test__/utils/upload/processUpload.test.js Outdated Show resolved Hide resolved
@@ -39,7 +39,7 @@ const MetadataPopover = (props) => {
onCancel();
}}
deleteEnabled={false}
value={`Track ${existingMetadata.filter((key) => key.match('Track-')).length + 1}`}
value={`Track ${existingMetadata.filter((key) => key.match('Track_')).length + 1}`}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unrelated bug that is in prod right now, default create metadata track names are not scaling correctly

Copy link
Contributor

@aerlaut aerlaut left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@cosa65 cosa65 merged commit 5c6233c into master Jul 4, 2022
@cosa65 cosa65 deleted the 1902-remove-project-from-code branch July 4, 2022 20:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants