Skip to content

Dependency updates for July 2026 - #1763

Open
gniezen wants to merge 19 commits into
developfrom
dep-updates-jul26
Open

Dependency updates for July 2026#1763
gniezen wants to merge 19 commits into
developfrom
dep-updates-jul26

Conversation

@gniezen

@gniezen gniezen commented Jul 23, 2026

Copy link
Copy Markdown
Member

As part of the dependency updates I have:

  • removed the jest electron runner as it is not maintained anymore
  • removed the rewire dependency as it is not maintained anymore
  • switched from eslint to exlint
  • changed oxlint warnings to errors and fixed them
  • upgraded to babel 8

@coderabbitai

coderabbitai Bot commented Jul 23, 2026

Copy link
Copy Markdown

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Summary by CodeRabbit

  • Improvements
    • Updated CI, development, and runtime environments to Node.js 24.18.0.
    • Refreshed Docker images and local development setup for smoother builds.
    • Improved shared application state and local storage reliability across supported environments.
    • Standardized macOS installer artifact naming.
  • Testing / Quality
    • Improved test environment setup with translation and browser compatibility support.
    • Updated linting and build validation for more consistent quality checks.
  • Documentation
    • Updated Linux Docker guidance and corrected device checklist wording and links.

Walkthrough

The PR updates Node to 24.18.0, replaces ESLint with Oxlint, modernizes build and test infrastructure, centralizes async action dependencies in appState, migrates tests away from rewire-based injection, and removes unused code across application and device-driver modules.

Changes

Runtime and application modernization

Layer / File(s) Summary
Runtime and build tooling
.circleci/config.yml, Dockerfile, Dockerfile.dev, .nvmrc, .config.js, .oxlintrc.json, package.json, babel.config.js, jest.setup.js, webpack.config*.mjs, README.md
Node version updated to 24.18.0. Oxlint configuration is added and ESLint scripts are replaced. Babel presets and polyfill configuration are simplified. Jest test environment changed from electron-runner to "node". Webpack iconv-lite rules are adjusted. Container and CI configurations updated.
Shared action state and async action refactoring
app/actions/appState.js, app/actions/async.js, test/app/actions/async.test.js, test/app/actions/sync.test.js, test/app/actions/utils.test.js
appState module introduced with shared services and versionInfo. Async thunks updated to source dependencies from appState instead of module scope. Tests remove __Rewire__ and __ResetDependency__ in favor of direct state mutation, Jest mocks, and beforeAll/afterEach hooks for deterministic OS-string initialization.
Application wiring and cleanup
app/components/*, app/containers/*, app/auth.js, app/main.dev.js, app/utils/config.i18next.cjs, lib/core/localStore.js, lib/core/api.js, lib/core/device.js, lib/commonFunctions.js, lib/crc.js, lib/driverManager.js, lib/serialDevice.js, test/app/reducers/*, test/lib/*
Unused imports (rollbar, metrics, pako, LoadingBar) removed. Redux mapStateToProps parameters renamed to indicate unused values. Electron import destructuring adjusted. Callback parameters standardized with underscore prefix. Storage fallback mockStore refactored to use closure-based mockData. Timezone validation error handling simplified. Test fixtures and variables cleaned up.

Device-driver cleanup

Layer / File(s) Summary
Shared driver foundations and utilities
lib/drivers/abbott/*, lib/drivers/allmedicus/agm4000.js, lib/drivers/bayer/bayerContourNext.js, lib/drivers/bluetoothLE/bluetoothLEDriver.js, lib/drivers/glucorx/glucoRxDriver.js, lib/drivers/i-sens/glucocardExpression.js, lib/drivers/roche/accuChekUSB.js, lib/serialDevice.js
Unused async and STX dependencies removed from Abbott drivers. Callback parameters renamed to underscore-prefixed names. Packet-padding creation switched from new Array(...) to Array.from({ length: ... }). Device string NUL-stripping regex adjusted. Serial port variable renamed internally. Truthy checks simplified for device-info overrides.
Medtronic driver and processing cleanup
lib/drivers/medtronic/medtronicDriver.js, lib/drivers/medtronic600/medtronic600Driver.js, lib/drivers/medtronic/processData.js, lib/drivers/medtronic/cli/blob_loader.js
Medtronic packet padding uses Array.from({ length: ... }). History-page handling and parser callbacks renamed. Unused locals (waitTimer, messageLength, done, message, test) removed. Parser success parameters renamed. Lint suppressions added for NUL-stripping control-regex. Process-data basalSchedules global removed. BOLUS_WIZARD_CHANGE handling simplified.
OneTouch driver parsing cleanup
lib/drivers/onetouch/oneTouchUltra2.js, lib/drivers/onetouch/oneTouchUltraMini.js, lib/drivers/onetouch/oneTouchVerioBLE.js, lib/drivers/onetouch/oneTouchVerioIQ.js
Command-builder functions (buildDeleteAllRecords, buildReadDateFormat) removed. Parsed record fields (day-of-week, alpha value, meal comment, unit-of-measure) removed. Callback parameters renamed with underscore prefix. Time array changed from new Array(4) to Array.from({ length: 4 }). NUL-stripping lint suppressions added.
Scripts and documentation corrections
scripts/json-compare.js, scripts/vt-submit.js, scripts/whitelisting/av-submit.js, docs/checklists/README.md, docs/checklisttemplates/CGMChecklist.md, docs/state/StateTreeGlossary.md, electron-builder-publish.js
JSON comparison predicate duplicate removed. Header spread syntax simplified. Email template escaping removed. Checklist links corrected. CGM documentation language updated. Glossary field references and spelling corrected. DMG and macOS artifact naming prefix changed to Tidepool-Uploader.

Estimated code review effort: 4 (Complex) | ~50 minutes

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 18.18% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the primary dependency and tooling updates in the changeset.
Description check ✅ Passed The description accurately references the main dependency, test runner, linting, and Babel changes.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch dep-updates-jul26

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 7

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
Dockerfile.dev (1)

22-23: 🩺 Stability & Availability | 🟠 Major | ⚡ Quick win

Use the published Node archive format by default.

curl -O follows Node’s redirect and does not fail on the final response here, but the Dockerfile still extracts a wrong .tar.gz archive instead of the published .tar.xz, producing an invalid Node install. Use curl -fsSLO with node-$NODE_VERSION-linux-x64.tar.xz and extract with tar -xJf.

Proposed fix
-RUN curl -O https://nodejs.org/download/release/$NODE_VERSION/node-$NODE_VERSION-linux-x64.tar.gz \
-    && tar -xzf node-$NODE_VERSION-linux-x64.tar.gz -C /usr/local/bin
+RUN curl -fsSLO https://nodejs.org/download/release/$NODE_VERSION/node-$NODE_VERSION-linux-x64.tar.xz \
+    && tar -xJf node-$NODE_VERSION-linux-x64.tar.xz -C /usr/local/bin
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@Dockerfile.dev` around lines 22 - 23, Update the Node download and extraction
command to fetch node-$NODE_VERSION-linux-x64.tar.xz using curl -fsSLO, then
extract that archive with tar -xJf into /usr/local/bin instead of using the
.tar.gz format.
test/app/actions/sync.test.js (1)

698-719: 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Restore periodMedtronic600 in teardown, not after assertions.

A failed assertion skips each inline restore and leaks the changed period into later tests.

  • test/app/actions/sync.test.js#L698-L719: restore the original period from afterEach or finally.
  • test/app/actions/sync.test.js#L788-L813: restore the original period from afterEach or finally.
  • test/app/actions/sync.test.js#L866-L896: restore the original period from afterEach or finally.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@test/app/actions/sync.test.js` around lines 698 - 719, Move restoration of
uploadDataPeriod.periodMedtronic600 out of the inline assertion flow and into
guaranteed cleanup for the affected tests. In test/app/actions/sync.test.js
ranges 698-719, 788-813, and 866-896, preserve each original period value and
restore it via afterEach or finally so cleanup runs even when assertions fail.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@app/actions/async.js`:
- Line 648: Update the regex used in the filename matching logic to remove the
global flag, escape the dot before the ibf extension, and match the requested
extension directly without accepting lookalike filenames.

In `@babel.config.js`:
- Around line 21-26: Update the Babel configuration’s preset-env options by
removing useBuiltIns, corejs, and bugfixes, and add
babel-plugin-polyfill-corejs3 configured with method usage-global. Remove the
obsolete `@babel/plugin-syntax-dynamic-import` and
`@babel/plugin-syntax-import-meta` entries while preserving the remaining
supported Babel plugins and settings.

In `@jest.setup.js`:
- Around line 3-10: Update mockT so placeholder keys are regex-escaped before
constructing the interpolation pattern, and replace matches via a callback that
returns obj[key] literally. Preserve the existing global whitespace-tolerant
placeholder matching and default-object behavior.

In `@lib/core/localStore.js`:
- Around line 22-26: Update the mockData backing store used by mockStore to be
prototype-free via Object.create(null), and change getItem to check only own
properties rather than using the in operator. Preserve the existing null return
for missing keys and current setItem/removeItem behavior.

In `@lib/drivers/abbott/freeStyleLibreData.js`:
- Line 390: Update the zero-compressed block handling in the decompression logic
to append blockLength actual zero values instead of undefined entries. Preserve
the existing decompressedBuffer.concat flow and ensure the resulting values
represent zero bytes.

In `@README.md`:
- Line 43: Correct the misspelled word “distrubutions” in the Linux setup
guidance to “distributions,” leaving the surrounding README text unchanged.

In `@test/app/actions/async.test.js`:
- Around line 77-79: Update the teardown that currently restores
appState.services to also restore appState.versionInfo to its default captured
value, ensuring each test starts with clean version metadata.

---

Outside diff comments:
In `@Dockerfile.dev`:
- Around line 22-23: Update the Node download and extraction command to fetch
node-$NODE_VERSION-linux-x64.tar.xz using curl -fsSLO, then extract that archive
with tar -xJf into /usr/local/bin instead of using the .tar.gz format.

In `@test/app/actions/sync.test.js`:
- Around line 698-719: Move restoration of uploadDataPeriod.periodMedtronic600
out of the inline assertion flow and into guaranteed cleanup for the affected
tests. In test/app/actions/sync.test.js ranges 698-719, 788-813, and 866-896,
preserve each original period value and restore it via afterEach or finally so
cleanup runs even when assertions fail.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: bbce6f4a-adc7-44ff-9326-4406e8cd6a22

📥 Commits

Reviewing files that changed from the base of the PR and between 8f43dd0 and e2b233b.

⛔ Files ignored due to path filters (1)
  • yarn.lock is excluded by !**/yarn.lock, !**/*.lock
📒 Files selected for processing (78)
  • .circleci/config.yml
  • .config.js
  • .eslintignore
  • .eslintrc
  • .nvmrc
  • .oxlintrc.json
  • Dockerfile
  • Dockerfile.dev
  • README.md
  • app/actions/appState.js
  • app/actions/async.js
  • app/actions/sync.js
  • app/actions/utils.js
  • app/auth.js
  • app/components/AdHocModal.js
  • app/components/BluetoothModal.js
  • app/components/ClinicUserSelect.js
  • app/components/DeviceSelection.js
  • app/components/DeviceTimeModal.js
  • app/components/Header.js
  • app/components/UpdateModal.js
  • app/components/Upload.js
  • app/components/UploadList.js
  • app/containers/App.js
  • app/containers/MainPage.js
  • app/containers/SettingsPage.js
  • app/containers/Top.js
  • app/containers/WorkspacePage.js
  • app/main.dev.js
  • app/package.json
  • app/utils/config.i18next.cjs
  • babel.config.js
  • docs/checklists/README.md
  • docs/checklisttemplates/CGMChecklist.md
  • docs/state/StateTreeGlossary.md
  • jest.setup.js
  • lib/TimezoneOffsetUtil.js
  • lib/commonFunctions.js
  • lib/core/api.js
  • lib/core/device.js
  • lib/core/localStore.js
  • lib/crc.js
  • lib/driverManager.js
  • lib/drivers/abbott/abbottFreeStyleLite.js
  • lib/drivers/abbott/abbottPrecisionXtra.js
  • lib/drivers/abbott/freeStyleLibreData.js
  • lib/drivers/allmedicus/agm4000.js
  • lib/drivers/bayer/bayerContourNext.js
  • lib/drivers/bluetoothLE/bluetoothLEDriver.js
  • lib/drivers/glucorx/glucoRxDriver.js
  • lib/drivers/i-sens/glucocardExpression.js
  • lib/drivers/medtronic/cli/blob_loader.js
  • lib/drivers/medtronic/medtronicDriver.js
  • lib/drivers/medtronic/processData.js
  • lib/drivers/medtronic600/medtronic600Driver.js
  • lib/drivers/onetouch/oneTouchUltra2.js
  • lib/drivers/onetouch/oneTouchUltraMini.js
  • lib/drivers/onetouch/oneTouchVerioBLE.js
  • lib/drivers/onetouch/oneTouchVerioIQ.js
  • lib/drivers/roche/accuChekUSB.js
  • lib/serialDevice.js
  • package.json
  • scripts/json-compare.js
  • scripts/vt-submit.js
  • scripts/whitelisting/av-submit.js
  • test/app/actions/async.test.js
  • test/app/actions/sync.test.js
  • test/app/actions/utils.test.js
  • test/app/reducers/uploads.test.js
  • test/app/reducers/working.test.js
  • test/e2e.js
  • test/lib/medtronic/testMedtronicSimulator.js
  • test/lib/tandem/testTandemSimulator.js
  • test/lib/testCommonFunctions.js
  • test/lib/testObjectBuilder.js
  • webpack.config.base.mjs
  • webpack.config.renderer.dev.babel.mjs
  • webpack.config.web.dev.babel.mjs
💤 Files with no reviewable changes (6)
  • .eslintignore
  • .eslintrc
  • lib/core/api.js
  • .config.js
  • app/containers/Top.js
  • app/components/DeviceSelection.js

Comment thread app/actions/async.js Outdated
Comment thread babel.config.js Outdated
Comment thread jest.setup.js
Comment thread lib/core/localStore.js Outdated
Comment thread lib/drivers/abbott/freeStyleLibreData.js Outdated
Comment thread README.md Outdated
Comment thread test/app/actions/async.test.js Outdated

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
lib/core/localStore.js (1)

32-33: 🩺 Stability & Availability | 🟠 Major | ⚡ Quick win

Fall back when window.localStorage is unavailable.

This branch checks only whether window exists. If storage is missing or access raises because browser storage is blocked, ourStore becomes unusable instead of selecting mockStore, causing subsequent storage operations to fail.

Proposed fix
 if (env.electron_renderer || env.browser) {
-  ourStore = typeof window !== 'undefined' ? window.localStorage : mockStore;
+  try {
+    const browserStore = typeof window !== 'undefined' ? window.localStorage : null;
+    ourStore = browserStore ?? mockStore;
+  } catch {
+    ourStore = mockStore;
+  }
 }
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@lib/core/localStore.js` around lines 32 - 33, Update the store selection in
the electron_renderer/browser branch to use mockStore whenever
window.localStorage is unavailable or access to it throws, while retaining
localStorage when it can be accessed successfully. Ensure ourStore is always
assigned a usable storage implementation.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In `@lib/core/localStore.js`:
- Around line 32-33: Update the store selection in the electron_renderer/browser
branch to use mockStore whenever window.localStorage is unavailable or access to
it throws, while retaining localStorage when it can be accessed successfully.
Ensure ourStore is always assigned a usable storage implementation.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 89e1c3ff-c915-4144-b6c3-fb6cbab4f179

📥 Commits

Reviewing files that changed from the base of the PR and between e2b233b and 98887d5.

⛔ Files ignored due to path filters (1)
  • yarn.lock is excluded by !**/yarn.lock, !**/*.lock
📒 Files selected for processing (10)
  • Dockerfile.dev
  • README.md
  • app/actions/async.js
  • babel.config.js
  • jest.setup.js
  • lib/core/localStore.js
  • lib/drivers/abbott/freeStyleLibreData.js
  • package.json
  • test/app/actions/async.test.js
  • test/app/actions/sync.test.js
🚧 Files skipped from review as they are similar to previous changes (6)
  • lib/drivers/abbott/freeStyleLibreData.js
  • Dockerfile.dev
  • babel.config.js
  • package.json
  • app/actions/async.js
  • test/app/actions/async.test.js

@gniezen
gniezen requested a review from krystophv July 30, 2026 12:57
Comment thread test/app/actions/async.test.js Outdated
// restore in an afterEach rather than at the end of each test, so that a
// failing assertion can't skip the restore
appState.services = defaultServices;
appState.versionInfo = defaultVersionInfo;

@krystophv krystophv Aug 3, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think the versionInfo reassignment here is going to just assign an already modified defaultVersionInfo since it's assigned by reference on L54 and doAppInit will mutate it when it runs.

We probably need to create new objects at creation and use them in this afterEach:

// line 53-54
const defaultServices = { ...appState.services };
const defaultVersionInfo = { ...appState.versionInfo };

afterEach(() => {
  appState.services = { ...defaultServices };
  appState.versionInfo = { ...defaultVersionInfo };
});

krystophv
krystophv previously approved these changes Aug 4, 2026

@krystophv krystophv left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM 🚀

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