refactored monorepo for more projects

This commit is contained in:
Boki 2025-06-22 23:48:01 -04:00
parent 4632c174dc
commit 9492f1b15e
180 changed files with 1438 additions and 424 deletions

View file

@ -73,6 +73,17 @@ export class ConfigManager<T = Record<string, unknown>> {
this.config = this.schema.parse(mergedConfig) as T;
} catch (error) {
if (error instanceof z.ZodError) {
const errorDetails = error.errors.map(err => ({
path: err.path.join('.'),
message: err.message,
code: err.code,
expected: (err as any).expected,
received: (err as any).received,
}));
console.error('Configuration validation failed:');
console.error(JSON.stringify(errorDetails, null, 2));
throw new ConfigValidationError('Configuration validation failed', error.errors);
}
throw error;