@veloxts/core 0.3.3 → 0.3.5
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/README.md +697 -16
- package/dist/app.d.ts +67 -10
- package/dist/app.d.ts.map +1 -1
- package/dist/app.js +79 -12
- package/dist/app.js.map +1 -1
- package/dist/context.d.ts +26 -1
- package/dist/context.d.ts.map +1 -1
- package/dist/context.js +29 -0
- package/dist/context.js.map +1 -1
- package/dist/di/container.d.ts +406 -0
- package/dist/di/container.d.ts.map +1 -0
- package/dist/di/container.js +699 -0
- package/dist/di/container.js.map +1 -0
- package/dist/di/decorators.d.ts +235 -0
- package/dist/di/decorators.d.ts.map +1 -0
- package/dist/di/decorators.js +297 -0
- package/dist/di/decorators.js.map +1 -0
- package/dist/di/index.d.ts +65 -0
- package/dist/di/index.d.ts.map +1 -0
- package/dist/di/index.js +73 -0
- package/dist/di/index.js.map +1 -0
- package/dist/di/providers.d.ts +397 -0
- package/dist/di/providers.d.ts.map +1 -0
- package/dist/di/providers.js +380 -0
- package/dist/di/providers.js.map +1 -0
- package/dist/di/scope.d.ts +230 -0
- package/dist/di/scope.d.ts.map +1 -0
- package/dist/di/scope.js +294 -0
- package/dist/di/scope.js.map +1 -0
- package/dist/di/tokens.d.ts +227 -0
- package/dist/di/tokens.d.ts.map +1 -0
- package/dist/di/tokens.js +192 -0
- package/dist/di/tokens.js.map +1 -0
- package/dist/errors/catalog.d.ts +79 -0
- package/dist/errors/catalog.d.ts.map +1 -0
- package/dist/errors/catalog.js +492 -0
- package/dist/errors/catalog.js.map +1 -0
- package/dist/errors/formatter.d.ts +101 -0
- package/dist/errors/formatter.d.ts.map +1 -0
- package/dist/errors/formatter.js +330 -0
- package/dist/errors/formatter.js.map +1 -0
- package/dist/errors/index.d.ts +14 -0
- package/dist/errors/index.d.ts.map +1 -0
- package/dist/errors/index.js +16 -0
- package/dist/errors/index.js.map +1 -0
- package/dist/errors.d.ts +35 -5
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js +57 -4
- package/dist/errors.js.map +1 -1
- package/dist/index.d.ts +10 -6
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +29 -6
- package/dist/index.js.map +1 -1
- package/package.json +14 -2
|
@@ -0,0 +1,492 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Error Catalog - Centralized error definitions with fix suggestions
|
|
3
|
+
*
|
|
4
|
+
* Error codes follow the pattern: VELOX-XYYY
|
|
5
|
+
* - X: Domain (1=Core, 2=Router, 3=Auth, 4=ORM, 5=Validation, 6=Client)
|
|
6
|
+
* - YYY: Sequential number within domain
|
|
7
|
+
*
|
|
8
|
+
* @module errors/catalog
|
|
9
|
+
*/
|
|
10
|
+
// ============================================================================
|
|
11
|
+
// Error Code Domains
|
|
12
|
+
// ============================================================================
|
|
13
|
+
/**
|
|
14
|
+
* Error code domain prefixes
|
|
15
|
+
*/
|
|
16
|
+
export const ERROR_DOMAINS = {
|
|
17
|
+
CORE: 1,
|
|
18
|
+
ROUTER: 2,
|
|
19
|
+
AUTH: 3,
|
|
20
|
+
ORM: 4,
|
|
21
|
+
VALIDATION: 5,
|
|
22
|
+
CLIENT: 6,
|
|
23
|
+
};
|
|
24
|
+
// ============================================================================
|
|
25
|
+
// Error Catalog Registry
|
|
26
|
+
// ============================================================================
|
|
27
|
+
/**
|
|
28
|
+
* The complete error catalog
|
|
29
|
+
* Organized by domain for easy navigation
|
|
30
|
+
*/
|
|
31
|
+
export const ERROR_CATALOG = {
|
|
32
|
+
// ==========================================================================
|
|
33
|
+
// CORE ERRORS (1XXX)
|
|
34
|
+
// ==========================================================================
|
|
35
|
+
'VELOX-1001': {
|
|
36
|
+
code: 'VELOX-1001',
|
|
37
|
+
title: 'Server Already Running',
|
|
38
|
+
description: 'Attempted to start a VeloxTS server that is already running.',
|
|
39
|
+
statusCode: 500,
|
|
40
|
+
fix: {
|
|
41
|
+
suggestion: 'Stop the existing server before starting a new one, or check if another process is using the port.',
|
|
42
|
+
example: `// Stop the server before restarting
|
|
43
|
+
await app.stop();
|
|
44
|
+
await app.start();
|
|
45
|
+
|
|
46
|
+
// Or check if you're calling start() multiple times
|
|
47
|
+
const app = await veloxApp({ port: 3000 });
|
|
48
|
+
await app.start(); // Call only once`,
|
|
49
|
+
},
|
|
50
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-1001',
|
|
51
|
+
},
|
|
52
|
+
'VELOX-1002': {
|
|
53
|
+
code: 'VELOX-1002',
|
|
54
|
+
title: 'Server Not Running',
|
|
55
|
+
description: 'Attempted to stop a VeloxTS server that is not running.',
|
|
56
|
+
statusCode: 500,
|
|
57
|
+
fix: {
|
|
58
|
+
suggestion: 'Ensure the server is started before attempting to stop it.',
|
|
59
|
+
example: `const app = await veloxApp({ port: 3000 });
|
|
60
|
+
await app.start(); // Must call start() first
|
|
61
|
+
// ... handle requests
|
|
62
|
+
await app.stop(); // Now safe to stop`,
|
|
63
|
+
},
|
|
64
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-1002',
|
|
65
|
+
},
|
|
66
|
+
'VELOX-1003': {
|
|
67
|
+
code: 'VELOX-1003',
|
|
68
|
+
title: 'Plugin Registration Failed',
|
|
69
|
+
description: 'A plugin failed to register with the VeloxTS application.',
|
|
70
|
+
statusCode: 500,
|
|
71
|
+
fix: {
|
|
72
|
+
suggestion: 'Check that the plugin is correctly configured and all required dependencies are available.',
|
|
73
|
+
example: `// Ensure plugin is awaited and properly configured
|
|
74
|
+
await app.register(databasePlugin({
|
|
75
|
+
client: prisma // Required: pass Prisma client
|
|
76
|
+
}));
|
|
77
|
+
|
|
78
|
+
// Check plugin order - some plugins depend on others
|
|
79
|
+
await app.register(databasePlugin({ client: prisma }));
|
|
80
|
+
await app.register(authPlugin(authConfig)); // Auth needs database`,
|
|
81
|
+
},
|
|
82
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-1003',
|
|
83
|
+
},
|
|
84
|
+
'VELOX-1004': {
|
|
85
|
+
code: 'VELOX-1004',
|
|
86
|
+
title: 'Configuration Error',
|
|
87
|
+
description: 'The VeloxTS application configuration is invalid or incomplete.',
|
|
88
|
+
statusCode: 500,
|
|
89
|
+
fix: {
|
|
90
|
+
suggestion: 'Review your configuration options and ensure all required fields are provided.',
|
|
91
|
+
example: `// Correct configuration
|
|
92
|
+
const app = await veloxApp({
|
|
93
|
+
port: parseInt(process.env.PORT || '3000'),
|
|
94
|
+
host: process.env.HOST || '0.0.0.0',
|
|
95
|
+
logger: process.env.NODE_ENV !== 'test',
|
|
96
|
+
});`,
|
|
97
|
+
},
|
|
98
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-1004',
|
|
99
|
+
},
|
|
100
|
+
'VELOX-1005': {
|
|
101
|
+
code: 'VELOX-1005',
|
|
102
|
+
title: 'Invalid Plugin Metadata',
|
|
103
|
+
description: 'A plugin was registered without required metadata (name, version).',
|
|
104
|
+
statusCode: 500,
|
|
105
|
+
fix: {
|
|
106
|
+
suggestion: 'Ensure your plugin exports proper metadata.',
|
|
107
|
+
example: `// Plugin must have name property
|
|
108
|
+
const myPlugin: VeloxPlugin = {
|
|
109
|
+
name: 'my-plugin',
|
|
110
|
+
version: '1.0.0', // Optional but recommended
|
|
111
|
+
register: async (app) => {
|
|
112
|
+
// Plugin logic
|
|
113
|
+
}
|
|
114
|
+
};`,
|
|
115
|
+
},
|
|
116
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-1005',
|
|
117
|
+
},
|
|
118
|
+
// ==========================================================================
|
|
119
|
+
// ROUTER ERRORS (2XXX)
|
|
120
|
+
// ==========================================================================
|
|
121
|
+
'VELOX-2001': {
|
|
122
|
+
code: 'VELOX-2001',
|
|
123
|
+
title: 'Procedure Missing Input Schema',
|
|
124
|
+
description: 'A procedure was defined without an input schema, but receives input data.',
|
|
125
|
+
statusCode: 500,
|
|
126
|
+
fix: {
|
|
127
|
+
suggestion: 'Add .input() to your procedure definition with a Zod schema.',
|
|
128
|
+
example: `export const getUser = procedure()
|
|
129
|
+
.input(z.object({ id: z.string().uuid() })) // Add input schema
|
|
130
|
+
.query(async ({ input, ctx }) => {
|
|
131
|
+
return ctx.db.user.findUnique({ where: { id: input.id } });
|
|
132
|
+
});`,
|
|
133
|
+
},
|
|
134
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-2001',
|
|
135
|
+
seeAlso: ['VELOX-2002'],
|
|
136
|
+
},
|
|
137
|
+
'VELOX-2002': {
|
|
138
|
+
code: 'VELOX-2002',
|
|
139
|
+
title: 'Procedure Missing Output Schema',
|
|
140
|
+
description: 'A procedure was defined without an output schema. Output schemas ensure type safety.',
|
|
141
|
+
statusCode: 500,
|
|
142
|
+
fix: {
|
|
143
|
+
suggestion: 'Add .output() to your procedure definition for type-safe responses.',
|
|
144
|
+
example: `export const getUser = procedure()
|
|
145
|
+
.input(z.object({ id: z.string().uuid() }))
|
|
146
|
+
.output(UserSchema) // Add output schema
|
|
147
|
+
.query(async ({ input, ctx }) => {
|
|
148
|
+
return ctx.db.user.findUnique({ where: { id: input.id } });
|
|
149
|
+
});`,
|
|
150
|
+
},
|
|
151
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-2002',
|
|
152
|
+
seeAlso: ['VELOX-2001'],
|
|
153
|
+
},
|
|
154
|
+
'VELOX-2003': {
|
|
155
|
+
code: 'VELOX-2003',
|
|
156
|
+
title: 'Guard Authorization Failed',
|
|
157
|
+
description: 'A guard prevented access to a procedure. The user lacks required permissions.',
|
|
158
|
+
statusCode: 403,
|
|
159
|
+
fix: {
|
|
160
|
+
suggestion: 'Ensure the user is authenticated and has the required roles/permissions.',
|
|
161
|
+
example: `// Using built-in guards
|
|
162
|
+
const protectedProcedure = procedure()
|
|
163
|
+
.guard(authenticated) // Requires valid auth
|
|
164
|
+
.query(({ ctx }) => ctx.user);
|
|
165
|
+
|
|
166
|
+
// Check user has required role
|
|
167
|
+
const adminProcedure = procedure()
|
|
168
|
+
.guard(hasRole('admin'))
|
|
169
|
+
.mutation(({ input }) => { /* ... */ });`,
|
|
170
|
+
},
|
|
171
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-2003',
|
|
172
|
+
},
|
|
173
|
+
'VELOX-2004': {
|
|
174
|
+
code: 'VELOX-2004',
|
|
175
|
+
title: 'Duplicate Procedure Name',
|
|
176
|
+
description: 'Two procedures in the same collection have the same name.',
|
|
177
|
+
statusCode: 500,
|
|
178
|
+
fix: {
|
|
179
|
+
suggestion: 'Ensure all procedure names within a collection are unique.',
|
|
180
|
+
example: `// Wrong: duplicate names
|
|
181
|
+
const userProcedures = defineProcedures('users', {
|
|
182
|
+
getUser: procedure()...,
|
|
183
|
+
getUser: procedure()..., // Error: duplicate!
|
|
184
|
+
});
|
|
185
|
+
|
|
186
|
+
// Correct: unique names
|
|
187
|
+
const userProcedures = defineProcedures('users', {
|
|
188
|
+
getUser: procedure()...,
|
|
189
|
+
getUserProfile: procedure()..., // Different name
|
|
190
|
+
});`,
|
|
191
|
+
},
|
|
192
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-2004',
|
|
193
|
+
},
|
|
194
|
+
'VELOX-2005': {
|
|
195
|
+
code: 'VELOX-2005',
|
|
196
|
+
title: 'Invalid REST Method Override',
|
|
197
|
+
description: 'The .rest() configuration contains an invalid HTTP method.',
|
|
198
|
+
statusCode: 500,
|
|
199
|
+
fix: {
|
|
200
|
+
suggestion: 'Use a valid HTTP method: GET, POST, PUT, PATCH, or DELETE.',
|
|
201
|
+
example: `// Correct usage
|
|
202
|
+
const updateUser = procedure()
|
|
203
|
+
.rest({ method: 'PUT', path: '/users/:id' })
|
|
204
|
+
.input(UpdateUserSchema)
|
|
205
|
+
.mutation(({ input }) => { /* ... */ });`,
|
|
206
|
+
},
|
|
207
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-2005',
|
|
208
|
+
},
|
|
209
|
+
// ==========================================================================
|
|
210
|
+
// AUTH ERRORS (3XXX)
|
|
211
|
+
// ==========================================================================
|
|
212
|
+
'VELOX-3001': {
|
|
213
|
+
code: 'VELOX-3001',
|
|
214
|
+
title: 'Invalid JWT Secret',
|
|
215
|
+
description: 'The JWT secret is missing, too short, or lacks sufficient entropy.',
|
|
216
|
+
statusCode: 500,
|
|
217
|
+
fix: {
|
|
218
|
+
suggestion: 'Provide a strong secret with at least 64 characters and 16 unique characters.',
|
|
219
|
+
example: `# Generate a secure secret
|
|
220
|
+
openssl rand -base64 64
|
|
221
|
+
|
|
222
|
+
# Set in environment
|
|
223
|
+
JWT_SECRET=<your-64-char-secret>
|
|
224
|
+
JWT_REFRESH_SECRET=<another-64-char-secret>`,
|
|
225
|
+
},
|
|
226
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-3001',
|
|
227
|
+
},
|
|
228
|
+
'VELOX-3002': {
|
|
229
|
+
code: 'VELOX-3002',
|
|
230
|
+
title: 'Token Expired',
|
|
231
|
+
description: 'The JWT access token has expired and cannot be used for authentication.',
|
|
232
|
+
statusCode: 401,
|
|
233
|
+
fix: {
|
|
234
|
+
suggestion: 'Refresh the access token using your refresh token, or re-authenticate.',
|
|
235
|
+
example: `// Client-side token refresh
|
|
236
|
+
const response = await fetch('/api/auth/refresh', {
|
|
237
|
+
method: 'POST',
|
|
238
|
+
headers: { 'Content-Type': 'application/json' },
|
|
239
|
+
body: JSON.stringify({ refreshToken: storedRefreshToken }),
|
|
240
|
+
});
|
|
241
|
+
const { accessToken } = await response.json();`,
|
|
242
|
+
},
|
|
243
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-3002',
|
|
244
|
+
},
|
|
245
|
+
'VELOX-3003': {
|
|
246
|
+
code: 'VELOX-3003',
|
|
247
|
+
title: 'Invalid Credentials',
|
|
248
|
+
description: 'The provided email or password is incorrect.',
|
|
249
|
+
statusCode: 401,
|
|
250
|
+
fix: {
|
|
251
|
+
suggestion: 'Verify the email and password are correct. Passwords are case-sensitive.',
|
|
252
|
+
},
|
|
253
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-3003',
|
|
254
|
+
},
|
|
255
|
+
'VELOX-3004': {
|
|
256
|
+
code: 'VELOX-3004',
|
|
257
|
+
title: 'Rate Limit Exceeded',
|
|
258
|
+
description: 'Too many authentication attempts. Please wait before trying again.',
|
|
259
|
+
statusCode: 429,
|
|
260
|
+
fix: {
|
|
261
|
+
suggestion: 'Wait for the rate limit window to reset before retrying.',
|
|
262
|
+
example: `// The response includes retry timing
|
|
263
|
+
// Retry-After: 900 (seconds until reset)
|
|
264
|
+
|
|
265
|
+
// Client should wait before retrying
|
|
266
|
+
if (response.status === 429) {
|
|
267
|
+
const retryAfter = response.headers.get('Retry-After');
|
|
268
|
+
await delay(parseInt(retryAfter) * 1000);
|
|
269
|
+
}`,
|
|
270
|
+
},
|
|
271
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-3004',
|
|
272
|
+
},
|
|
273
|
+
'VELOX-3005': {
|
|
274
|
+
code: 'VELOX-3005',
|
|
275
|
+
title: 'Session Secret Invalid',
|
|
276
|
+
description: 'The session secret is missing or has insufficient entropy.',
|
|
277
|
+
statusCode: 500,
|
|
278
|
+
fix: {
|
|
279
|
+
suggestion: 'Provide a session secret with at least 32 characters and 16 unique characters.',
|
|
280
|
+
example: `# Generate a secure session secret
|
|
281
|
+
openssl rand -base64 32
|
|
282
|
+
|
|
283
|
+
# Set in environment
|
|
284
|
+
SESSION_SECRET=<your-32-char-secret>`,
|
|
285
|
+
},
|
|
286
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-3005',
|
|
287
|
+
},
|
|
288
|
+
'VELOX-3006': {
|
|
289
|
+
code: 'VELOX-3006',
|
|
290
|
+
title: 'CSRF Token Invalid',
|
|
291
|
+
description: 'The CSRF token is missing, expired, or does not match.',
|
|
292
|
+
statusCode: 403,
|
|
293
|
+
fix: {
|
|
294
|
+
suggestion: 'Include a valid CSRF token in your request.',
|
|
295
|
+
example: `// Get CSRF token from cookie or meta tag
|
|
296
|
+
const csrfToken = document.querySelector('meta[name="csrf-token"]')?.content;
|
|
297
|
+
|
|
298
|
+
// Include in request headers
|
|
299
|
+
fetch('/api/users', {
|
|
300
|
+
method: 'POST',
|
|
301
|
+
headers: {
|
|
302
|
+
'Content-Type': 'application/json',
|
|
303
|
+
'X-CSRF-Token': csrfToken,
|
|
304
|
+
},
|
|
305
|
+
body: JSON.stringify(data),
|
|
306
|
+
});`,
|
|
307
|
+
},
|
|
308
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-3006',
|
|
309
|
+
},
|
|
310
|
+
'VELOX-3007': {
|
|
311
|
+
code: 'VELOX-3007',
|
|
312
|
+
title: 'Token Revoked',
|
|
313
|
+
description: 'This token has been revoked and can no longer be used.',
|
|
314
|
+
statusCode: 401,
|
|
315
|
+
fix: {
|
|
316
|
+
suggestion: 'Re-authenticate to obtain new tokens.',
|
|
317
|
+
},
|
|
318
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-3007',
|
|
319
|
+
},
|
|
320
|
+
// ==========================================================================
|
|
321
|
+
// ORM ERRORS (4XXX)
|
|
322
|
+
// ==========================================================================
|
|
323
|
+
'VELOX-4001': {
|
|
324
|
+
code: 'VELOX-4001',
|
|
325
|
+
title: 'Database Connection Failed',
|
|
326
|
+
description: 'Could not establish a connection to the database.',
|
|
327
|
+
statusCode: 503,
|
|
328
|
+
fix: {
|
|
329
|
+
suggestion: 'Verify DATABASE_URL is correct and the database server is running.',
|
|
330
|
+
example: `# Check your .env file
|
|
331
|
+
DATABASE_URL="postgresql://user:password@localhost:5432/mydb"
|
|
332
|
+
|
|
333
|
+
# For SQLite
|
|
334
|
+
DATABASE_URL="file:./dev.db"
|
|
335
|
+
|
|
336
|
+
# Ensure database server is running
|
|
337
|
+
docker ps # Check if database container is up`,
|
|
338
|
+
},
|
|
339
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-4001',
|
|
340
|
+
},
|
|
341
|
+
'VELOX-4002': {
|
|
342
|
+
code: 'VELOX-4002',
|
|
343
|
+
title: 'Database Already Connected',
|
|
344
|
+
description: 'Attempted to connect to a database that is already connected.',
|
|
345
|
+
statusCode: 500,
|
|
346
|
+
fix: {
|
|
347
|
+
suggestion: 'The database client is already connected. Avoid calling connect() multiple times.',
|
|
348
|
+
example: `// Connection is typically managed automatically
|
|
349
|
+
// Only call connect manually if needed
|
|
350
|
+
if (!isConnected) {
|
|
351
|
+
await prisma.$connect();
|
|
352
|
+
}`,
|
|
353
|
+
},
|
|
354
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-4002',
|
|
355
|
+
},
|
|
356
|
+
'VELOX-4003': {
|
|
357
|
+
code: 'VELOX-4003',
|
|
358
|
+
title: 'Missing Database Plugin',
|
|
359
|
+
description: 'Attempted to access ctx.db without registering the database plugin.',
|
|
360
|
+
statusCode: 500,
|
|
361
|
+
fix: {
|
|
362
|
+
suggestion: 'Register the database plugin before accessing ctx.db.',
|
|
363
|
+
example: `import { databasePlugin } from '@veloxts/velox';
|
|
364
|
+
import { prisma } from './database/index.js';
|
|
365
|
+
|
|
366
|
+
const app = await veloxApp({ port: 3000 });
|
|
367
|
+
await app.register(databasePlugin({ client: prisma }));
|
|
368
|
+
|
|
369
|
+
// Now ctx.db is available in procedures`,
|
|
370
|
+
},
|
|
371
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-4003',
|
|
372
|
+
},
|
|
373
|
+
// ==========================================================================
|
|
374
|
+
// VALIDATION ERRORS (5XXX)
|
|
375
|
+
// ==========================================================================
|
|
376
|
+
'VELOX-5001': {
|
|
377
|
+
code: 'VELOX-5001',
|
|
378
|
+
title: 'Validation Failed',
|
|
379
|
+
description: 'The request data failed schema validation.',
|
|
380
|
+
statusCode: 400,
|
|
381
|
+
fix: {
|
|
382
|
+
suggestion: 'Check the fields property for specific validation errors.',
|
|
383
|
+
example: `// Response includes field-specific errors
|
|
384
|
+
{
|
|
385
|
+
"error": "ValidationError",
|
|
386
|
+
"message": "Validation failed",
|
|
387
|
+
"statusCode": 400,
|
|
388
|
+
"code": "VELOX-5001",
|
|
389
|
+
"fields": {
|
|
390
|
+
"email": "Invalid email format",
|
|
391
|
+
"age": "Must be at least 18"
|
|
392
|
+
}
|
|
393
|
+
}`,
|
|
394
|
+
},
|
|
395
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-5001',
|
|
396
|
+
},
|
|
397
|
+
'VELOX-5002': {
|
|
398
|
+
code: 'VELOX-5002',
|
|
399
|
+
title: 'Invalid Schema Definition',
|
|
400
|
+
description: 'The Zod schema definition is invalid.',
|
|
401
|
+
statusCode: 500,
|
|
402
|
+
fix: {
|
|
403
|
+
suggestion: 'Check your Zod schema for syntax errors or invalid chaining.',
|
|
404
|
+
example: `// Correct schema definition
|
|
405
|
+
const UserSchema = z.object({
|
|
406
|
+
id: z.string().uuid(),
|
|
407
|
+
email: z.string().email(),
|
|
408
|
+
age: z.number().min(0).max(150),
|
|
409
|
+
});`,
|
|
410
|
+
},
|
|
411
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-5002',
|
|
412
|
+
},
|
|
413
|
+
// ==========================================================================
|
|
414
|
+
// CLIENT ERRORS (6XXX)
|
|
415
|
+
// ==========================================================================
|
|
416
|
+
'VELOX-6001': {
|
|
417
|
+
code: 'VELOX-6001',
|
|
418
|
+
title: 'Network Request Failed',
|
|
419
|
+
description: 'The HTTP request could not be completed due to a network error.',
|
|
420
|
+
statusCode: 0,
|
|
421
|
+
fix: {
|
|
422
|
+
suggestion: 'Check your internet connection and ensure the API server is reachable.',
|
|
423
|
+
example: `// Handle network errors gracefully
|
|
424
|
+
try {
|
|
425
|
+
const data = await api.users.list();
|
|
426
|
+
} catch (error) {
|
|
427
|
+
if (isNetworkError(error)) {
|
|
428
|
+
console.log('Network unavailable, using cached data');
|
|
429
|
+
return getCachedData();
|
|
430
|
+
}
|
|
431
|
+
throw error;
|
|
432
|
+
}`,
|
|
433
|
+
},
|
|
434
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-6001',
|
|
435
|
+
},
|
|
436
|
+
'VELOX-6002': {
|
|
437
|
+
code: 'VELOX-6002',
|
|
438
|
+
title: 'API Base URL Not Configured',
|
|
439
|
+
description: 'The VeloxTS client was created without a base URL.',
|
|
440
|
+
statusCode: 500,
|
|
441
|
+
fix: {
|
|
442
|
+
suggestion: 'Provide a baseUrl when creating the client.',
|
|
443
|
+
example: `import { createClient } from '@veloxts/client';
|
|
444
|
+
|
|
445
|
+
const api = createClient({
|
|
446
|
+
baseUrl: process.env.API_URL || 'http://localhost:3000/api',
|
|
447
|
+
});`,
|
|
448
|
+
},
|
|
449
|
+
docsUrl: 'https://veloxts.dev/errors/VELOX-6002',
|
|
450
|
+
},
|
|
451
|
+
};
|
|
452
|
+
// ============================================================================
|
|
453
|
+
// Catalog Access Functions
|
|
454
|
+
// ============================================================================
|
|
455
|
+
/**
|
|
456
|
+
* Get an error catalog entry by code
|
|
457
|
+
*
|
|
458
|
+
* @param code - The error code (e.g., 'VELOX-1001')
|
|
459
|
+
* @returns The catalog entry or undefined if not found
|
|
460
|
+
*/
|
|
461
|
+
export function getErrorEntry(code) {
|
|
462
|
+
return ERROR_CATALOG[code];
|
|
463
|
+
}
|
|
464
|
+
/**
|
|
465
|
+
* Get all error codes for a specific domain
|
|
466
|
+
*
|
|
467
|
+
* @param domain - The error domain (e.g., 'CORE', 'AUTH')
|
|
468
|
+
* @returns Array of error codes in that domain
|
|
469
|
+
*/
|
|
470
|
+
export function getErrorsByDomain(domain) {
|
|
471
|
+
const prefix = `VELOX-${ERROR_DOMAINS[domain]}`;
|
|
472
|
+
return Object.keys(ERROR_CATALOG).filter((code) => code.startsWith(prefix));
|
|
473
|
+
}
|
|
474
|
+
/**
|
|
475
|
+
* Check if an error code exists in the catalog
|
|
476
|
+
*
|
|
477
|
+
* @param code - The error code to check
|
|
478
|
+
* @returns true if the code exists
|
|
479
|
+
*/
|
|
480
|
+
export function isKnownErrorCode(code) {
|
|
481
|
+
return code in ERROR_CATALOG;
|
|
482
|
+
}
|
|
483
|
+
/**
|
|
484
|
+
* Get the documentation URL for an error code
|
|
485
|
+
*
|
|
486
|
+
* @param code - The error code
|
|
487
|
+
* @returns The documentation URL or undefined
|
|
488
|
+
*/
|
|
489
|
+
export function getDocsUrl(code) {
|
|
490
|
+
return ERROR_CATALOG[code]?.docsUrl;
|
|
491
|
+
}
|
|
492
|
+
//# sourceMappingURL=catalog.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"catalog.js","sourceRoot":"","sources":["../../src/errors/catalog.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,+EAA+E;AAC/E,qBAAqB;AACrB,+EAA+E;AAE/E;;GAEG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG;IAC3B,IAAI,EAAE,CAAC;IACP,MAAM,EAAE,CAAC;IACT,IAAI,EAAE,CAAC;IACP,GAAG,EAAE,CAAC;IACN,UAAU,EAAE,CAAC;IACb,MAAM,EAAE,CAAC;CACD,CAAC;AAuCX,+EAA+E;AAC/E,yBAAyB;AACzB,+EAA+E;AAE/E;;;GAGG;AACH,MAAM,CAAC,MAAM,aAAa,GAAsC;IAC9D,6EAA6E;IAC7E,qBAAqB;IACrB,6EAA6E;IAE7E,YAAY,EAAE;QACZ,IAAI,EAAE,YAAY;QAClB,KAAK,EAAE,wBAAwB;QAC/B,WAAW,EAAE,8DAA8D;QAC3E,UAAU,EAAE,GAAG;QACf,GAAG,EAAE;YACH,UAAU,EACR,oGAAoG;YACtG,OAAO,EAAE;;;;;;qCAMsB;SAChC;QACD,OAAO,EAAE,uCAAuC;KACjD;IAED,YAAY,EAAE;QACZ,IAAI,EAAE,YAAY;QAClB,KAAK,EAAE,oBAAoB;QAC3B,WAAW,EAAE,yDAAyD;QACtE,UAAU,EAAE,GAAG;QACf,GAAG,EAAE;YACH,UAAU,EAAE,4DAA4D;YACxE,OAAO,EAAE;;;uCAGwB;SAClC;QACD,OAAO,EAAE,uCAAuC;KACjD;IAED,YAAY,EAAE;QACZ,IAAI,EAAE,YAAY;QAClB,KAAK,EAAE,4BAA4B;QACnC,WAAW,EAAE,2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ASb;SACG;QACD,OAAO,EAAE,uCAAuC;KACjD;IAED,YAAY,EAAE;QACZ,IAAI,EAAE,YAAY;QAClB,KAAK,EAAE,6BAA6B;QACpC,WAAW,EAAE,oDAAoD;QACjE,UAAU,EAAE,GAAG;QACf,GAAG,EAAE;YACH,UAAU,EAAE,6CAA6C;YACzD,OAAO,EAAE;;;;IAIX;SACC;QACD,OAAO,EAAE,uCAAuC;KACjD;CACF,CAAC;AAEF,+EAA+E;AAC/E,2BAA2B;AAC3B,+EAA+E;AAE/E;;;;;GAKG;AACH,MAAM,UAAU,aAAa,CAAC,IAAY;IACxC,OAAO,aAAa,CAAC,IAAI,CAAC,CAAC;AAC7B,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,iBAAiB,CAAC,MAAmB;IACnD,MAAM,MAAM,GAAG,SAAS,aAAa,CAAC,MAAM,CAAC,EAAE,CAAC;IAChD,OAAO,MAAM,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,CAAC;AAC9E,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,gBAAgB,CAAC,IAAY;IAC3C,OAAO,IAAI,IAAI,aAAa,CAAC;AAC/B,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,UAAU,CAAC,IAAY;IACrC,OAAO,aAAa,CAAC,IAAI,CAAC,EAAE,OAAO,CAAC;AACtC,CAAC"}
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Error Formatter - Pretty terminal output with fix suggestions
|
|
3
|
+
*
|
|
4
|
+
* Inspired by Laravel's Ignition error pages, this module provides
|
|
5
|
+
* beautiful, informative error messages with actionable suggestions.
|
|
6
|
+
*
|
|
7
|
+
* @module errors/formatter
|
|
8
|
+
*/
|
|
9
|
+
/**
|
|
10
|
+
* Extracted error location from stack trace
|
|
11
|
+
*/
|
|
12
|
+
export interface ErrorLocation {
|
|
13
|
+
file: string;
|
|
14
|
+
line: number;
|
|
15
|
+
column?: number;
|
|
16
|
+
functionName?: string;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Parse stack trace to extract error location
|
|
20
|
+
*
|
|
21
|
+
* @param error - The error to parse
|
|
22
|
+
* @returns Location info or undefined
|
|
23
|
+
*/
|
|
24
|
+
export declare function extractErrorLocation(error: Error): ErrorLocation | undefined;
|
|
25
|
+
/**
|
|
26
|
+
* Options for error formatting
|
|
27
|
+
*/
|
|
28
|
+
export interface FormatErrorOptions {
|
|
29
|
+
/** Include the stack trace (default: false in production) */
|
|
30
|
+
includeStack?: boolean;
|
|
31
|
+
/** Include the fix suggestion (default: true) */
|
|
32
|
+
includeFix?: boolean;
|
|
33
|
+
/** Include documentation link (default: true) */
|
|
34
|
+
includeDocs?: boolean;
|
|
35
|
+
/** Include related error codes (default: true) */
|
|
36
|
+
includeSeeAlso?: boolean;
|
|
37
|
+
/** Maximum width for text wrapping */
|
|
38
|
+
maxWidth?: number;
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* Format an error for terminal output with fix suggestions
|
|
42
|
+
*
|
|
43
|
+
* @param error - The error to format
|
|
44
|
+
* @param catalogCode - Optional catalog error code
|
|
45
|
+
* @param options - Formatting options
|
|
46
|
+
* @returns Formatted error string for terminal display
|
|
47
|
+
*
|
|
48
|
+
* @example
|
|
49
|
+
* ```typescript
|
|
50
|
+
* try {
|
|
51
|
+
* // ... code that throws
|
|
52
|
+
* } catch (error) {
|
|
53
|
+
* console.error(formatError(error, 'VELOX-1001'));
|
|
54
|
+
* }
|
|
55
|
+
* ```
|
|
56
|
+
*/
|
|
57
|
+
export declare function formatError(error: Error, catalogCode?: string, options?: FormatErrorOptions): string;
|
|
58
|
+
/**
|
|
59
|
+
* Format an error for JSON API response
|
|
60
|
+
* Includes catalog metadata but not stack traces
|
|
61
|
+
*
|
|
62
|
+
* @param error - The error to format
|
|
63
|
+
* @param catalogCode - Optional catalog error code
|
|
64
|
+
* @returns JSON-serializable error object
|
|
65
|
+
*/
|
|
66
|
+
export declare function formatErrorForApi(error: Error & {
|
|
67
|
+
statusCode?: number;
|
|
68
|
+
code?: string;
|
|
69
|
+
fields?: Record<string, string>;
|
|
70
|
+
}, catalogCode?: string): Record<string, unknown>;
|
|
71
|
+
/**
|
|
72
|
+
* Format a short one-line error summary
|
|
73
|
+
*
|
|
74
|
+
* @param error - The error
|
|
75
|
+
* @param catalogCode - Optional catalog code
|
|
76
|
+
* @returns One-line error string
|
|
77
|
+
*/
|
|
78
|
+
export declare function formatErrorOneLine(error: Error, catalogCode?: string): string;
|
|
79
|
+
/**
|
|
80
|
+
* Log an error with pretty formatting
|
|
81
|
+
*
|
|
82
|
+
* @param error - The error to log
|
|
83
|
+
* @param catalogCode - Optional catalog error code
|
|
84
|
+
*/
|
|
85
|
+
export declare function logError(error: Error, catalogCode?: string): void;
|
|
86
|
+
/**
|
|
87
|
+
* Log a warning with pretty formatting
|
|
88
|
+
*
|
|
89
|
+
* @param message - Warning message
|
|
90
|
+
* @param suggestion - Optional fix suggestion
|
|
91
|
+
*/
|
|
92
|
+
export declare function logWarning(message: string, suggestion?: string): void;
|
|
93
|
+
/**
|
|
94
|
+
* Log a deprecation warning
|
|
95
|
+
*
|
|
96
|
+
* @param oldApi - The deprecated API
|
|
97
|
+
* @param newApi - The replacement API
|
|
98
|
+
* @param removeVersion - Version when it will be removed
|
|
99
|
+
*/
|
|
100
|
+
export declare function logDeprecation(oldApi: string, newApi: string, removeVersion?: string): void;
|
|
101
|
+
//# sourceMappingURL=formatter.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formatter.d.ts","sourceRoot":"","sources":["../../src/errors/formatter.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AA+FH;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;I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