Skip to content

fix data-processing hard refresh bug#1060

Merged
alexvpickering merged 1 commit into
masterfrom
fix-processing-refresh
May 21, 2026
Merged

fix data-processing hard refresh bug#1060
alexvpickering merged 1 commit into
masterfrom
fix-processing-refresh

Conversation

@alexvpickering
Copy link
Copy Markdown
Contributor

@alexvpickering alexvpickering commented May 21, 2026

Description

Fix React 18 SSR hydration for data-processing page

Use wrapper.getInitialAppProps() for proper Redux state serialization and
client-side HYDRATE action dispatch during Next.js SSR hydration.

Previously, the manual getInitialProps implementation didn't trigger the
HYDRATE action on the client, causing Redux state to be empty during hard
refresh. Server correctly loaded experiment data with 24 samples, but client
received empty sampleIds array due to hydration mismatch.

Changes:

  • Wrap getInitialProps with wrapper.getInitialAppProps() callback
  • Remove store destructuring from ctx (now passed as wrapper parameter)
  • Remove manual store fallback initialization (guaranteed by wrapper)
  • Use store parameter directly from wrapper callback

Fixes plots not showing and filters appearing disabled on hard refresh of
data-processing page.

Details

URL to issue

N/A

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

N/A

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.
  • All new dependency licenses have been checked for compatibility.

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.

Signed-off-by: Alex Pickering <alexvpickering@gmail.com>
@alexvpickering alexvpickering added the safe to run Sensitive jobs are safe to be run label May 21, 2026
@dbmi-svc-checkmarx
Copy link
Copy Markdown

Logo
Checkmarx One – Scan Summary & Details43a05425-8460-4732-ac2b-5548d982d6ed

Great job! No new security vulnerabilities introduced in this pull request


Use @Checkmarx to interact with Checkmarx PR Assistant.
Examples:
@Checkmarx how are you able to help me?
@Checkmarx rescan this PR

@github-actions
Copy link
Copy Markdown
Contributor

📦 Next.js Bundle Analysis for ui

This analysis was generated by the Next.js Bundle Analysis action. 🤖

🎉 Global Bundle Size Decreased

Page Size (compressed)
global 684.86 KB (-36 B)
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!

@alexvpickering alexvpickering merged commit c7c7414 into master May 21, 2026
25 of 26 checks passed
@alexvpickering alexvpickering deleted the fix-processing-refresh branch May 21, 2026 20:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

safe to run Sensitive jobs are safe to be run

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants