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

Metadata uploader - PARSE FILE #1362

Merged
merged 43 commits into from
Oct 24, 2022

Conversation

ksierks
Copy link
Contributor

@ksierks ksierks commented Sep 8, 2022

Description of changes

What did you change in this pull request? Provide a description of files changed, user interactions changed, etc. Include how to test your changes.

Related issue

Link to the GitHub issue this pull request addresses using the #issuenum format. If it completes an issue, use Fixes #issuenum to automatically close the issue.

Checklist

Things for the developer to confirm they've done before the PR should be accepted:

  • CHANGELOG.md (and UPGRADING.md if necessary) updated with information for new change.
  • Tests added (or description of how to test) for any new features.
  • User documentation updated for UI or technical changes.

@joshsadam
Copy link
Contributor

A couple of comments:

  1. When you click the next step button, ensure you show some sort of indicator (maybe a spinner on the button) to give the user some affordance that something is going on.
  2. Can you try using virtualized tables row, I tried to load a huge file into the uploader (4000 samples w/ 40 columns). The table does not react to any scroll events. Too many DOM elements were created.

@joshsadam
Copy link
Contributor

Please make all these files TypeScript.

@joshsadam
Copy link
Contributor

Instead of modifying the metadata object imported from the spreadsheet, I think it would work better if you store the validation object, with a sample name key to look it up. This will prevent you from having to modify the entire metadata object (leaving 2 large objects in memory temporarily).

Instead up uploading one at a time, it might be a lot faster to do chunk uploads.

@ksierks ksierks marked this pull request as ready for review October 6, 2022 17:29
Copy link
Contributor

@joshsadam joshsadam left a comment

Choose a reason for hiding this comment

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

I starting reviewing your code this morning, but I need you to do me a favour first. This first file that I have been reviewing, all my comments are errors that are picked up by eslint. Can you go through your PR and make sure that you fix the eslint and any other error the editor is warning you about (if possible). I have also started using a plugin called sonar lint that has been really helpful in finding other code smells that I would have missed. Thanks.

@ksierks ksierks requested a review from joshsadam October 7, 2022 18:36
@joshsadam
Copy link
Contributor

I found a situation where if a user refreshes the page while doing an upload their state is lost but they remain on the step they were at:
wrong-state
What might work well is keeping the state of the metadata in sessionStorage, then onload check the step and see if there is anything is storage. You should probably confirm the project id and maybe timestamp it.

Copy link
Contributor

@joshsadam joshsadam left a comment

Choose a reason for hiding this comment

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

Sorry there is a big request in here that I wanted to get to you. I will still go through the other files.

Copy link
Contributor

@joshsadam joshsadam left a comment

Choose a reason for hiding this comment

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

A couple more things

@ksierks ksierks requested a review from joshsadam October 19, 2022 17:01
@ksierks ksierks changed the title Metadata uploader parse file Metadata uploader - PARSE FILE Oct 20, 2022
Copy link
Contributor

@joshsadam joshsadam left a comment

Choose a reason for hiding this comment

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

Just one tiny thing

Copy link
Member

@ericenns ericenns left a comment

Choose a reason for hiding this comment

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

👍 Approved thanks for completing the file parsing, I have tested it and it worked as I expected.

@ericenns ericenns merged commit 73a4670 into metadata-uploader-base Oct 24, 2022
@ksierks ksierks mentioned this pull request Jan 13, 2023
3 tasks
@ksierks ksierks deleted the metadata-uploader-parse-file branch January 23, 2023 16:50
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.

3 participants