Skip to content

Conversation

@lambdalisue
Copy link
Member

@lambdalisue lambdalisue commented Nov 13, 2025

📦 @types/sinon ^17.0.3 → ^21.0.0

Summary by CodeRabbit

  • Chores
    • Updated testing framework dependencies to latest compatible versions.

@coderabbitai
Copy link

coderabbitai bot commented Nov 13, 2025

Walkthrough

Updated Sinon type references in two test files: denops/@denops-private/cli_test.ts and denops/@denops-private/worker_test.ts — the deno-types/type-reference for Sinon was bumped from @types/sinon@^17.0.3 to @types/sinon@^21.0.0; no runtime or public API changes.

Changes

Cohort / File(s) Summary
Sinon type version update
denops/@denops-private/cli_test.ts, denops/@denops-private/worker_test.ts
Bumped Sinon type directive from @types/sinon@^17.0.3 to @types/sinon@^21.0.0 (type-definition import only; no logic changes)

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

  • Files are small, identical kind of edit; review can focus on ensuring no stray runtime imports were changed.

Possibly related PRs

  • #439 — Modifies the same test files to update Sinon type/version references.
  • #411 — Also updates the deno-types Sinon type directive in test files; closely related.

Suggested reviewers

  • Milly

Poem

🐰 I hopped through code, a tiny quest,

Types refreshed, the tests dressed best.
Sinon climbed to twenty-one, hooray —
Soft paws tidy types away. ✨

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: bumping the @types/sinon dependency version from ^17.0.3 to ^21.0.0, which is the sole purpose of this pull request.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch automation/update-dependencies

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 74deba3 and f064656.

📒 Files selected for processing (2)
  • denops/@denops-private/cli_test.ts (1 hunks)
  • denops/@denops-private/worker_test.ts (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • denops/@denops-private/worker_test.ts
🧰 Additional context used
🧠 Learnings (1)
📚 Learning: 2024-09-14T17:09:30.174Z
Learnt from: Milly
Repo: vim-denops/denops.vim PR: 418
File: tests/denops/runtime/functions/plugin/check_type_test.ts:6-6
Timestamp: 2024-09-14T17:09:30.174Z
Learning: In this project, import paths prefixed with `/denops-testdata/` are defined in `deno.jsonc` via an import map, and these import paths are valid.

Applied to files:

  • denops/@denops-private/cli_test.ts
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (6)
  • GitHub Check: test (macos-latest, 2.x, v9.1.1646, v0.11.3)
  • GitHub Check: test (ubuntu-latest, 2.x, v9.1.1646, v0.11.3)
  • GitHub Check: test (windows-latest, 2.x, v9.1.1646, v0.11.3)
  • GitHub Check: test (ubuntu-latest, 2.3.0, v9.1.1646, v0.11.3)
  • GitHub Check: test (macos-latest, 2.3.0, v9.1.1646, v0.11.3)
  • GitHub Check: test (windows-latest, 2.3.0, v9.1.1646, v0.11.3)

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 and usage tips.

@codecov
Copy link

codecov bot commented Nov 13, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.07%. Comparing base (5cfca39) to head (f064656).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #464   +/-   ##
=======================================
  Coverage   97.07%   97.07%           
=======================================
  Files          11       11           
  Lines         924      924           
  Branches      146      146           
=======================================
  Hits          897      897           
  Misses         24       24           
  Partials        3        3           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 5cfca39 and 74deba3.

📒 Files selected for processing (2)
  • denops/@denops-private/cli_test.ts (1 hunks)
  • denops/@denops-private/worker_test.ts (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (6)
  • GitHub Check: test (windows-latest, 2.3.0, v9.1.1646, v0.11.3)
  • GitHub Check: test (ubuntu-latest, 2.3.0, v9.1.1646, v0.11.3)
  • GitHub Check: test (ubuntu-latest, 2.x, v9.1.1646, v0.11.3)
  • GitHub Check: test (macos-latest, 2.x, v9.1.1646, v0.11.3)
  • GitHub Check: test (macos-latest, 2.3.0, v9.1.1646, v0.11.3)
  • GitHub Check: test (windows-latest, 2.x, v9.1.1646, v0.11.3)
🔇 Additional comments (1)
denops/@denops-private/worker_test.ts (1)

1-1: Remove the non-existent @types/sinon@^20.0.0 reference.

The latest available version of @types/sinon is 17.0.4, not @types/sinon@^20.0.0. The deno-types directive in both worker_test.ts and cli_test.ts references a non-existent npm package version. Since the root configuration already specifies sinon@^21.0.0 as the runtime, you should either:

  1. Update the deno-types directive to use the actual latest version: // @deno-types="npm:@types/sinon@^17.0.4"
  2. Or remove the directive if Sinon v21 provides built-in type definitions

The version mismatch will cause type resolution failures at runtime.

Likely an incorrect or invalid review comment.

@@ -1,5 +1,5 @@
// NOTE: Use sinon to stub the getter property.
// @deno-types="npm:@types/sinon@^17.0.3"
// @deno-types="npm:@types/sinon@^20.0.0"
Copy link

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

LGTM! Verify compatibility with the major version bump.

The type definition update is consistent with the PR objective and aligns with the change in worker_test.ts. However, this is a major version bump (^17.0.3 → ^20.0.0), which may include breaking changes in type definitions.

Run the following script to verify the tests pass and check if dependency configuration files need updating:


🏁 Script executed:

#!/bin/bash
# Description: Run the CLI tests and check for dependency configuration

# Execute the test file
deno test denops/@denops-private/cli_test.ts

echo "---"
echo "Checking for dependency configuration files:"

# Check if deno.json or deno.jsonc exists and contains sinon references
if fd -t f '^deno\.jsonc?$' --max-depth 2 --exec cat {}; then
  echo "Found deno.json/deno.jsonc"
fi

# Check for import_map.json
if fd -t f '^import_map\.json$' --max-depth 2 --exec cat {}; then
  echo "Found import_map.json"
fi

Length of output: 1589


Let me search for the other test file and verify the version compatibility:


🏁 Script executed:

#!/bin/bash
# Verify type annotation versions in both test files and check for mismatches

# Look for both cli_test.ts and worker_test.ts
echo "=== Searching for test files with @deno-types annotation ==="
rg -n '@deno-types' denops/ tests/ --type typescript

echo ""
echo "=== Checking cli_test.ts content ==="
fd -t f 'cli_test\.ts$' --exec cat {}

echo ""
echo "=== Checking worker_test.ts content (first 50 lines) ==="
fd -t f 'worker_test\.ts$' --exec head -50 {}

Length of output: 20304


Critical version incompatibility detected—@types/sinon version does not exist.

The review comment approves the type definition update to @types/sinon@^20.0.0, but this version does not appear to exist in the npm registry. The latest version of @types/sinon is 17.0.4, and there are no published versions 20 or 21.

Additionally, there is a version mismatch between:

  • deno.json: "sinon": "npm:sinon@^21.0.0"
  • cli_test.ts & worker_test.ts: @types/sinon@^20.0.0

This type definition update will fail at runtime. The correct version should align with the sinon package version in deno.json or use an actually-published version like @types/sinon@^17.0.0.

🤖 Prompt for AI Agents
In denops/@denops-private/cli_test.ts around line 2, the @deno-types annotation
references a non-existent @types/sinon@^20.0.0 which will fail at runtime;
update the @deno-types to a published version that matches the sinon entry in
deno.json (either change this line and the same one in worker_test.ts to
@types/sinon@^17.0.0 or alternatively update deno.json to use a sinon version
that has matching @types available) and ensure both test files and deno.json use
the same compatible sinon/@types version.

@lambdalisue lambdalisue changed the title chore: bump @types/sinon from ^17.0.3 to ^20.0.0 chore: bump @types/sinon from ^17.0.3 to ^21.0.0 Nov 18, 2025
@lambdalisue lambdalisue force-pushed the automation/update-dependencies branch from 74deba3 to f064656 Compare November 18, 2025 00:44
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