veryfront 0.1.635 → 0.1.637

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.
Files changed (88) hide show
  1. package/esm/cli/commands/serve/command.d.ts.map +1 -1
  2. package/esm/cli/commands/serve/command.js +2 -1
  3. package/esm/deno.js +1 -1
  4. package/esm/src/cache/distributed-cache-init.d.ts +11 -2
  5. package/esm/src/cache/distributed-cache-init.d.ts.map +1 -1
  6. package/esm/src/cache/distributed-cache-init.js +2 -14
  7. package/esm/src/channels/control-plane.d.ts +5 -5
  8. package/esm/src/embedding/chunk.js +4 -2
  9. package/esm/src/errors/error-registry/agent.d.ts +16 -0
  10. package/esm/src/errors/error-registry/agent.d.ts.map +1 -0
  11. package/esm/src/errors/error-registry/agent.js +52 -0
  12. package/esm/src/errors/error-registry/boundary.d.ts +16 -0
  13. package/esm/src/errors/error-registry/boundary.d.ts.map +1 -0
  14. package/esm/src/errors/error-registry/boundary.js +52 -0
  15. package/esm/src/errors/error-registry/build.d.ts +20 -0
  16. package/esm/src/errors/error-registry/build.d.ts.map +1 -0
  17. package/esm/src/errors/error-registry/build.js +68 -0
  18. package/esm/src/errors/error-registry/config.d.ts +22 -0
  19. package/esm/src/errors/error-registry/config.d.ts.map +1 -0
  20. package/esm/src/errors/error-registry/config.js +70 -0
  21. package/esm/src/errors/error-registry/deploy.d.ts +12 -0
  22. package/esm/src/errors/error-registry/deploy.d.ts.map +1 -0
  23. package/esm/src/errors/error-registry/deploy.js +36 -0
  24. package/esm/src/errors/error-registry/dev.d.ts +14 -0
  25. package/esm/src/errors/error-registry/dev.d.ts.map +1 -0
  26. package/esm/src/errors/error-registry/dev.js +44 -0
  27. package/esm/src/errors/error-registry/general.d.ts +29 -0
  28. package/esm/src/errors/error-registry/general.d.ts.map +1 -0
  29. package/esm/src/errors/error-registry/general.js +92 -0
  30. package/esm/src/errors/error-registry/module.d.ts +16 -0
  31. package/esm/src/errors/error-registry/module.d.ts.map +1 -0
  32. package/esm/src/errors/error-registry/module.js +52 -0
  33. package/esm/src/errors/error-registry/route.d.ts +16 -0
  34. package/esm/src/errors/error-registry/route.d.ts.map +1 -0
  35. package/esm/src/errors/error-registry/route.js +52 -0
  36. package/esm/src/errors/error-registry/runtime.d.ts +18 -0
  37. package/esm/src/errors/error-registry/runtime.d.ts.map +1 -0
  38. package/esm/src/errors/error-registry/runtime.js +60 -0
  39. package/esm/src/errors/error-registry/server.d.ts +39 -0
  40. package/esm/src/errors/error-registry/server.d.ts.map +1 -0
  41. package/esm/src/errors/error-registry/server.js +129 -0
  42. package/esm/src/errors/error-registry.d.ts +79 -157
  43. package/esm/src/errors/error-registry.d.ts.map +1 -1
  44. package/esm/src/errors/error-registry.js +37 -706
  45. package/esm/src/errors/logging.d.ts.map +1 -1
  46. package/esm/src/errors/logging.js +7 -3
  47. package/esm/src/integrations/schema.d.ts +4 -4
  48. package/esm/src/internal-agents/control-plane-auth.d.ts +1 -1
  49. package/esm/src/internal-agents/run-stream.d.ts.map +1 -1
  50. package/esm/src/internal-agents/run-stream.js +15 -1
  51. package/esm/src/oauth/index.d.ts +1 -0
  52. package/esm/src/oauth/index.d.ts.map +1 -1
  53. package/esm/src/oauth/token-store/index.d.ts +1 -0
  54. package/esm/src/oauth/token-store/index.d.ts.map +1 -1
  55. package/esm/src/oauth/token-store/memory.d.ts +26 -4
  56. package/esm/src/oauth/token-store/memory.d.ts.map +1 -1
  57. package/esm/src/oauth/token-store/memory.js +42 -5
  58. package/esm/src/observability/log-buffer.d.ts.map +1 -1
  59. package/esm/src/observability/log-buffer.js +7 -1
  60. package/esm/src/platform/adapters/redis/modules.d.ts.map +1 -1
  61. package/esm/src/platform/adapters/redis/modules.js +3 -10
  62. package/esm/src/security/sandbox/project-worker.d.ts.map +1 -1
  63. package/esm/src/security/sandbox/project-worker.js +0 -1
  64. package/esm/src/server/dev-server/server.d.ts.map +1 -1
  65. package/esm/src/server/dev-server/server.js +2 -1
  66. package/esm/src/server/distributed-cache-initializers.d.ts +13 -0
  67. package/esm/src/server/distributed-cache-initializers.d.ts.map +1 -0
  68. package/esm/src/server/distributed-cache-initializers.js +22 -0
  69. package/esm/src/server/handlers/request/agent-stream.handler.d.ts.map +1 -1
  70. package/esm/src/server/handlers/request/agent-stream.handler.js +56 -16
  71. package/esm/src/server/index.d.ts +1 -0
  72. package/esm/src/server/index.d.ts.map +1 -1
  73. package/esm/src/server/index.js +1 -0
  74. package/esm/src/server/production-server.d.ts.map +1 -1
  75. package/esm/src/server/production-server.js +2 -1
  76. package/esm/src/server/services/rsc/endpoints/rsc-bundles.generated.d.ts.map +1 -1
  77. package/esm/src/server/services/rsc/endpoints/rsc-bundles.generated.js +2 -2
  78. package/esm/src/utils/logger/logger.d.ts.map +1 -1
  79. package/esm/src/utils/logger/logger.js +15 -5
  80. package/esm/src/utils/logger/redact.d.ts +64 -0
  81. package/esm/src/utils/logger/redact.d.ts.map +1 -0
  82. package/esm/src/utils/logger/redact.js +235 -0
  83. package/esm/src/utils/redis-client.d.ts.map +1 -1
  84. package/esm/src/utils/redis-client.js +0 -3
  85. package/esm/src/utils/version-constant.d.ts +1 -1
  86. package/esm/src/utils/version-constant.js +1 -1
  87. package/esm/src/workflow/schemas/workflow.schema.d.ts +4 -4
  88. package/package.json +2 -1
@@ -0,0 +1,29 @@
1
+ export declare const UNKNOWN_ERROR: import("../types.js").RegisteredError;
2
+ export declare const PERMISSION_DENIED: import("../types.js").RegisteredError;
3
+ export declare const FILE_NOT_FOUND: import("../types.js").RegisteredError;
4
+ export declare const RESOURCE_NOT_FOUND: import("../types.js").RegisteredError;
5
+ export declare const INVALID_ARGUMENT: import("../types.js").RegisteredError;
6
+ export declare const TIMEOUT_ERROR: import("../types.js").RegisteredError;
7
+ export declare const INITIALIZATION_ERROR: import("../types.js").RegisteredError;
8
+ export declare const NOT_SUPPORTED: import("../types.js").RegisteredError;
9
+ /** Path traversal / secure-fs violations (replaces SecurityError) */
10
+ export declare const SECURITY_VIOLATION: import("../types.js").RegisteredError;
11
+ /** HTTP request input validation failures (replaces ValidationError) */
12
+ export declare const INPUT_VALIDATION_FAILED: import("../types.js").RegisteredError;
13
+ /**
14
+ * All registered errors for lookup by slug
15
+ */
16
+ /** Registry fragment for GENERAL errors (slug → definition). */
17
+ export declare const GENERAL_REGISTRY: {
18
+ readonly "unknown-error": import("../types.js").RegisteredError;
19
+ readonly "permission-denied": import("../types.js").RegisteredError;
20
+ readonly "file-not-found": import("../types.js").RegisteredError;
21
+ readonly "resource-not-found": import("../types.js").RegisteredError;
22
+ readonly "invalid-argument": import("../types.js").RegisteredError;
23
+ readonly "timeout-error": import("../types.js").RegisteredError;
24
+ readonly "initialization-error": import("../types.js").RegisteredError;
25
+ readonly "not-supported": import("../types.js").RegisteredError;
26
+ readonly "security-violation": import("../types.js").RegisteredError;
27
+ readonly "input-validation-failed": import("../types.js").RegisteredError;
28
+ };
29
+ //# sourceMappingURL=general.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"general.d.ts","sourceRoot":"","sources":["../../../../src/src/errors/error-registry/general.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,aAAa,uCAMxB,CAAC;AAEH,eAAO,MAAM,iBAAiB,uCAM5B,CAAC;AAEH,eAAO,MAAM,cAAc,uCAMzB,CAAC;AAEH,eAAO,MAAM,kBAAkB,uCAM7B,CAAC;AAEH,eAAO,MAAM,gBAAgB,uCAM3B,CAAC;AAEH,eAAO,MAAM,aAAa,uCAMxB,CAAC;AAEH,eAAO,MAAM,oBAAoB,uCAM/B,CAAC;AAEH,eAAO,MAAM,aAAa,uCAMxB,CAAC;AAEH,qEAAqE;AACrE,eAAO,MAAM,kBAAkB,uCAM7B,CAAC;AAEH,wEAAwE;AACxE,eAAO,MAAM,uBAAuB,uCAMlC,CAAC;AAMH;;GAEG;AAEH,gEAAgE;AAChE,eAAO,MAAM,gBAAgB;;;;;;;;;;;CAWnB,CAAC"}
@@ -0,0 +1,92 @@
1
+ import { defineError } from "../types.js";
2
+ export const UNKNOWN_ERROR = defineError({
3
+ slug: "unknown-error",
4
+ category: "GENERAL",
5
+ status: 500,
6
+ title: "Unknown/unclassified error",
7
+ suggestion: "Check logs for more details",
8
+ });
9
+ export const PERMISSION_DENIED = defineError({
10
+ slug: "permission-denied",
11
+ category: "GENERAL",
12
+ status: 403,
13
+ title: "File/resource permission denied",
14
+ suggestion: "Check file permissions and access rights",
15
+ });
16
+ export const FILE_NOT_FOUND = defineError({
17
+ slug: "file-not-found",
18
+ category: "GENERAL",
19
+ status: 404,
20
+ title: "File not found",
21
+ suggestion: "Verify the file path exists",
22
+ });
23
+ export const RESOURCE_NOT_FOUND = defineError({
24
+ slug: "resource-not-found",
25
+ category: "GENERAL",
26
+ status: 404,
27
+ title: "Requested resource not found",
28
+ suggestion: "Verify the referenced resource ID or name exists",
29
+ });
30
+ export const INVALID_ARGUMENT = defineError({
31
+ slug: "invalid-argument",
32
+ category: "GENERAL",
33
+ status: 400,
34
+ title: "Invalid function argument",
35
+ suggestion: "Check argument types and values",
36
+ });
37
+ export const TIMEOUT_ERROR = defineError({
38
+ slug: "timeout-error",
39
+ category: "GENERAL",
40
+ status: 408,
41
+ title: "Operation timed out",
42
+ suggestion: "Increase timeout or optimize the operation",
43
+ });
44
+ export const INITIALIZATION_ERROR = defineError({
45
+ slug: "initialization-error",
46
+ category: "GENERAL",
47
+ status: 500,
48
+ title: "Initialization failed",
49
+ suggestion: "Check initialization requirements and dependencies",
50
+ });
51
+ export const NOT_SUPPORTED = defineError({
52
+ slug: "not-supported",
53
+ category: "GENERAL",
54
+ status: 501,
55
+ title: "Feature not supported",
56
+ suggestion: "Check documentation for supported features",
57
+ });
58
+ /** Path traversal / secure-fs violations (replaces SecurityError) */
59
+ export const SECURITY_VIOLATION = defineError({
60
+ slug: "security-violation",
61
+ category: "GENERAL",
62
+ status: 403,
63
+ title: "Security violation detected",
64
+ suggestion: "Check for path traversal or unauthorized access attempts",
65
+ });
66
+ /** HTTP request input validation failures (replaces ValidationError) */
67
+ export const INPUT_VALIDATION_FAILED = defineError({
68
+ slug: "input-validation-failed",
69
+ category: "GENERAL",
70
+ status: 400,
71
+ title: "Input validation failed",
72
+ suggestion: "Check request input against validation rules",
73
+ });
74
+ // =============================================================================
75
+ // Registry exports
76
+ // =============================================================================
77
+ /**
78
+ * All registered errors for lookup by slug
79
+ */
80
+ /** Registry fragment for GENERAL errors (slug → definition). */
81
+ export const GENERAL_REGISTRY = {
82
+ "unknown-error": UNKNOWN_ERROR,
83
+ "permission-denied": PERMISSION_DENIED,
84
+ "file-not-found": FILE_NOT_FOUND,
85
+ "resource-not-found": RESOURCE_NOT_FOUND,
86
+ "invalid-argument": INVALID_ARGUMENT,
87
+ "timeout-error": TIMEOUT_ERROR,
88
+ "initialization-error": INITIALIZATION_ERROR,
89
+ "not-supported": NOT_SUPPORTED,
90
+ "security-violation": SECURITY_VIOLATION,
91
+ "input-validation-failed": INPUT_VALIDATION_FAILED,
92
+ };
@@ -0,0 +1,16 @@
1
+ export declare const MODULE_NOT_FOUND: import("../types.js").RegisteredError;
2
+ export declare const IMPORT_RESOLUTION_ERROR: import("../types.js").RegisteredError;
3
+ export declare const CIRCULAR_DEPENDENCY: import("../types.js").RegisteredError;
4
+ export declare const INVALID_IMPORT: import("../types.js").RegisteredError;
5
+ export declare const DEPENDENCY_MISSING: import("../types.js").RegisteredError;
6
+ export declare const VERSION_MISMATCH: import("../types.js").RegisteredError;
7
+ /** Registry fragment for MODULE errors (slug → definition). */
8
+ export declare const MODULE_REGISTRY: {
9
+ readonly "module-not-found": import("../types.js").RegisteredError;
10
+ readonly "import-resolution-error": import("../types.js").RegisteredError;
11
+ readonly "circular-dependency": import("../types.js").RegisteredError;
12
+ readonly "invalid-import": import("../types.js").RegisteredError;
13
+ readonly "dependency-missing": import("../types.js").RegisteredError;
14
+ readonly "version-mismatch": import("../types.js").RegisteredError;
15
+ };
16
+ //# sourceMappingURL=module.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"module.d.ts","sourceRoot":"","sources":["../../../../src/src/errors/error-registry/module.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,gBAAgB,uCAM3B,CAAC;AAEH,eAAO,MAAM,uBAAuB,uCAMlC,CAAC;AAEH,eAAO,MAAM,mBAAmB,uCAM9B,CAAC;AAEH,eAAO,MAAM,cAAc,uCAMzB,CAAC;AAEH,eAAO,MAAM,kBAAkB,uCAM7B,CAAC;AAEH,eAAO,MAAM,gBAAgB,uCAM3B,CAAC;AAEH,+DAA+D;AAC/D,eAAO,MAAM,eAAe;;;;;;;CAOlB,CAAC"}
@@ -0,0 +1,52 @@
1
+ import { defineError } from "../types.js";
2
+ export const MODULE_NOT_FOUND = defineError({
3
+ slug: "module-not-found",
4
+ category: "MODULE",
5
+ status: 404,
6
+ title: "Module could not be resolved",
7
+ suggestion: "Check the import path and ensure the module is installed",
8
+ });
9
+ export const IMPORT_RESOLUTION_ERROR = defineError({
10
+ slug: "import-resolution-error",
11
+ category: "MODULE",
12
+ status: 500,
13
+ title: "Import path resolution failed",
14
+ suggestion: "Verify import paths and module configuration",
15
+ });
16
+ export const CIRCULAR_DEPENDENCY = defineError({
17
+ slug: "circular-dependency",
18
+ category: "MODULE",
19
+ status: 500,
20
+ title: "Circular dependency detected",
21
+ suggestion: "Refactor imports to break the circular dependency",
22
+ });
23
+ export const INVALID_IMPORT = defineError({
24
+ slug: "invalid-import",
25
+ category: "MODULE",
26
+ status: 400,
27
+ title: "Invalid import statement",
28
+ suggestion: "Fix import syntax or path",
29
+ });
30
+ export const DEPENDENCY_MISSING = defineError({
31
+ slug: "dependency-missing",
32
+ category: "MODULE",
33
+ status: 404,
34
+ title: "Required dependency not installed",
35
+ suggestion: "Install the missing dependency with your package manager",
36
+ });
37
+ export const VERSION_MISMATCH = defineError({
38
+ slug: "version-mismatch",
39
+ category: "MODULE",
40
+ status: 409,
41
+ title: "Dependency version mismatch",
42
+ suggestion: "Update dependencies to compatible versions",
43
+ });
44
+ /** Registry fragment for MODULE errors (slug → definition). */
45
+ export const MODULE_REGISTRY = {
46
+ "module-not-found": MODULE_NOT_FOUND,
47
+ "import-resolution-error": IMPORT_RESOLUTION_ERROR,
48
+ "circular-dependency": CIRCULAR_DEPENDENCY,
49
+ "invalid-import": INVALID_IMPORT,
50
+ "dependency-missing": DEPENDENCY_MISSING,
51
+ "version-mismatch": VERSION_MISMATCH,
52
+ };
@@ -0,0 +1,16 @@
1
+ export declare const ROUTE_CONFLICT: import("../types.js").RegisteredError;
2
+ export declare const INVALID_ROUTE_FILE: import("../types.js").RegisteredError;
3
+ export declare const ROUTE_HANDLER_INVALID: import("../types.js").RegisteredError;
4
+ export declare const DYNAMIC_ROUTE_ERROR: import("../types.js").RegisteredError;
5
+ export declare const ROUTE_PARAMS_ERROR: import("../types.js").RegisteredError;
6
+ export declare const API_ROUTE_ERROR: import("../types.js").RegisteredError;
7
+ /** Registry fragment for ROUTE errors (slug → definition). */
8
+ export declare const ROUTE_REGISTRY: {
9
+ readonly "route-conflict": import("../types.js").RegisteredError;
10
+ readonly "invalid-route-file": import("../types.js").RegisteredError;
11
+ readonly "route-handler-invalid": import("../types.js").RegisteredError;
12
+ readonly "dynamic-route-error": import("../types.js").RegisteredError;
13
+ readonly "route-params-error": import("../types.js").RegisteredError;
14
+ readonly "api-route-error": import("../types.js").RegisteredError;
15
+ };
16
+ //# sourceMappingURL=route.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"route.d.ts","sourceRoot":"","sources":["../../../../src/src/errors/error-registry/route.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,cAAc,uCAMzB,CAAC;AAEH,eAAO,MAAM,kBAAkB,uCAM7B,CAAC;AAEH,eAAO,MAAM,qBAAqB,uCAMhC,CAAC;AAEH,eAAO,MAAM,mBAAmB,uCAM9B,CAAC;AAEH,eAAO,MAAM,kBAAkB,uCAM7B,CAAC;AAEH,eAAO,MAAM,eAAe,uCAM1B,CAAC;AAEH,8DAA8D;AAC9D,eAAO,MAAM,cAAc;;;;;;;CAOjB,CAAC"}
@@ -0,0 +1,52 @@
1
+ import { defineError } from "../types.js";
2
+ export const ROUTE_CONFLICT = defineError({
3
+ slug: "route-conflict",
4
+ category: "ROUTE",
5
+ status: 409,
6
+ title: "Conflicting route definitions",
7
+ suggestion: "Rename or reorganize conflicting route files",
8
+ });
9
+ export const INVALID_ROUTE_FILE = defineError({
10
+ slug: "invalid-route-file",
11
+ category: "ROUTE",
12
+ status: 400,
13
+ title: "Invalid route file structure",
14
+ suggestion: "Ensure route file exports required functions",
15
+ });
16
+ export const ROUTE_HANDLER_INVALID = defineError({
17
+ slug: "route-handler-invalid",
18
+ category: "ROUTE",
19
+ status: 400,
20
+ title: "Invalid route handler export",
21
+ suggestion: "Export a valid handler function from the route file",
22
+ });
23
+ export const DYNAMIC_ROUTE_ERROR = defineError({
24
+ slug: "dynamic-route-error",
25
+ category: "ROUTE",
26
+ status: 500,
27
+ title: "Dynamic route parsing failed",
28
+ suggestion: "Check dynamic route segment syntax",
29
+ });
30
+ export const ROUTE_PARAMS_ERROR = defineError({
31
+ slug: "route-params-error",
32
+ category: "ROUTE",
33
+ status: 400,
34
+ title: "Route parameters invalid",
35
+ suggestion: "Validate route parameter values",
36
+ });
37
+ export const API_ROUTE_ERROR = defineError({
38
+ slug: "api-route-error",
39
+ category: "ROUTE",
40
+ status: 500,
41
+ title: "API route definition error",
42
+ suggestion: "Review API route configuration",
43
+ });
44
+ /** Registry fragment for ROUTE errors (slug → definition). */
45
+ export const ROUTE_REGISTRY = {
46
+ "route-conflict": ROUTE_CONFLICT,
47
+ "invalid-route-file": INVALID_ROUTE_FILE,
48
+ "route-handler-invalid": ROUTE_HANDLER_INVALID,
49
+ "dynamic-route-error": DYNAMIC_ROUTE_ERROR,
50
+ "route-params-error": ROUTE_PARAMS_ERROR,
51
+ "api-route-error": API_ROUTE_ERROR,
52
+ };
@@ -0,0 +1,18 @@
1
+ export declare const HYDRATION_MISMATCH: import("../types.js").RegisteredError;
2
+ export declare const RENDER_ERROR: import("../types.js").RegisteredError;
3
+ export declare const COMPONENT_ERROR: import("../types.js").RegisteredError;
4
+ export declare const LAYOUT_NOT_FOUND: import("../types.js").RegisteredError;
5
+ export declare const PAGE_NOT_FOUND: import("../types.js").RegisteredError;
6
+ export declare const API_ERROR: import("../types.js").RegisteredError;
7
+ export declare const MIDDLEWARE_ERROR: import("../types.js").RegisteredError;
8
+ /** Registry fragment for RUNTIME errors (slug → definition). */
9
+ export declare const RUNTIME_REGISTRY: {
10
+ readonly "hydration-mismatch": import("../types.js").RegisteredError;
11
+ readonly "render-error": import("../types.js").RegisteredError;
12
+ readonly "component-error": import("../types.js").RegisteredError;
13
+ readonly "layout-not-found": import("../types.js").RegisteredError;
14
+ readonly "page-not-found": import("../types.js").RegisteredError;
15
+ readonly "api-error": import("../types.js").RegisteredError;
16
+ readonly "middleware-error": import("../types.js").RegisteredError;
17
+ };
18
+ //# sourceMappingURL=runtime.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"runtime.d.ts","sourceRoot":"","sources":["../../../../src/src/errors/error-registry/runtime.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,kBAAkB,uCAM7B,CAAC;AAEH,eAAO,MAAM,YAAY,uCAMvB,CAAC;AAEH,eAAO,MAAM,eAAe,uCAM1B,CAAC;AAEH,eAAO,MAAM,gBAAgB,uCAM3B,CAAC;AAEH,eAAO,MAAM,cAAc,uCAMzB,CAAC;AAEH,eAAO,MAAM,SAAS,uCAMpB,CAAC;AAEH,eAAO,MAAM,gBAAgB,uCAM3B,CAAC;AAEH,gEAAgE;AAChE,eAAO,MAAM,gBAAgB;;;;;;;;CAQnB,CAAC"}
@@ -0,0 +1,60 @@
1
+ import { defineError } from "../types.js";
2
+ export const HYDRATION_MISMATCH = defineError({
3
+ slug: "hydration-mismatch",
4
+ category: "RUNTIME",
5
+ status: 500,
6
+ title: "Client/server hydration mismatch",
7
+ suggestion: "Ensure server and client render the same content",
8
+ });
9
+ export const RENDER_ERROR = defineError({
10
+ slug: "render-error",
11
+ category: "RUNTIME",
12
+ status: 500,
13
+ title: "Component render failed",
14
+ suggestion: "Check component for runtime errors",
15
+ });
16
+ export const COMPONENT_ERROR = defineError({
17
+ slug: "component-error",
18
+ category: "RUNTIME",
19
+ status: 500,
20
+ title: "Component execution error",
21
+ suggestion: "Review component logic and props",
22
+ });
23
+ export const LAYOUT_NOT_FOUND = defineError({
24
+ slug: "layout-not-found",
25
+ category: "RUNTIME",
26
+ status: 404,
27
+ title: "Layout component not found",
28
+ suggestion: "Ensure layout file exists at the expected path",
29
+ });
30
+ export const PAGE_NOT_FOUND = defineError({
31
+ slug: "page-not-found",
32
+ category: "RUNTIME",
33
+ status: 404,
34
+ title: "Page component not found",
35
+ suggestion: "Check that the page file exists in the routes directory",
36
+ });
37
+ export const API_ERROR = defineError({
38
+ slug: "api-error",
39
+ category: "RUNTIME",
40
+ status: 500,
41
+ title: "API route handler error",
42
+ suggestion: "Review API route handler for errors",
43
+ });
44
+ export const MIDDLEWARE_ERROR = defineError({
45
+ slug: "middleware-error",
46
+ category: "RUNTIME",
47
+ status: 500,
48
+ title: "Middleware execution error",
49
+ suggestion: "Check middleware function for errors",
50
+ });
51
+ /** Registry fragment for RUNTIME errors (slug → definition). */
52
+ export const RUNTIME_REGISTRY = {
53
+ "hydration-mismatch": HYDRATION_MISMATCH,
54
+ "render-error": RENDER_ERROR,
55
+ "component-error": COMPONENT_ERROR,
56
+ "layout-not-found": LAYOUT_NOT_FOUND,
57
+ "page-not-found": PAGE_NOT_FOUND,
58
+ "api-error": API_ERROR,
59
+ "middleware-error": MIDDLEWARE_ERROR,
60
+ };
@@ -0,0 +1,39 @@
1
+ export declare const PORT_IN_USE: import("../types.js").RegisteredError;
2
+ export declare const SERVER_START_ERROR: import("../types.js").RegisteredError;
3
+ export declare const CACHE_ERROR: import("../types.js").RegisteredError;
4
+ export declare const FILE_WATCH_ERROR: import("../types.js").RegisteredError;
5
+ export declare const REQUEST_ERROR: import("../types.js").RegisteredError;
6
+ export declare const SERVICE_OVERLOADED: import("../types.js").RegisteredError;
7
+ export declare const SEMAPHORE_TIMEOUT: import("../types.js").RegisteredError;
8
+ export declare const CIRCUIT_BREAKER_OPEN: import("../types.js").RegisteredError;
9
+ export declare const CACHE_PATH_MISMATCH: import("../types.js").RegisteredError;
10
+ export declare const NETWORK_ERROR: import("../types.js").RegisteredError;
11
+ /** API client request/response errors (replaces VeryfrontAPIError) */
12
+ export declare const API_CLIENT_ERROR: import("../types.js").RegisteredError;
13
+ /** Token storage adapter failures (replaces TokenStorageError) */
14
+ export declare const TOKEN_STORAGE_ERROR: import("../types.js").RegisteredError;
15
+ /** Cache path invariant violations (replaces CacheInvariantError) */
16
+ export declare const CACHE_INVARIANT_VIOLATION: import("../types.js").RegisteredError;
17
+ /** Production domain resolved but no active release found */
18
+ export declare const RELEASE_NOT_FOUND: import("../types.js").RegisteredError;
19
+ /** Both primary and fallback operations failed (replaces FallbackExecutionError) */
20
+ export declare const FALLBACK_EXHAUSTED: import("../types.js").RegisteredError;
21
+ /** Registry fragment for SERVER errors (slug → definition). */
22
+ export declare const SERVER_REGISTRY: {
23
+ readonly "port-in-use": import("../types.js").RegisteredError;
24
+ readonly "server-start-error": import("../types.js").RegisteredError;
25
+ readonly "cache-error": import("../types.js").RegisteredError;
26
+ readonly "file-watch-error": import("../types.js").RegisteredError;
27
+ readonly "request-error": import("../types.js").RegisteredError;
28
+ readonly "service-overloaded": import("../types.js").RegisteredError;
29
+ readonly "semaphore-timeout": import("../types.js").RegisteredError;
30
+ readonly "circuit-breaker-open": import("../types.js").RegisteredError;
31
+ readonly "cache-path-mismatch": import("../types.js").RegisteredError;
32
+ readonly "network-error": import("../types.js").RegisteredError;
33
+ readonly "api-client-error": import("../types.js").RegisteredError;
34
+ readonly "token-storage-error": import("../types.js").RegisteredError;
35
+ readonly "cache-invariant-violation": import("../types.js").RegisteredError;
36
+ readonly "release-not-found": import("../types.js").RegisteredError;
37
+ readonly "fallback-exhausted": import("../types.js").RegisteredError;
38
+ };
39
+ //# sourceMappingURL=server.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../../../src/src/errors/error-registry/server.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,WAAW,uCAMtB,CAAC;AAEH,eAAO,MAAM,kBAAkB,uCAM7B,CAAC;AAEH,eAAO,MAAM,WAAW,uCAMtB,CAAC;AAEH,eAAO,MAAM,gBAAgB,uCAM3B,CAAC;AAEH,eAAO,MAAM,aAAa,uCAMxB,CAAC;AAEH,eAAO,MAAM,kBAAkB,uCAM7B,CAAC;AAEH,eAAO,MAAM,iBAAiB,uCAM5B,CAAC;AAEH,eAAO,MAAM,oBAAoB,uCAM/B,CAAC;AAEH,eAAO,MAAM,mBAAmB,uCAM9B,CAAC;AAEH,eAAO,MAAM,aAAa,uCAMxB,CAAC;AAEH,sEAAsE;AACtE,eAAO,MAAM,gBAAgB,uCAM3B,CAAC;AAEH,kEAAkE;AAClE,eAAO,MAAM,mBAAmB,uCAM9B,CAAC;AAEH,qEAAqE;AACrE,eAAO,MAAM,yBAAyB,uCAMpC,CAAC;AAEH,6DAA6D;AAC7D,eAAO,MAAM,iBAAiB,uCAM5B,CAAC;AAEH,oFAAoF;AACpF,eAAO,MAAM,kBAAkB,uCAM7B,CAAC;AAEH,+DAA+D;AAC/D,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;CAgBlB,CAAC"}
@@ -0,0 +1,129 @@
1
+ import { defineError } from "../types.js";
2
+ export const PORT_IN_USE = defineError({
3
+ slug: "port-in-use",
4
+ category: "SERVER",
5
+ status: 409,
6
+ title: "Server port already in use",
7
+ suggestion: "Use a different port or stop the process using this port",
8
+ });
9
+ export const SERVER_START_ERROR = defineError({
10
+ slug: "server-start-error",
11
+ category: "SERVER",
12
+ status: 500,
13
+ title: "Server failed to start",
14
+ suggestion: "Check server configuration and port availability",
15
+ });
16
+ export const CACHE_ERROR = defineError({
17
+ slug: "cache-error",
18
+ category: "SERVER",
19
+ status: 500,
20
+ title: "Cache operation failed",
21
+ suggestion: "Clear the cache and try again",
22
+ });
23
+ export const FILE_WATCH_ERROR = defineError({
24
+ slug: "file-watch-error",
25
+ category: "SERVER",
26
+ status: 500,
27
+ title: "File watcher error",
28
+ suggestion: "Restart the development server",
29
+ });
30
+ export const REQUEST_ERROR = defineError({
31
+ slug: "request-error",
32
+ category: "SERVER",
33
+ status: 500,
34
+ title: "HTTP request handling error",
35
+ suggestion: "Check request handler and middleware",
36
+ });
37
+ export const SERVICE_OVERLOADED = defineError({
38
+ slug: "service-overloaded",
39
+ category: "SERVER",
40
+ status: 503,
41
+ title: "Service overloaded",
42
+ suggestion: "Reduce load or scale up resources",
43
+ });
44
+ export const SEMAPHORE_TIMEOUT = defineError({
45
+ slug: "semaphore-timeout",
46
+ category: "SERVER",
47
+ status: 503,
48
+ title: "Semaphore acquire timeout",
49
+ suggestion: "Reduce concurrency or increase the semaphore acquire timeout",
50
+ });
51
+ export const CIRCUIT_BREAKER_OPEN = defineError({
52
+ slug: "circuit-breaker-open",
53
+ category: "SERVER",
54
+ status: 503,
55
+ title: "Circuit breaker is open",
56
+ suggestion: "Wait for the breaker reset timeout before retrying",
57
+ });
58
+ export const CACHE_PATH_MISMATCH = defineError({
59
+ slug: "cache-path-mismatch",
60
+ category: "SERVER",
61
+ status: 500,
62
+ title: "Cache path mismatch",
63
+ suggestion: "Clear the cache directory and rebuild",
64
+ });
65
+ export const NETWORK_ERROR = defineError({
66
+ slug: "network-error",
67
+ category: "SERVER",
68
+ status: 502,
69
+ title: "Network operation failed",
70
+ suggestion: "Check network connectivity and retry",
71
+ });
72
+ /** API client request/response errors (replaces VeryfrontAPIError) */
73
+ export const API_CLIENT_ERROR = defineError({
74
+ slug: "api-client-error",
75
+ category: "SERVER",
76
+ status: 500,
77
+ title: "API client request failed",
78
+ suggestion: "Check API connectivity and authentication",
79
+ });
80
+ /** Token storage adapter failures (replaces TokenStorageError) */
81
+ export const TOKEN_STORAGE_ERROR = defineError({
82
+ slug: "token-storage-error",
83
+ category: "SERVER",
84
+ status: 500,
85
+ title: "Token storage operation failed",
86
+ suggestion: "Check token storage backend and credentials",
87
+ });
88
+ /** Cache path invariant violations (replaces CacheInvariantError) */
89
+ export const CACHE_INVARIANT_VIOLATION = defineError({
90
+ slug: "cache-invariant-violation",
91
+ category: "SERVER",
92
+ status: 500,
93
+ title: "Cache path invariant violated",
94
+ suggestion: "Clear the cache and rebuild",
95
+ });
96
+ /** Production domain resolved but no active release found */
97
+ export const RELEASE_NOT_FOUND = defineError({
98
+ slug: "release-not-found",
99
+ category: "SERVER",
100
+ status: 404,
101
+ title: "No active release found",
102
+ suggestion: "Deploy the project to create a release for this environment",
103
+ });
104
+ /** Both primary and fallback operations failed (replaces FallbackExecutionError) */
105
+ export const FALLBACK_EXHAUSTED = defineError({
106
+ slug: "fallback-exhausted",
107
+ category: "SERVER",
108
+ status: 500,
109
+ title: "Primary and fallback operations both failed",
110
+ suggestion: "Check service availability and connectivity",
111
+ });
112
+ /** Registry fragment for SERVER errors (slug → definition). */
113
+ export const SERVER_REGISTRY = {
114
+ "port-in-use": PORT_IN_USE,
115
+ "server-start-error": SERVER_START_ERROR,
116
+ "cache-error": CACHE_ERROR,
117
+ "file-watch-error": FILE_WATCH_ERROR,
118
+ "request-error": REQUEST_ERROR,
119
+ "service-overloaded": SERVICE_OVERLOADED,
120
+ "semaphore-timeout": SEMAPHORE_TIMEOUT,
121
+ "circuit-breaker-open": CIRCUIT_BREAKER_OPEN,
122
+ "cache-path-mismatch": CACHE_PATH_MISMATCH,
123
+ "network-error": NETWORK_ERROR,
124
+ "api-client-error": API_CLIENT_ERROR,
125
+ "token-storage-error": TOKEN_STORAGE_ERROR,
126
+ "cache-invariant-violation": CACHE_INVARIANT_VIOLATION,
127
+ "release-not-found": RELEASE_NOT_FOUND,
128
+ "fallback-exhausted": FALLBACK_EXHAUSTED,
129
+ };