Skip to content

Replace all the occurrences of the deprecated toThrowError API with the appropriate toThrow one#14442

Open
dario-piotrowicz wants to merge 1 commit into
mainfrom
dario/no-deprecated-toThrowError
Open

Replace all the occurrences of the deprecated toThrowError API with the appropriate toThrow one#14442
dario-piotrowicz wants to merge 1 commit into
mainfrom
dario/no-deprecated-toThrowError

Conversation

@dario-piotrowicz

@dario-piotrowicz dario-piotrowicz commented Jun 26, 2026

Copy link
Copy Markdown
Member

Vitest's toThrowError is deprecated and simply toThrow should be used instead

Screenshot of vscode showing deprecation warning

This PR simply makes this change across the whole monorepo


vitest toThrow docs (mentioning the deprecated alias)


  • Tests
    • Tests included/updated
    • Automated tests not possible - manual testing has been completed as follows:
    • Additional testing not necessary because:
  • Public documentation
    • Cloudflare docs PR(s):
    • Documentation not necessary because: minor code refactoring

A picture of a cute animal (not mandatory, but encouraged)


Open in Devin Review

@changeset-bot

changeset-bot Bot commented Jun 26, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: c47bc27

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@github-project-automation github-project-automation Bot moved this to Untriaged in workers-sdk Jun 26, 2026
@workers-devprod workers-devprod requested review from a team and edmundhung and removed request for a team June 26, 2026 14:28
@workers-devprod

workers-devprod commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Codeowners approval required for this PR:

  • @cloudflare/cloudchamber
  • @cloudflare/d1
  • @cloudflare/deploy-config
  • ✅ @cloudflare/wrangler
Show detailed file reviewers
  • packages/containers-shared/tests/images.test.ts: [@cloudflare/cloudchamber]
  • packages/workers-shared/asset-worker/tests/kv.test.ts: [@cloudflare/deploy-config]
  • packages/workers-shared/router-worker/tests/index.test.ts: [@cloudflare/deploy-config]
  • packages/wrangler/src/tests/containers/instances.test.ts: [@cloudflare/cloudchamber]
  • packages/wrangler/src/tests/containers/list.test.ts: [@cloudflare/cloudchamber]
  • packages/wrangler/src/tests/d1/create.test.ts: [@cloudflare/d1]
  • packages/wrangler/src/tests/d1/execute.test.ts: [@cloudflare/d1]
  • packages/wrangler/src/tests/d1/export.test.ts: [@cloudflare/d1]
  • packages/wrangler/src/tests/d1/insights.test.ts: [@cloudflare/d1]
  • packages/wrangler/src/tests/d1/migrate.test.ts: [@cloudflare/d1]
  • packages/wrangler/src/tests/d1/timeTravel.test.ts: [@cloudflare/d1]

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Open in Devin Review

@pkg-pr-new

pkg-pr-new Bot commented Jun 26, 2026

Copy link
Copy Markdown
@cloudflare/autoconfig

npm i https://pkg.pr.new/@cloudflare/autoconfig@14442

create-cloudflare

npm i https://pkg.pr.new/create-cloudflare@14442

@cloudflare/deploy-helpers

npm i https://pkg.pr.new/@cloudflare/deploy-helpers@14442

@cloudflare/kv-asset-handler

npm i https://pkg.pr.new/@cloudflare/kv-asset-handler@14442

miniflare

npm i https://pkg.pr.new/miniflare@14442

@cloudflare/pages-shared

npm i https://pkg.pr.new/@cloudflare/pages-shared@14442

@cloudflare/unenv-preset

npm i https://pkg.pr.new/@cloudflare/unenv-preset@14442

@cloudflare/vite-plugin

npm i https://pkg.pr.new/@cloudflare/vite-plugin@14442

@cloudflare/vitest-pool-workers

npm i https://pkg.pr.new/@cloudflare/vitest-pool-workers@14442

@cloudflare/workers-auth

npm i https://pkg.pr.new/@cloudflare/workers-auth@14442

@cloudflare/workers-editor-shared

npm i https://pkg.pr.new/@cloudflare/workers-editor-shared@14442

@cloudflare/workers-utils

npm i https://pkg.pr.new/@cloudflare/workers-utils@14442

wrangler

npm i https://pkg.pr.new/wrangler@14442

commit: c47bc27

@dario-piotrowicz dario-piotrowicz added the ci:no-changeset-required Skip pull request checks for a valid changeset label Jun 26, 2026
@ask-bonk

ask-bonk Bot commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

@dario-piotrowicz Bonk workflow was cancelled.

View workflow run · To retry, trigger Bonk again.

@edmundhung edmundhung 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.

codeowners bypass

@workers-devprod workers-devprod left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Codeowners reviews satisfied

@github-project-automation github-project-automation Bot moved this from Untriaged to Approved in workers-sdk Jun 26, 2026
@edmundhung

Copy link
Copy Markdown
Member

The c3 CI error should be fixed once you rebase your branch against main (#14425)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci:no-changeset-required Skip pull request checks for a valid changeset

Projects

Status: Approved

Development

Successfully merging this pull request may close these issues.

3 participants