@checkstack/dependency-backend 0.2.1 → 0.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,58 @@
1
1
  # @checkstack/dependency-backend
2
2
 
3
+ ## 0.2.3
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [26d8bae]
8
+ - Updated dependencies [26d8bae]
9
+ - @checkstack/healthcheck-common@0.11.0
10
+ - @checkstack/healthcheck-backend@0.13.0
11
+ - @checkstack/backend-api@0.12.0
12
+ - @checkstack/catalog-backend@0.2.24
13
+
14
+ ## 0.2.2
15
+
16
+ ### Patch Changes
17
+
18
+ - d1a2796: Enforce stricter code quality standards and eliminate AI slop anti-patterns.
19
+
20
+ **New utility**
21
+
22
+ - `extractErrorMessage(error, fallback?)` in `@checkstack/common` for consistent error extraction
23
+
24
+ **ESLint rules**
25
+
26
+ - `react-hooks/rules-of-hooks` and `exhaustive-deps` for hook correctness
27
+ - `no-console` in frontend packages — forces `toast` over silent `console.error`
28
+ - `no-restricted-syntax` banning `instanceof Error` — forces `extractErrorMessage`
29
+ - Custom `no-eslint-disable-any` rule preventing `@typescript-eslint/no-explicit-any` circumvention
30
+
31
+ **Refactoring**
32
+
33
+ - Replace 141 `instanceof Error` boilerplate patterns across the codebase
34
+ - Replace swallowed `console.error` with user-visible `toast.error()` feedback
35
+ - Remove 15 redundant `as` type casts in IntegrationsPage and ProviderConnectionsPage
36
+ - Consolidate 3 identical callback handlers into `handleDialogClose`
37
+ - Fix conditional React hook call in `FormField.tsx`
38
+ - Fix unstable useMemo deps in `Dashboard.tsx`
39
+ - Replace `useEffect`→`setState` with derived `useMemo` in `RegisterPage.tsx`
40
+ - Rewrite `keystore.test.ts` with typed `DrizzleMockChain` (eliminating 7 `any` suppressions)
41
+ - Delete obvious comments in `encryption.ts` and Teams `provider.ts`
42
+
43
+ - Updated dependencies [d1a2796]
44
+ - Updated dependencies [3c34b07]
45
+ - @checkstack/common@0.6.5
46
+ - @checkstack/backend-api@0.11.1
47
+ - @checkstack/catalog-backend@0.2.23
48
+ - @checkstack/healthcheck-backend@0.12.1
49
+ - @checkstack/catalog-common@1.3.1
50
+ - @checkstack/healthcheck-common@0.10.1
51
+ - @checkstack/dependency-common@0.2.1
52
+ - @checkstack/incident-common@0.4.7
53
+ - @checkstack/maintenance-common@0.4.9
54
+ - @checkstack/signal-common@0.1.9
55
+
3
56
  ## 0.2.1
4
57
 
5
58
  ### Patch Changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@checkstack/dependency-backend",
3
- "version": "0.2.1",
3
+ "version": "0.2.3",
4
4
  "type": "module",
5
5
  "main": "src/index.ts",
6
6
  "checkstack": {
@@ -13,16 +13,16 @@
13
13
  "lint:code": "eslint . --max-warnings 0"
14
14
  },
15
15
  "dependencies": {
16
- "@checkstack/backend-api": "0.10.0",
17
- "@checkstack/dependency-common": "0.1.0",
18
- "@checkstack/catalog-common": "1.2.11",
19
- "@checkstack/catalog-backend": "0.2.20",
20
- "@checkstack/healthcheck-common": "0.8.4",
21
- "@checkstack/healthcheck-backend": "0.10.7",
22
- "@checkstack/maintenance-common": "0.4.8",
23
- "@checkstack/incident-common": "0.4.6",
24
- "@checkstack/signal-common": "0.1.8",
25
- "@checkstack/common": "0.6.4",
16
+ "@checkstack/backend-api": "0.11.1",
17
+ "@checkstack/dependency-common": "0.2.1",
18
+ "@checkstack/catalog-common": "1.3.1",
19
+ "@checkstack/catalog-backend": "0.2.23",
20
+ "@checkstack/healthcheck-common": "0.10.1",
21
+ "@checkstack/healthcheck-backend": "0.12.1",
22
+ "@checkstack/maintenance-common": "0.4.9",
23
+ "@checkstack/incident-common": "0.4.7",
24
+ "@checkstack/signal-common": "0.1.9",
25
+ "@checkstack/common": "0.6.5",
26
26
  "drizzle-orm": "^0.45.0",
27
27
  "zod": "^4.2.1",
28
28
  "@orpc/server": "^1.13.2"
@@ -30,8 +30,8 @@
30
30
  "devDependencies": {
31
31
  "@checkstack/drizzle-helper": "0.0.4",
32
32
  "@checkstack/scripts": "0.1.2",
33
- "@checkstack/test-utils-backend": "0.1.15",
34
- "@checkstack/tsconfig": "0.0.4",
33
+ "@checkstack/test-utils-backend": "0.1.18",
34
+ "@checkstack/tsconfig": "0.0.5",
35
35
  "@types/bun": "^1.0.0",
36
36
  "typescript": "^5.0.0"
37
37
  }
package/src/router.ts CHANGED
@@ -17,6 +17,7 @@ import type {
17
17
  } from "./services/warning-evaluation-service";
18
18
  import { dependencyHooks } from "./hooks";
19
19
  import type { InferClient } from "@checkstack/common";
20
+ import { extractErrorMessage } from "@checkstack/common";
20
21
  import { CatalogApi } from "@checkstack/catalog-common";
21
22
  import { HealthCheckApi } from "@checkstack/healthcheck-common";
22
23
 
@@ -205,12 +206,12 @@ export function createRouter({
205
206
 
206
207
  return result;
207
208
  } catch (error) {
209
+ const message = extractErrorMessage(error);
208
210
  if (
209
- error instanceof Error &&
210
- (error.message.includes("circular chain") ||
211
- error.message.includes("already exists"))
211
+ message.includes("circular chain") ||
212
+ message.includes("already exists")
212
213
  ) {
213
- throw new ORPCError("BAD_REQUEST", { message: error.message });
214
+ throw new ORPCError("BAD_REQUEST", { message });
214
215
  }
215
216
  throw error;
216
217
  }