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

fix: localize debounced settings updates #9513

Merged
merged 2 commits into from
Jun 18, 2024

Conversation

ashtonG
Copy link
Contributor

@ashtonG ashtonG commented Jun 13, 2024

Ticket

ET-287

Description

This pr solves some race conditions that were added in #9220 by undoing the global settings debounce and instead localizing it to the column width changes the bug was talking about. There's a light refacator of userSettings#setPartial which should allow it to work on any io-ts type that has props.

Test Plan

  1. Open your browsers devtools and navigate to the network tab.
  2. navigate the page to the new experiment list.
  3. change the sort order either by using the column header menu or the dropdown menu. Note that there should be one POST request to settings per change.
  4. change the width of any column. Only one POST request should be made when the column width is done moving.

Checklist

  • Changes have been manually QA'd
  • User-facing API changes need the "User-facing API Change" label.
  • Release notes should be added as a separate file under docs/release-notes/.
    See Release Note for details.
  • Licenses should be included for new code which was copied and/or modified from any external code.

This pr solves some race conditions that were added in #9220 by undoing
the global settings debounce and instead localizing it to the column
width changes the bug was talking about. There's a light refacator of
`userSettings#setPartial` which should allow it to work on any io-ts
type that has props.
@ashtonG ashtonG requested a review from a team as a code owner June 13, 2024 15:29
@cla-bot cla-bot bot added the cla-signed label Jun 13, 2024
Copy link

codecov bot commented Jun 13, 2024

Codecov Report

Attention: Patch coverage is 63.15789% with 70 lines in your changes missing coverage. Please review.

Project coverage is 45.18%. Comparing base (fec31a1) to head (01d4f40).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #9513      +/-   ##
==========================================
- Coverage   49.31%   45.18%   -4.13%     
==========================================
  Files        1241      918     -323     
  Lines      161338   120913   -40425     
  Branches     2868     2886      +18     
==========================================
- Hits        79566    54639   -24927     
+ Misses      81600    66103   -15497     
+ Partials      172      171       -1     
Flag Coverage Δ
harness ?
web 46.24% <63.15%> (+1.32%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
webui/react/src/hooks/useDebouncedSettings.ts 100.00% <100.00%> (ø)
webui/react/src/hooks/useTypedParams.ts 94.07% <100.00%> (ø)
webui/react/src/stores/userSettings.tsx 88.34% <100.00%> (+1.30%) ⬆️
webui/react/src/utils/asValueObject.ts 94.73% <100.00%> (-0.57%) ⬇️
webui/react/src/utils/iotsHelpers.ts 100.00% <100.00%> (ø)
...bui/react/src/pages/F_ExpList/F_ExperimentList.tsx 0.00% <0.00%> (ø)
webui/react/src/pages/FlatRuns/FlatRuns.tsx 0.00% <0.00%> (ø)
...ebui/react/src/pages/FlatRuns/FlatRuns.settings.ts 0.00% <0.00%> (ø)
...t/src/pages/F_ExpList/F_ExperimentList.settings.ts 0.00% <0.00%> (ø)

... and 348 files with indirect coverage changes

Copy link

netlify bot commented Jun 13, 2024

Deploy Preview for determined-ui ready!

Name Link
🔨 Latest commit 01d4f40
🔍 Latest deploy log https://app.netlify.com/sites/determined-ui/deploys/6671a1f07259f60008ec687a
😎 Deploy Preview https://deploy-preview-9513--determined-ui.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@ashtonG ashtonG merged commit 8006e2e into main Jun 18, 2024
84 of 97 checks passed
@ashtonG ashtonG deleted the bug/ET-287/localize-debounced-settings branch June 18, 2024 15:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants