Erster Docker-Stand

This commit is contained in:
Ali
2026-02-20 16:06:40 +09:00
commit f31e2e8ed3
8818 changed files with 1605323 additions and 0 deletions

View File

@@ -0,0 +1,4 @@
export interface ErrorWithBatchIndex {
batchRequestIdx?: number;
}
export declare function hasBatchIndex(value: object): value is Required<ErrorWithBatchIndex>;

View File

@@ -0,0 +1,7 @@
export declare class PrismaClientInitializationError extends Error {
clientVersion: string;
errorCode?: string;
retryable?: boolean;
constructor(message: string, clientVersion: string, errorCode?: string);
get [Symbol.toStringTag](): string;
}

View File

@@ -0,0 +1,16 @@
import { ErrorWithBatchIndex } from './ErrorWithBatchIndex';
type KnownErrorParams = {
code: string;
clientVersion: string;
meta?: Record<string, unknown>;
batchRequestIdx?: number;
};
export declare class PrismaClientKnownRequestError extends Error implements ErrorWithBatchIndex {
code: string;
meta?: Record<string, unknown>;
clientVersion: string;
batchRequestIdx?: number;
constructor(message: string, { code, clientVersion, meta, batchRequestIdx }: KnownErrorParams);
get [Symbol.toStringTag](): string;
}
export {};

View File

@@ -0,0 +1,16 @@
import { type RustLog } from './log';
export type PrismaClientRustErrorArgs = {
clientVersion: string;
error: RustLog;
};
/**
* A generic Prisma Client Rust error.
* This error is being exposed via the `prisma.$on('error')` interface
*/
export declare class PrismaClientRustError extends Error {
clientVersion: string;
private _isPanic;
constructor({ clientVersion, error }: PrismaClientRustErrorArgs);
get [Symbol.toStringTag](): string;
isPanic(): boolean;
}

View File

@@ -0,0 +1,5 @@
export declare class PrismaClientRustPanicError extends Error {
clientVersion: string;
constructor(message: string, clientVersion: string);
get [Symbol.toStringTag](): string;
}

View File

@@ -0,0 +1,12 @@
import { ErrorWithBatchIndex } from './ErrorWithBatchIndex';
type UnknownErrorParams = {
clientVersion: string;
batchRequestIdx?: number;
};
export declare class PrismaClientUnknownRequestError extends Error implements ErrorWithBatchIndex {
clientVersion: string;
batchRequestIdx?: number;
constructor(message: string, { clientVersion, batchRequestIdx }: UnknownErrorParams);
get [Symbol.toStringTag](): string;
}
export {};

View File

@@ -0,0 +1,10 @@
type Options = {
clientVersion: string;
};
export declare class PrismaClientValidationError extends Error {
name: string;
clientVersion: string;
constructor(message: string, { clientVersion }: Options);
get [Symbol.toStringTag](): string;
}
export {};

View File

@@ -0,0 +1,7 @@
export * from './ErrorWithBatchIndex';
export * from './PrismaClientInitializationError';
export * from './PrismaClientKnownRequestError';
export * from './PrismaClientRustError';
export * from './PrismaClientRustPanicError';
export * from './PrismaClientUnknownRequestError';
export * from './PrismaClientValidationError';

View File

@@ -0,0 +1,50 @@
import { PrismaClientRustError } from './PrismaClientRustError';
export type LogLevel = 'info' | 'trace' | 'debug' | 'warn' | 'error' | 'query';
export interface RawRustLog {
timestamp: string;
level: LogLevel;
target: string;
fields: LogFields;
}
export interface RustLog {
timestamp: Date;
level: LogLevel;
target: string;
fields: LogFields;
}
export declare function getMessage(log: string | PrismaClientRustError): string;
export declare function getBacktrace(log: RustLog): string;
export declare function isPanic(err: RustLog): boolean;
export declare function isRustLog(e: any): e is RustLog;
export declare function isRustErrorLog(e: any): e is RustLog;
export type LogFields = {
[key: string]: any;
};
export interface PanicLogFields {
message: 'PANIC';
reason: string;
file: string;
line: string;
column: number;
}
export interface InfoLogFields {
message: string;
'log.target': string;
'log.module_path': string;
'log.file': string;
'log.line': number;
}
export interface QueryLogFields {
query: string;
item_type: string;
params: string;
duration_ms: number;
}
export interface Log {
message: string;
level: LogLevel;
date: Date;
application: string;
[key: string]: string | Date;
}
export declare function convertLog(rustLog: RawRustLog): RustLog;

View File

@@ -0,0 +1,9 @@
/**
* Used for preserving class names for minified class instances
* Useful for error objects and other classes where public name
* actually matters
*
* @param classObject
* @param name
*/
export declare function setClassName(classObject: Function, name: string): void;