Merge pull request #33720 from backstage/rugvip/add-to-error-utility
errors: add `toError` utility and migrate usages
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
'@backstage/errors': minor
|
||||
---
|
||||
|
||||
A new `toError` utility function is now available for converting unknown values to `ErrorLike` objects. If the value is already error-like it is returned as-is, strings are used directly as the error message, and all other values are wrapped as `unknown error '<stringified>'`. Non-error causes passed to `CustomErrorBase` are now converted and stored using `toError` rather than discarded.
|
||||
@@ -0,0 +1,30 @@
|
||||
---
|
||||
'@backstage/backend-app-api': patch
|
||||
'@backstage/backend-defaults': patch
|
||||
'@backstage/cli': patch
|
||||
'@backstage/cli-common': patch
|
||||
'@backstage/cli-module-migrate': patch
|
||||
'@backstage/cli-module-new': patch
|
||||
'@backstage/cli-node': patch
|
||||
'@backstage/config-loader': patch
|
||||
'@backstage/core-components': patch
|
||||
'@backstage/repo-tools': patch
|
||||
'@backstage/plugin-auth': patch
|
||||
'@backstage/plugin-auth-backend': patch
|
||||
'@backstage/plugin-catalog': patch
|
||||
'@backstage/plugin-catalog-backend': patch
|
||||
'@backstage/plugin-catalog-backend-module-incremental-ingestion': patch
|
||||
'@backstage/plugin-catalog-import': patch
|
||||
'@backstage/plugin-catalog-react': patch
|
||||
'@backstage/plugin-catalog-unprocessed-entities': patch
|
||||
'@backstage/plugin-devtools-backend': patch
|
||||
'@backstage/plugin-mcp-actions-backend': patch
|
||||
'@backstage/plugin-notifications-backend-module-slack': patch
|
||||
'@backstage/plugin-scaffolder-backend': patch
|
||||
'@backstage/plugin-scaffolder-backend-module-github': patch
|
||||
'@backstage/plugin-search-backend-node': patch
|
||||
'@backstage/plugin-techdocs-backend': patch
|
||||
'@backstage/plugin-techdocs-node': patch
|
||||
---
|
||||
|
||||
Migrated from `assertError` to `toError` for error handling.
|
||||
Reference in New Issue
Block a user