@prisma/orm-family-sql 8.0.0-rc.11-dev.30 → 8.0.0-rc.11-dev.31

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.
@@ -1 +1 @@
1
- {"version":3,"file":"contract-prisma7__provider.mjs","names":[],"sources":["../../../../2-sql/2-authoring/contract-prisma7/dist/provider.mjs"],"sourcesContent":["import { readFile, readdir, stat } from \"node:fs/promises\";\nimport { validateContractDomain } from \"@internal/contract/validate-domain\";\nimport { buildSymbolTable, keywordPslSpan, nodePslSpan, rangeToPslSpan, readResolvedAttribute, readResolvedAttributes } from \"@internal/psl-parser\";\nimport { ArrayLiteralAst, BooleanLiteralExprAst, FunctionCallAst, IdentifierAst, NumberLiteralExprAst, StringLiteralExprAst, parse, printSyntax } from \"@internal/psl-parser/syntax\";\nimport { validateModelStorageReferences, validateSqlStorageConsistency } from \"@internal/sql-contract/validators\";\nimport { applySqlSpecifierControlPolicy, buildSqlContractFromDefinition } from \"@internal/sql-contract-ts/contract-builder\";\nimport { blindCast } from \"@internal/utils/casts\";\nimport { InternalError } from \"@internal/utils/internal-error\";\nimport { notOk, ok } from \"@internal/utils/result\";\nimport { isStructuredError } from \"@internal/utils/structured-error\";\nimport { basename, dirname, extname, join, normalize } from \"pathe\";\nimport { collectScalarTypeConstructors, instantiateAuthoringEntityType } from \"@internal/framework-components/authoring\";\nimport { deriveValueSetFromEntity } from \"@internal/sql-contract/value-set-derivation-hook\";\nimport { applyBackrelationCandidates, buildEntityTypesByDiscriminator, indexFkRelations, normalizeReferentialAction, numberLiteralDefault, resolveFieldTypeDescriptor } from \"@internal/sql-contract-psl/resolution\";\nimport { ifDefined } from \"@internal/utils/defined\";\nimport { fkRelationPairKey } from \"@internal/psl-parser/interpret\";\n//#region src/diagnostics.ts\nfunction prisma7Diagnostic(code, message, sourceId, span) {\n\treturn {\n\t\tcode,\n\t\tmessage,\n\t\tsourceId,\n\t\t...span !== void 0 ? { span } : {}\n\t};\n}\nfunction andList(items) {\n\tconst leading = items.slice(0, -1);\n\tconst last = items[items.length - 1] ?? \"\";\n\treturn leading.length === 0 ? last : `${leading.join(\", \")} and ${last}`;\n}\nfunction fieldList(modelName, fieldNames) {\n\treturn andList(fieldNames.map((name) => `\"${modelName}.${name}\"`));\n}\nfunction ignoredFieldReferenced(input) {\n\tconst fields = fieldList(input.modelName, input.fieldNames);\n\tconst one = input.fieldNames.length === 1;\n\treturn prisma7Diagnostic(\"PSL.PRISMA7_IGNORED_FIELD_REFERENCED\", `${one ? \"Field\" : \"Fields\"} ${fields} ${one ? \"is\" : \"are\"} marked @ignore, but ${input.usedBy} uses ${one ? \"it\" : \"them\"}, and Prisma 7 still creates the ${input.constraint} that includes ${one ? \"its column\" : \"their columns\"}. Remove @ignore from ${fields}; Prisma 7's next migration is then empty, and ${one ? \"the field appears\" : \"the fields appear\"} in the Prisma 7 client again.`, input.sourceId, input.span);\n}\n//#endregion\n//#region src/defaults.ts\nconst CLIENT_SIDE_GENERATORS = /* @__PURE__ */ new Set([\n\t\"uuid\",\n\t\"cuid\",\n\t\"ulid\",\n\t\"nanoid\"\n]);\nfunction givesColumnDefault(attribute) {\n\tconst expression = attribute?.args.find((arg) => arg.kind === \"positional\")?.expression;\n\tif (expression === void 0) return false;\n\tconst call = FunctionCallAst.cast(expression.syntax);\n\tif (call === void 0) return true;\n\tconst fn = call.path().join(\".\");\n\tif (CLIENT_SIDE_GENERATORS.has(fn)) return false;\n\treturn fn !== \"dbgenerated\" || [...call.args()].length > 0;\n}\n/** Positional argument keys per Prisma 7 default function, matching the target registry's signatures. */\nconst FUNCTION_ARGUMENT_KEYS = {\n\tuuid: [\"version\"],\n\tcuid: [\"version\"],\n\tnanoid: [\"size\"],\n\tdbgenerated: [\"expression\"],\n\tnow: [],\n\tautoincrement: [],\n\tulid: []\n};\nfunction literalArgument(expression) {\n\tconst text = StringLiteralExprAst.cast(expression.syntax)?.value();\n\tif (text !== void 0) return text;\n\tconst number = NumberLiteralExprAst.cast(expression.syntax)?.value();\n\tif (number !== void 0) return number;\n\treturn BooleanLiteralExprAst.cast(expression.syntax)?.value();\n}\nfunction lowerPrisma7Default(input) {\n\tconst { attribute, field, sourceId, diagnostics } = input;\n\tconst label = `Field \"${input.modelName}.${field.name}\"`;\n\tconst unknown = (reason, span) => {\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_DEFAULT\", `${label}: @default ${reason}`, sourceId, span));\n\t};\n\tconst argument = attribute.args.find((arg) => arg.kind === \"positional\");\n\tconst expression = argument?.expression;\n\tif (argument === void 0 || expression === void 0) return unknown(\"needs one value.\", attribute.span);\n\tconst call = FunctionCallAst.cast(expression.syntax);\n\tif (call !== void 0) return lowerFunction(call, input, label, unknown);\n\tconst rawLiteral = input.literalForm?.kind === \"sqlExpression\" ? sqlExpressionDefault(expression, input.literalForm, input.field.list) : void 0;\n\tif (rawLiteral === \"unreadable\") return unknown(\"holds a value this contract source does not read.\", attribute.span);\n\tif (rawLiteral !== void 0) return {\n\t\tstorage: {\n\t\t\tkind: \"function\",\n\t\t\texpression: rawLiteral.expression\n\t\t},\n\t\tonCreate: void 0\n\t};\n\tconst scalar = scalarValue$1(expression, input, unknown);\n\tif (scalar === void 0) return void 0;\n\treturn {\n\t\tstorage: {\n\t\t\tkind: \"literal\",\n\t\t\tvalue: scalar\n\t\t},\n\t\tonCreate: void 0\n\t};\n}\nfunction scalarValue$1(expression, input, unknown) {\n\tconst span = input.attribute.span;\n\tconst isJson = input.literalForm?.kind === \"json\";\n\tconst jsonNull = (holds) => {\n\t\tinput.diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_JSON_NULL_DEFAULT_UNSUPPORTED\", `Field \"${input.modelName}.${input.field.name}\": @default(${printSyntax(expression.syntax).trim()}) ${holds} the JSON value null, which the contract cannot tell apart from SQL NULL. Remove the @default or give it another JSON value; either changes the column default on Prisma 7's next migration.`, input.sourceId, span));\n\t};\n\tconst array = ArrayLiteralAst.cast(expression.syntax);\n\tif (array !== void 0) {\n\t\tconst values = [];\n\t\tfor (const element of array.elements()) {\n\t\t\tconst value = elementValue(element, input);\n\t\t\tif (value === void 0) return unknown(rejectedNumberReason(element, input) ?? \"lists may only hold literals or enum members.\", span);\n\t\t\tvalues.push(value);\n\t\t}\n\t\tif (isJson && values.includes(null)) return jsonNull(\"holds\");\n\t\treturn values;\n\t}\n\tconst value = elementValue(expression, input);\n\tif (isJson && value === null) return jsonNull(\"is\");\n\tif (value !== void 0) return value;\n\tconst numberReason = rejectedNumberReason(expression, input);\n\tif (numberReason !== void 0) return unknown(numberReason, span);\n\tconst identifier = IdentifierAst.cast(expression.syntax)?.name();\n\tif (identifier !== void 0) return unknown(input.enumMembers === void 0 ? `refers to \"${identifier}\", but the field is not an enum.` : `refers to \"${identifier}\", which is not a member of the field's enum.`, span);\n\treturn unknown(\"holds a value this contract source does not read.\", span);\n}\nfunction sqlExpressionDefault(expression, form, isList) {\n\tconst array = isList ? ArrayLiteralAst.cast(expression.syntax) : void 0;\n\tif (array === void 0) {\n\t\tconst text = StringLiteralExprAst.cast(expression.syntax)?.value();\n\t\tif (text === void 0) return void 0;\n\t\tconst literal = form.literal(text);\n\t\treturn literal === void 0 ? \"unreadable\" : { expression: literal };\n\t}\n\tconst literals = [];\n\tfor (const element of array.elements()) {\n\t\tconst text = StringLiteralExprAst.cast(element.syntax)?.value();\n\t\tconst literal = text === void 0 ? void 0 : form.literal(text);\n\t\tif (literal === void 0) return \"unreadable\";\n\t\tliterals.push(literal);\n\t}\n\treturn { expression: form.list(literals) };\n}\n/** The Prisma 7 scalars whose number defaults must be whole numbers, as each is named in a message. */\nconst WHOLE_NUMBER_SCALARS = {\n\tInt: \"an Int\",\n\tBigInt: \"a BigInt\"\n};\nconst WHOLE_NUMBER_TEXT = /^-?\\d+$/;\n/** The number literal the column codec reads neither as a number nor as text, such as `1.5` for a `BigInt`, which Prisma 7 rejects too. */\nfunction rejectedNumberReason(expression, input) {\n\tconst text = NumberLiteralExprAst.cast(expression.syntax)?.token()?.text;\n\tif (text === void 0 || numberValue(text, input) !== void 0) return void 0;\n\tconst { typeName } = input.field;\n\tconst wholeNumberScalar = Object.hasOwn(WHOLE_NUMBER_SCALARS, typeName) ? WHOLE_NUMBER_SCALARS[typeName] : void 0;\n\treturn wholeNumberScalar === void 0 ? `holds ${text}, which is not a valid ${typeName} value.` : `holds ${text}, which is not an integer; ${wholeNumberScalar} default must be a whole number.`;\n}\n/** A number default for the field: Prisma 7 accepts only whole numbers for `Int` and `BigInt`. */\nfunction numberValue(text, input) {\n\tif (Object.hasOwn(WHOLE_NUMBER_SCALARS, input.field.typeName) && !WHOLE_NUMBER_TEXT.test(text)) return;\n\treturn numberLiteralDefault(text, input.codecId, input.codecLookup);\n}\nfunction elementValue(expression, input) {\n\tconst member = IdentifierAst.cast(expression.syntax)?.name();\n\tif (member !== void 0) return input.enumMembers?.get(member);\n\tconst number = NumberLiteralExprAst.cast(expression.syntax)?.token()?.text;\n\tif (number !== void 0) return numberValue(number, input);\n\tconst text = StringLiteralExprAst.cast(expression.syntax)?.value();\n\tif (text !== void 0) {\n\t\tif (input.literalForm?.kind === \"json\") try {\n\t\t\treturn blindCast(JSON.parse(text));\n\t\t} catch {\n\t\t\treturn;\n\t\t}\n\t\treturn text;\n\t}\n\treturn BooleanLiteralExprAst.cast(expression.syntax)?.value();\n}\nfunction lowerFunction(call, input, label, unknown) {\n\tconst fn = call.path().join(\".\");\n\tconst span = input.attribute.span;\n\tconst callArgs = [...call.args()];\n\tif (fn === \"dbgenerated\" && callArgs.length === 0) {\n\t\tif (input.field.optional || input.field.list) return {\n\t\t\tstorage: void 0,\n\t\t\tonCreate: void 0\n\t\t};\n\t\tinput.diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_DEFAULT\", `${label}: @default(dbgenerated()) with no expression is not supported yet on a required field, because without a column default Prisma 8 requires the value on create. Either remove the @default, which makes Prisma 7's next migration drop the column default (ALTER COLUMN ... DROP DEFAULT) and both clients require the value on create, or write the column's database default as @default(dbgenerated(\"<expression>\")), which Prisma 7's next migration sets on the column.`, input.sourceId, span));\n\t\treturn;\n\t}\n\tconst keys = FUNCTION_ARGUMENT_KEYS[fn];\n\tconst entry = input.controlMutationDefaults.defaultFunctionRegistry.get(fn);\n\tif (keys === void 0 || entry === void 0) return unknown(`function \"${fn}()\" is not a Prisma 7 default function this target supports.`, span);\n\tconst args = {};\n\tlet index = 0;\n\tfor (const arg of callArgs) {\n\t\tconst key = arg.name()?.name() ?? keys[index];\n\t\tconst value = arg.value();\n\t\tconst literal = value === void 0 ? void 0 : literalArgument(value);\n\t\tif (key === void 0 || literal === void 0) return unknown(`function \"${fn}()\" has an argument this contract source does not read.`, span);\n\t\targs[key] = literal;\n\t\tindex += 1;\n\t}\n\tif (fn === \"cuid\") args[\"version\"] = 2;\n\tconst lowered = entry.lower({\n\t\tcall: {\n\t\t\tfn,\n\t\t\tspan,\n\t\t\targs\n\t\t},\n\t\tcontext: {\n\t\t\tsourceId: input.sourceId,\n\t\t\tmodelName: input.modelName,\n\t\t\tfieldName: input.field.name,\n\t\t\tcolumnCodecId: input.codecId\n\t\t}\n\t});\n\tif (!lowered.ok) {\n\t\tinput.diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_DEFAULT\", `${label}: ${lowered.diagnostic.message}`, input.sourceId, span));\n\t\treturn;\n\t}\n\treturn lowered.value.kind === \"storage\" ? {\n\t\tstorage: lowered.value.defaultValue,\n\t\tonCreate: void 0\n\t} : {\n\t\tstorage: void 0,\n\t\tonCreate: lowered.value.generated\n\t};\n}\n//#endregion\n//#region src/indexes.ts\nfunction parseIndexAttribute(attribute, owner, sourceId, indexTypes, diagnostics) {\n\tconst unsupported = (what, span) => {\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_INDEX_ARGUMENT_UNSUPPORTED\", `\"${owner}\": @${attribute.name} ${what}`, sourceId, span));\n\t};\n\tlet fields;\n\tlet map;\n\tlet type;\n\tfor (const arg of attribute.args) {\n\t\tconst key = arg.kind === \"positional\" ? \"fields\" : arg.name;\n\t\tconst expression = arg.expression;\n\t\tswitch (key) {\n\t\t\tcase \"fields\": {\n\t\t\t\tconst array = expression === void 0 ? void 0 : ArrayLiteralAst.cast(expression.syntax);\n\t\t\t\tif (array === void 0) return unsupported(\"expects a list of field names.\", arg.span);\n\t\t\t\tconst names = [];\n\t\t\t\tfor (const element of array.elements()) {\n\t\t\t\t\tconst name = IdentifierAst.cast(element.syntax)?.name();\n\t\t\t\t\tif (name === void 0) return unsupported(\"field arguments such as sort or length are not supported; Prisma 8 indexes carry none.\", arg.span);\n\t\t\t\t\tnames.push(name);\n\t\t\t\t}\n\t\t\t\tfields = names;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tcase \"map\":\n\t\t\t\tmap = expression === void 0 ? void 0 : StringLiteralExprAst.cast(expression.syntax)?.value();\n\t\t\t\tif (map === void 0) return unsupported(\"map must be a string.\", arg.span);\n\t\t\t\tbreak;\n\t\t\tcase \"name\": break;\n\t\t\tcase \"type\": {\n\t\t\t\tconst token = expression === void 0 ? void 0 : IdentifierAst.cast(expression.syntax)?.name();\n\t\t\t\ttype = token !== void 0 && Object.hasOwn(indexTypes, token) ? indexTypes[token] : void 0;\n\t\t\t\tif (type === void 0) return unsupported(`type \"${token ?? \"\"}\" is not an index type Prisma 8 supports.`, arg.span);\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tdefault: return unsupported(`argument \"${key ?? \"\"}\" is not supported.`, arg.span);\n\t\t}\n\t}\n\treturn {\n\t\tfields,\n\t\tmap,\n\t\ttype,\n\t\tspan: attribute.span\n\t};\n}\nconst utf8 = new TextEncoder();\n/**\n* A generated constraint name as Prisma 7 spells it: `base` cut so that\n* `base + suffix` is at most `maxBytes` bytes, cut on a character boundary,\n* with the suffix kept whole. Prisma 7.10.0 emits `..._aVeryLongCo_idx` for a\n* long `@@index`, `..._AB_pkey` and `..._B_index` for a long implicit junction,\n* and cuts a multi-byte name before the character that would cross the budget.\n*/\nfunction prisma7ConstraintName(base, suffix, maxBytes) {\n\tconst budget = maxBytes - utf8.encode(suffix).length;\n\tlet bytes = 0;\n\tlet kept = \"\";\n\tfor (const character of base) {\n\t\tbytes += utf8.encode(character).length;\n\t\tif (bytes > budget) break;\n\t\tkept += character;\n\t}\n\treturn `${kept}${suffix}`;\n}\n/** Prisma 7's default index name: `{table}_{columns}_idx`, or `_key` for a unique index, cut to `maxBytes`. */\nfunction defaultIndexName(tableName, columns, unique, maxBytes) {\n\treturn prisma7ConstraintName(`${tableName}_${columns.join(\"_\")}`, unique ? \"_key\" : \"_idx\", maxBytes);\n}\nfunction indexNode(tableName, columns, attribute, unique, maxBytes) {\n\treturn {\n\t\tcolumns,\n\t\t...attribute.type === void 0 ? {\n\t\t\ttype: void 0,\n\t\t\toptions: void 0\n\t\t} : {\n\t\t\ttype: attribute.type,\n\t\t\toptions: {}\n\t\t},\n\t\twhere: void 0,\n\t\tunique: unique ? true : void 0,\n\t\tmap: attribute.map ?? defaultIndexName(tableName, columns, unique, maxBytes),\n\t\tname: void 0\n\t};\n}\n//#endregion\n//#region src/native-types.ts\nfunction prisma7ScalarMapping(typeMap, scalar) {\n\treturn Object.hasOwn(typeMap.scalars, scalar) ? typeMap.scalars[scalar] : void 0;\n}\nfunction prisma7NativeTypeMapping(typeMap, nativeType, args) {\n\tconst mapping = Object.hasOwn(typeMap.nativeTypes, nativeType) ? typeMap.nativeTypes[nativeType] : void 0;\n\tif (mapping === void 0) return void 0;\n\treturn args.length === 0 ? mapping : {\n\t\tconstructorName: mapping.constructorName,\n\t\targs\n\t};\n}\n//#endregion\n//#region src/relations.ts\n/** The codes `applyBackrelationCandidates` reports, each shown as `PSL.PRISMA7_RELATION_UNRESOLVED`. */\nconst RELATION_PAIRING_CODES = /* @__PURE__ */ new Set([\n\t\"PSL_ORPHANED_BACKRELATION\",\n\t\"PSL_AMBIGUOUS_BACKRELATION\",\n\t\"PSL_NON_UNIQUE_BACKRELATION\",\n\t\"PSL_REQUIRED_ONE_TO_ONE_BACKRELATION\",\n\t\"PSL_JUNCTION_ID_NOT_FK_COVERING\",\n\t\"PSL_JUNCTION_TARGET_FK_NOT_ID\"\n]);\nfunction identifierNames(expression) {\n\tif (expression === void 0) return void 0;\n\tconst array = ArrayLiteralAst.cast(expression.syntax);\n\tif (array === void 0) return void 0;\n\tconst names = [];\n\tfor (const element of array.elements()) {\n\t\tconst name = IdentifierAst.cast(element.syntax)?.name();\n\t\tif (name === void 0) return void 0;\n\t\tnames.push(name);\n\t}\n\treturn names;\n}\nfunction stringValue(expression) {\n\treturn expression === void 0 ? void 0 : StringLiteralExprAst.cast(expression.syntax)?.value();\n}\nconst PRISMA7_REFERENTIAL_ACTIONS = /* @__PURE__ */ new Set([\n\t\"Cascade\",\n\t\"Restrict\",\n\t\"NoAction\",\n\t\"SetNull\",\n\t\"SetDefault\"\n]);\nfunction actionValue(expression) {\n\tconst token = expression === void 0 ? void 0 : IdentifierAst.cast(expression.syntax)?.name();\n\treturn token !== void 0 && PRISMA7_REFERENTIAL_ACTIONS.has(token) ? normalizeReferentialAction(token) : void 0;\n}\nfunction parseRelationAttribute(attribute, label, sourceId, diagnostics) {\n\tlet name;\n\tlet fields;\n\tlet references;\n\tlet onDelete;\n\tlet onUpdate;\n\tconst invalid = (what, span) => {\n\t\tdiagnostics.push({\n\t\t\tcode: \"PSL_INVALID_ATTRIBUTE_ARGUMENT\",\n\t\t\tmessage: `${label}: @relation ${what}.`,\n\t\t\tsourceId,\n\t\t\tspan\n\t\t});\n\t};\n\tfor (const arg of attribute.args) {\n\t\tconst key = arg.kind === \"positional\" ? \"name\" : arg.name;\n\t\tswitch (key) {\n\t\t\tcase \"name\":\n\t\t\t\tname = stringValue(arg.expression);\n\t\t\t\tif (name === void 0) return invalid(\"name must be a string\", arg.span);\n\t\t\t\tbreak;\n\t\t\tcase \"fields\":\n\t\t\t\tfields = identifierNames(arg.expression);\n\t\t\t\tif (fields === void 0) return invalid(\"fields must be a list of field names\", arg.span);\n\t\t\t\tbreak;\n\t\t\tcase \"references\":\n\t\t\t\treferences = identifierNames(arg.expression);\n\t\t\t\tif (references === void 0) return invalid(\"references must be a list of field names\", arg.span);\n\t\t\t\tbreak;\n\t\t\tcase \"onDelete\":\n\t\t\t\tonDelete = actionValue(arg.expression);\n\t\t\t\tif (onDelete === void 0) return invalid(\"onDelete must be a referential action\", arg.span);\n\t\t\t\tbreak;\n\t\t\tcase \"onUpdate\":\n\t\t\t\tonUpdate = actionValue(arg.expression);\n\t\t\t\tif (onUpdate === void 0) return invalid(\"onUpdate must be a referential action\", arg.span);\n\t\t\t\tbreak;\n\t\t\tcase \"map\": break;\n\t\t\tdefault: return invalid(`argument \"${key ?? \"\"}\" is not supported`, arg.span);\n\t\t}\n\t}\n\treturn {\n\t\tname,\n\t\tfields,\n\t\treferences,\n\t\tonDelete,\n\t\tonUpdate,\n\t\tspan: attribute.span\n\t};\n}\nfunction columnNames(model, fieldNames) {\n\tconst columns = [];\n\tfor (const fieldName of fieldNames) {\n\t\tconst column = model.columns.get(fieldName);\n\t\tif (column === void 0) return void 0;\n\t\tcolumns.push(column.columnName);\n\t}\n\treturn columns;\n}\nfunction unresolved(label, reason, sourceId, span) {\n\treturn prisma7Diagnostic(\"PSL.PRISMA7_RELATION_UNRESOLVED\", `${label} ${reason}`, sourceId, span);\n}\nfunction groupBy(items, keyOf) {\n\tconst groups = /* @__PURE__ */ new Map();\n\tfor (const item of items) {\n\t\tconst group = groups.get(keyOf(item)) ?? [];\n\t\tgroups.set(keyOf(item), group);\n\t\tgroup.push(item);\n\t}\n\treturn groups;\n}\nfunction orderJunctionSides(requester, partner) {\n\treturn (requester.model === partner.model ? requester.field.field.name < partner.field.field.name : requester.model.modelName < partner.model.modelName) ? [requester, partner] : [partner, requester];\n}\nfunction junctionKey(namespaceId, name) {\n\treturn JSON.stringify([namespaceId, name]);\n}\n/**\n* Prisma 7's default relation name: the two model names in alphabetical\n* order joined by `To`. Giving every unnamed relation that name lets the\n* shared pairing helper match Prisma 7's rule that an unnamed side pairs only\n* with the unnamed side of the same model pair.\n*/\nfunction effectiveRelationName(attribute, modelName, targetModelName) {\n\tif (attribute?.name !== void 0) return attribute.name;\n\tconst [first, second] = modelName < targetModelName ? [modelName, targetModelName] : [targetModelName, modelName];\n\treturn `${first}To${second}`;\n}\n/**\n* Prisma 7 accepts `SetNull` over a required field and `SetDefault` over a\n* required field with no default, and writes them into the foreign key; the\n* contract rejects both, because the action would fail the first time it runs.\n*/\nfunction referentialActionRejections(input) {\n\tconst { model, relationField, label, fieldNames, span } = input;\n\tconst anotherAction = \"choose another action, which replaces the foreign key on Prisma 7's next migration and leaves the Prisma 7 client unchanged.\";\n\tconst fieldsWhere = (predicate) => fieldNames.filter((name) => {\n\t\tconst column = model.columns.get(name);\n\t\treturn column !== void 0 && predicate(column);\n\t});\n\tconst rejections = [];\n\tfor (const [key, action] of Object.entries(input.actions)) {\n\t\tif (action === \"setNull\") {\n\t\t\tconst required = fieldsWhere((column) => !column.nullable);\n\t\t\tif (required.length === 0) continue;\n\t\t\tconst fields = fieldList(model.modelName, required);\n\t\t\trejections.push(prisma7Diagnostic(\"PSL.PRISMA7_REFERENTIAL_ACTION_UNSUPPORTED\", `${label}: ${key}: SetNull sets the foreign key fields to null, but ${fields} ${required.length === 1 ? \"is\" : \"are\"} required, so Prisma 8 cannot describe this foreign key. Make ${fields}${relationField.optional ? \"\" : ` and \"${model.modelName}.${relationField.name}\"`} optional, which drops NOT NULL on Prisma 7's next migration and makes ${required.length === 1 && relationField.optional ? \"it\" : \"them\"} nullable in the Prisma 7 client, or ${anotherAction}`, model.sourceId, span));\n\t\t}\n\t\tif (action === \"setDefault\") {\n\t\t\tconst withoutDefault = fieldsWhere((column) => !column.nullable && column.default === void 0);\n\t\t\tif (withoutDefault.length === 0) continue;\n\t\t\tconst fields = fieldList(model.modelName, withoutDefault);\n\t\t\tconst one = withoutDefault.length === 1;\n\t\t\tconst generated = withoutDefault.filter((name) => model.columns.get(name)?.executionDefaults?.onCreate !== void 0);\n\t\t\tconst plain = withoutDefault.filter((name) => !generated.includes(name));\n\t\t\tconst generatorNote = generated.length > 0 ? \" (a client-side generator such as uuid() does not give the column one)\" : \"\";\n\t\t\tconst example = \"a column default, such as a literal or @default(dbgenerated(\\\"<expression>\\\"))\";\n\t\t\tconst plainFields = fieldList(model.modelName, plain);\n\t\t\tconst generatedFields = fieldList(model.modelName, generated);\n\t\t\tconst edit = generated.length === 0 ? `Give ${plainFields} ${example}` : plain.length === 0 ? `Replace the @default on ${generatedFields} with ${example}, because a field takes only one @default` : `Give ${plainFields} ${example}, and replace the @default on ${generatedFields} with one, because a field takes only one @default`;\n\t\t\tconst effects = [\n\t\t\t\t`Prisma 7's next migration sets ${one ? \"it\" : \"them\"}`,\n\t\t\t\t...plain.length > 0 ? [`${plainFields} ${plain.length === 1 ? \"becomes\" : \"become\"} optional when creating records with the Prisma 7 client`] : [],\n\t\t\t\t...generated.length > 0 ? [`the Prisma 7 client stops generating ${generated.length === 1 ? \"a value\" : \"values\"} for ${generatedFields}`] : []\n\t\t\t];\n\t\t\trejections.push(prisma7Diagnostic(\"PSL.PRISMA7_REFERENTIAL_ACTION_UNSUPPORTED\", `${label}: ${key}: SetDefault sets the foreign key fields to their column defaults, but ${fields} ${one ? \"is\" : \"are\"} required and ${one ? \"has\" : \"have\"} no column default${generatorNote}, so Prisma 8 cannot describe this foreign key. ${edit}: ${andList(effects)}. Or ${anotherAction}`, model.sourceId, span));\n\t\t}\n\t}\n\treturn rejections;\n}\nfunction lowerRelations(models, naming, diagnostics) {\n\tconst fkRelationMetadata = [];\n\tconst candidates = [];\n\tconst invalidFkPairings = [];\n\tconst foreignKeys = /* @__PURE__ */ new Map();\n\tconst junctions = /* @__PURE__ */ new Map();\n\tconst reportedJunctionNames = /* @__PURE__ */ new Set();\n\tconst junctionRequests = [];\n\tconst addForeignKey = (modelName, node) => {\n\t\tconst existing = foreignKeys.get(modelName) ?? [];\n\t\tforeignKeys.set(modelName, existing);\n\t\texisting.push(node);\n\t};\n\tconst isFkSide = (relationField) => relationField.attribute?.fields !== void 0;\n\tconst sameName = (left, right) => left.attribute?.name === right.attribute?.name;\n\tconst rejectFkSide = (model, relationField, ...rejections) => {\n\t\tdiagnostics.push(...rejections);\n\t\tinvalidFkPairings.push({\n\t\t\tpairKey: fkRelationPairKey(model.modelName, relationField.targetModelName),\n\t\t\trelationName: effectiveRelationName(relationField.attribute, model.modelName, relationField.targetModelName)\n\t\t});\n\t};\n\tfor (const model of models.values()) for (const relationField of model.relationFields) {\n\t\tconst { field, targetModelName } = relationField;\n\t\tconst label = `Relation field \"${model.modelName}.${field.name}\"`;\n\t\tconst target = models.get(targetModelName);\n\t\tif (target === void 0) continue;\n\t\tif (isFkSide(relationField)) {\n\t\t\tconst attribute = relationField.attribute;\n\t\t\tif (attribute === void 0 || attribute.fields === void 0) continue;\n\t\t\tconst ignoredScalars = attribute.fields.filter((name) => model.ignoredFields.has(name));\n\t\t\tif (ignoredScalars.length > 0) {\n\t\t\t\trejectFkSide(model, relationField, ignoredFieldReferenced({\n\t\t\t\t\tmodelName: model.modelName,\n\t\t\t\t\tfieldNames: ignoredScalars,\n\t\t\t\t\tusedBy: `relation field \"${model.modelName}.${field.name}\"`,\n\t\t\t\t\tconstraint: \"foreign key\",\n\t\t\t\t\tsourceId: model.sourceId,\n\t\t\t\t\tspan: attribute.span\n\t\t\t\t}));\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tif (attribute.references === void 0) {\n\t\t\t\trejectFkSide(model, relationField, unresolved(label, \"declares fields without references.\", model.sourceId, attribute.span));\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tif (attribute.fields.some((name) => model.rejectedFields.has(name)) || attribute.references.some((name) => target.ignoredFields.has(name) || target.rejectedFields.has(name))) {\n\t\t\t\trejectFkSide(model, relationField);\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst localColumns = columnNames(model, attribute.fields);\n\t\t\tconst referencedColumns = columnNames(target, attribute.references);\n\t\t\tif (localColumns === void 0 || referencedColumns === void 0) {\n\t\t\t\trejectFkSide(model, relationField, unresolved(label, \"names a field that is not a scalar column of the model or its target.\", model.sourceId, attribute.span));\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tif (localColumns.length !== referencedColumns.length) {\n\t\t\t\trejectFkSide(model, relationField, unresolved(label, \"must list as many fields as references.\", model.sourceId, attribute.span));\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst nullability = attribute.fields.map((name) => model.columns.get(name)?.nullable === true);\n\t\t\tconst anyNullable = nullability.includes(true);\n\t\t\tif (anyNullable && !field.optional) {\n\t\t\t\trejectFkSide(model, relationField, unresolved(label, \"must be optional because one of its fields is optional.\", model.sourceId, field.span));\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst onDelete = attribute.onDelete ?? (nullability.includes(false) ? \"restrict\" : \"setNull\");\n\t\t\tconst onUpdate = attribute.onUpdate ?? \"cascade\";\n\t\t\tconst actionRejections = referentialActionRejections({\n\t\t\t\tmodel,\n\t\t\t\trelationField: field,\n\t\t\t\tlabel,\n\t\t\t\tfieldNames: attribute.fields,\n\t\t\t\tactions: {\n\t\t\t\t\tonDelete,\n\t\t\t\t\tonUpdate\n\t\t\t\t},\n\t\t\t\tspan: attribute.span\n\t\t\t});\n\t\t\tif (actionRejections.length > 0) {\n\t\t\t\trejectFkSide(model, relationField, ...actionRejections);\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\taddForeignKey(model.modelName, {\n\t\t\t\tcolumns: localColumns,\n\t\t\t\treferences: {\n\t\t\t\t\tmodel: target.modelName,\n\t\t\t\t\ttable: target.tableName,\n\t\t\t\t\tcolumns: referencedColumns,\n\t\t\t\t\tnamespaceId: target.namespaceId\n\t\t\t\t},\n\t\t\t\tonDelete,\n\t\t\t\tonUpdate,\n\t\t\t\tindex: false\n\t\t\t});\n\t\t\tfkRelationMetadata.push({\n\t\t\t\tdeclaringModelName: model.modelName,\n\t\t\t\tdeclaringFieldName: field.name,\n\t\t\t\tdeclaringTableName: model.tableName,\n\t\t\t\tdeclaringNamespaceId: model.namespaceId,\n\t\t\t\ttargetModelName: target.modelName,\n\t\t\t\ttargetTableName: target.tableName,\n\t\t\t\ttargetNamespaceId: target.namespaceId,\n\t\t\t\trelationName: effectiveRelationName(attribute, model.modelName, target.modelName),\n\t\t\t\tnullable: anyNullable,\n\t\t\t\tlocalColumns,\n\t\t\t\treferencedColumns\n\t\t\t});\n\t\t\tcontinue;\n\t\t}\n\t\tif (target.ignoredRelationFields.some((other) => other.targetModelName === model.modelName && sameName(other, relationField))) continue;\n\t\tif (target.relationFields.filter((other) => other.targetModelName === model.modelName && isFkSide(other) && sameName(other, relationField)).length > 0 || !field.list) {\n\t\t\tcandidates.push({\n\t\t\t\tmodelName: model.modelName,\n\t\t\t\ttableName: model.tableName,\n\t\t\t\tfield,\n\t\t\t\ttargetModelName: target.modelName,\n\t\t\t\tisList: field.list,\n\t\t\t\trelationName: effectiveRelationName(relationField.attribute, model.modelName, target.modelName)\n\t\t\t});\n\t\t\tcontinue;\n\t\t}\n\t\tconst partners = target.relationFields.filter((other) => other !== relationField && other.targetModelName === model.modelName && other.field.list && !isFkSide(other) && sameName(other, relationField));\n\t\tconst [partner] = partners;\n\t\tif (partner === void 0) {\n\t\t\tdiagnostics.push(unresolved(label, `has no matching relation field on \"${target.modelName}\".`, model.sourceId, field.span));\n\t\t\tcontinue;\n\t\t}\n\t\tif (partners.length > 1 || target === model && relationField.attribute?.name === void 0) {\n\t\t\tdiagnostics.push(unresolved(label, `is ambiguous: more than one list field on \"${target.modelName}\" could pair with it. Name both sides with @relation(\"name\").`, model.sourceId, field.span));\n\t\t\tcontinue;\n\t\t}\n\t\tconst junctionName = effectiveRelationName(relationField.attribute, model.modelName, target.modelName);\n\t\tconst requester = {\n\t\t\tmodel,\n\t\t\tfield: relationField\n\t\t};\n\t\tconst partnerSide = {\n\t\t\tmodel: target,\n\t\t\tfield: partner\n\t\t};\n\t\tconst junctionNamespaceId = orderJunctionSides(requester, partnerSide)[0].model.namespaceId;\n\t\tconst namesake = models.get(junctionName);\n\t\tif (namesake !== void 0 && namesake.namespaceId === junctionNamespaceId) {\n\t\t\tconst reportedKey = junctionKey(junctionNamespaceId, junctionName);\n\t\t\tif (!reportedJunctionNames.has(reportedKey)) {\n\t\t\t\treportedJunctionNames.add(reportedKey);\n\t\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_JUNCTION_NAME_COLLISION\", `${label} is an implicit many-to-many relation whose junction model would be named \"${junctionName}\", but model \"${junctionName}\" already has that name. Rename model \"${junctionName}\" and keep its table with @@map(\"${namesake.tableName}\"); Prisma 7's next migration is then empty.`, model.sourceId, field.span));\n\t\t\t}\n\t\t\tcontinue;\n\t\t}\n\t\tjunctionRequests.push({\n\t\t\trequester,\n\t\t\tpartner: partnerSide,\n\t\t\tname: junctionName\n\t\t});\n\t}\n\tconst requestsByJunction = groupBy(junctionRequests, (request) => junctionKey(orderJunctionSides(request.requester, request.partner)[0].model.namespaceId, request.name));\n\tfor (const requests of requestsByJunction.values()) {\n\t\tconst [first] = requests;\n\t\tif (first === void 0) continue;\n\t\tconst name = first.name;\n\t\tconst [sideA] = orderJunctionSides(first.requester, first.partner);\n\t\tconst tableName = prisma7ConstraintName(`_${name}`, \"\", naming.identifierMaxBytes);\n\t\tconst sideLabel = (side) => `${side.model.modelName}.${side.field.field.name}`;\n\t\tconst pairs = /* @__PURE__ */ new Map();\n\t\tfor (const request of requests) {\n\t\t\tconst key = [sideLabel(request.requester), sideLabel(request.partner)].sort().join(\"|\");\n\t\t\tif (!pairs.has(key)) pairs.set(key, request);\n\t\t}\n\t\tif (pairs.size > 1) {\n\t\t\tconst pairRequests = [...pairs.values()];\n\t\t\tfor (const request of pairRequests) {\n\t\t\t\tconst others = pairRequests.filter((other) => other !== request).map((other) => `\"${sideLabel(other.requester)}\"`);\n\t\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_RELATION_NAME_SHARED\", `Relation field \"${sideLabel(request.requester)}\" is an implicit many-to-many relation named \"${name}\", and so ${others.length === 1 ? \"is relation field\" : \"are relation fields\"} ${andList(others)}; Prisma 7 creates one table \"${tableName}\" for them, wired to only one of the relations (its foreign keys show which). Give each relation its own name with @relation(\"<name>\") on both fields: renaming a relation that \"${tableName}\" does not reference makes Prisma 7's next migration create its own table, while renaming the one it references moves \"${tableName}\"'s foreign keys to another relation, which fails on rows whose ids that relation's models lack and attaches the rest to the wrong records.`, request.requester.model.sourceId, request.requester.field.field.span));\n\t\t\t}\n\t\t\tcontinue;\n\t\t}\n\t\tconst tableOwner = [...models.values()].find((other) => other.tableName === tableName && other.namespaceId === sideA.model.namespaceId);\n\t\tif (tableOwner !== void 0) {\n\t\t\tconst relationField = `${first.requester.model.modelName}.${first.requester.field.field.name}`;\n\t\t\tconst message = `Model \"${tableOwner.modelName}\" and the implicit many-to-many relation \"${relationField}\" both use table \"${tableOwner.namespaceId}\".\"${tableName}\"; Prisma 7 creates the relation's table there and never creates the model's. Rename the model's table with @@map, which makes Prisma 7's next migration create it, or give the relation its own name with @relation(\"<name>\") on both fields, which makes Prisma 7's next migration rebuild \"${tableName}\" as the model's table and create an empty table for the relation, losing the relation's rows.`;\n\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_TABLE_COLLISION\", message, tableOwner.sourceId, tableOwner.tableSpan), prisma7Diagnostic(\"PSL.PRISMA7_TABLE_COLLISION\", message, first.requester.model.sourceId, first.requester.field.field.span));\n\t\t\tcontinue;\n\t\t}\n\t\tfor (const { requester, partner } of requests) {\n\t\t\tconst junction = synthesizeJunction(requester, partner, naming, diagnostics);\n\t\t\tif (junction === void 0) continue;\n\t\t\tif (!junctions.has(junction.key)) {\n\t\t\t\tjunctions.set(junction.key, junction.node);\n\t\t\t\tfkRelationMetadata.push(...junction.foreignKeys);\n\t\t\t}\n\t\t\tcandidates.push({\n\t\t\t\tmodelName: requester.model.modelName,\n\t\t\t\ttableName: requester.model.tableName,\n\t\t\t\tfield: requester.field.field,\n\t\t\t\ttargetModelName: partner.model.modelName,\n\t\t\t\tisList: true,\n\t\t\t\trelationName: junction.candidateRelationName\n\t\t\t});\n\t\t}\n\t}\n\tconst { modelRelations, fkRelationsByPair, fkRelationsByDeclaringModel } = indexFkRelations({ fkRelationMetadata });\n\tconst modelIdColumns = /* @__PURE__ */ new Map();\n\tconst modelUniqueColumnSets = /* @__PURE__ */ new Map();\n\tfor (const model of models.values()) {\n\t\tconst id = columnNames(model, model.idFields);\n\t\tif (id !== void 0 && id.length > 0) modelIdColumns.set(model.modelName, id);\n\t\tconst sets = [];\n\t\tif (id !== void 0 && id.length > 0) sets.push(id);\n\t\tfor (const unique of model.uniqueFieldSets) {\n\t\t\tconst columns = columnNames(model, unique);\n\t\t\tif (columns !== void 0) sets.push(columns);\n\t\t}\n\t\tmodelUniqueColumnSets.set(model.modelName, sets);\n\t}\n\tfor (const key of junctions.keys()) {\n\t\tmodelIdColumns.set(key, [\"A\", \"B\"]);\n\t\tmodelUniqueColumnSets.set(key, [[\"A\", \"B\"]]);\n\t}\n\tconst pairingDiagnostics = [];\n\tconst candidatesBySourceId = /* @__PURE__ */ new Map();\n\tfor (const candidate of candidates) {\n\t\tconst sourceId = models.get(candidate.modelName)?.sourceId ?? \"schema.prisma\";\n\t\tconst group = candidatesBySourceId.get(sourceId) ?? [];\n\t\tcandidatesBySourceId.set(sourceId, group);\n\t\tgroup.push(candidate);\n\t}\n\tfor (const [sourceId, backrelationCandidates] of candidatesBySourceId) applyBackrelationCandidates({\n\t\tbackrelationCandidates,\n\t\tfkRelationsByPair,\n\t\tinvalidFkPairings,\n\t\tfkRelationsByDeclaringModel,\n\t\tmodelIdColumns,\n\t\tmodelUniqueColumnSets,\n\t\tmodelRelations,\n\t\tdiagnostics: pairingDiagnostics,\n\t\tsourceId\n\t});\n\tfor (const diagnostic of pairingDiagnostics) diagnostics.push(RELATION_PAIRING_CODES.has(diagnostic.code) ? {\n\t\t...diagnostic,\n\t\tcode: \"PSL.PRISMA7_RELATION_UNRESOLVED\"\n\t} : diagnostic);\n\tconst relations = /* @__PURE__ */ new Map();\n\tfor (const [modelName, nodes] of modelRelations) relations.set(modelName, [...nodes].sort((left, right) => left.fieldName.localeCompare(right.fieldName)));\n\treturn {\n\t\tjunctions,\n\t\tforeignKeys,\n\t\trelations\n\t};\n}\n/**\n* The id column a junction side contributes. The diagnostic names the\n* requesting relation field, so it is located at that field, whichever side's\n* id is at fault.\n*/\nfunction singleIdColumn(side, requester, diagnostics) {\n\tif (side.model.idFields.some((name) => side.model.ignoredFields.has(name) || side.model.rejectedFields.has(name))) return;\n\tconst [idField, ...rest] = side.model.idFields;\n\tconst column = idField === void 0 ? void 0 : side.model.columns.get(idField);\n\tif (column === void 0 || rest.length > 0) {\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_JUNCTION_ID_UNSUPPORTED\", `Relation field \"${requester.model.modelName}.${requester.field.field.name}\" is an implicit many-to-many relation, but \"${side.model.modelName}\" ${column === void 0 ? \"has no single-field @id\" : \"has a composite id\"}; Prisma 7 requires a single-field @id on both models of an implicit many-to-many relation.`, requester.model.sourceId, requester.field.field.span));\n\t\treturn;\n\t}\n\treturn column;\n}\n/**\n* Prisma 7's implicit junction: table `_AToB` (or `_Name`), columns `A` and `B`\n* typed like the two ids, primary key `(A, B)`, index `_AToB_B_index`, and two\n* cascading foreign keys, with relation fields named as `contract infer` names\n* them. `A` is the model whose name is smaller in plain\n* string order; for a self-relation, the field whose name is smaller. This is\n* prisma-engines' rule (`psl/parser-database/src/relations.rs`,\n* `ingest_relation`: the side with the greater model name, or field name for a\n* self relation, is skipped so the smaller one owns `field_a`).\n*/\nfunction synthesizeJunction(requester, partner, naming, diagnostics) {\n\tconst [sideA, sideB] = orderJunctionSides(requester, partner);\n\tconst requesterFirst = sideA === requester;\n\tconst name = requester.field.attribute?.name ?? `${sideA.model.modelName}To${sideB.model.modelName}`;\n\tconst idA = singleIdColumn(sideA, requester, diagnostics);\n\tconst idB = singleIdColumn(sideB, requester, diagnostics);\n\tif (idA === void 0 || idB === void 0) return void 0;\n\tconst tableName = prisma7ConstraintName(`_${name}`, \"\", naming.identifierMaxBytes);\n\tconst namespaceId = sideA.model.namespaceId;\n\tconst key = junctionKey(namespaceId, name);\n\tconst [relationFieldA, relationFieldB] = naming.junctionRelationFieldNames(sideA.model.tableName, sideB.model.tableName);\n\tconst foreignKey = (column, side, id) => ({\n\t\tcolumns: [column],\n\t\treferences: {\n\t\t\tmodel: side.model.modelName,\n\t\t\ttable: side.model.tableName,\n\t\t\tcolumns: [id.columnName],\n\t\t\tnamespaceId: side.model.namespaceId\n\t\t},\n\t\tonDelete: \"cascade\",\n\t\tonUpdate: \"cascade\",\n\t\tindex: false\n\t});\n\tconst metadata = (column, side, id) => ({\n\t\tdeclaringModelName: key,\n\t\tdeclaringFieldName: column === \"A\" ? relationFieldA : relationFieldB,\n\t\tdeclaringTableName: tableName,\n\t\tdeclaringNamespaceId: namespaceId,\n\t\ttargetModelName: side.model.modelName,\n\t\ttargetTableName: side.model.tableName,\n\t\ttargetNamespaceId: side.model.namespaceId,\n\t\trelationName: `${name}:${column}`,\n\t\tnullable: false,\n\t\tlocalColumns: [column],\n\t\treferencedColumns: [id.columnName]\n\t});\n\tconst index = {\n\t\tcolumns: [\"B\"],\n\t\ttype: void 0,\n\t\toptions: void 0,\n\t\twhere: void 0,\n\t\tunique: void 0,\n\t\tmap: prisma7ConstraintName(`_${name}`, \"_B_index\", naming.identifierMaxBytes),\n\t\tname: void 0\n\t};\n\treturn {\n\t\tkey,\n\t\tnode: {\n\t\t\tmodelName: name,\n\t\t\ttableName,\n\t\t\tnamespaceId,\n\t\t\tfields: [{\n\t\t\t\tfieldName: \"A\",\n\t\t\t\tcolumnName: \"A\",\n\t\t\t\tdescriptor: idA.descriptor,\n\t\t\t\tnullable: false\n\t\t\t}, {\n\t\t\t\tfieldName: \"B\",\n\t\t\t\tcolumnName: \"B\",\n\t\t\t\tdescriptor: idB.descriptor,\n\t\t\t\tnullable: false\n\t\t\t}],\n\t\t\tid: { columns: [\"A\", \"B\"] },\n\t\t\tindexes: [index],\n\t\t\tforeignKeys: [foreignKey(\"A\", sideA, idA), foreignKey(\"B\", sideB, idB)]\n\t\t},\n\t\tforeignKeys: [metadata(\"A\", sideA, idA), metadata(\"B\", sideB, idB)],\n\t\tcandidateRelationName: requesterFirst ? `${name}:A` : `${name}:B`\n\t};\n}\n//#endregion\n//#region src/interpreter.ts\nconst SUMMARY = \"Prisma 7 schema interpretation failed\";\nconst EMPTY_DESCRIPTORS = /* @__PURE__ */ new Map();\nfunction attributeText(attribute) {\n\tconst args = attribute.args.map((arg) => arg.kind === \"named\" ? `${arg.name}: ${arg.value}` : arg.value);\n\treturn args.length === 0 ? `@${attribute.name}` : `@${attribute.name}(${args.join(\", \")})`;\n}\nfunction stringArgument(attribute) {\n\tconst expression = (attribute.args.find((arg) => arg.kind === \"positional\") ?? attribute.args.find((arg) => arg.name === \"name\"))?.expression;\n\tif (expression === void 0) return void 0;\n\treturn StringLiteralExprAst.cast(expression.syntax)?.value();\n}\nfunction scalarValue(block, key) {\n\tconst parameter = block.parameters[key];\n\tif (parameter?.kind !== \"value\") return void 0;\n\ttry {\n\t\tconst parsed = JSON.parse(parameter.raw);\n\t\treturn typeof parsed === \"string\" ? parsed : void 0;\n\t} catch {\n\t\treturn;\n\t}\n}\nfunction parameterSpan(block, key) {\n\tconst parameter = block.parameters[key];\n\treturn parameter === void 0 ? block.span : parameter.span;\n}\nfunction interpretPrisma7Documents(input) {\n\tconst { binding } = input;\n\tconst diagnostics = [...input.seedDiagnostics];\n\tconst defaultNamespaceId = binding.target.defaultNamespaceId;\n\tconst datasources = [];\n\tconst enumBlocks = [];\n\tconst models = [];\n\tconst ignoredModels = /* @__PURE__ */ new Set();\n\tconst declaredNames = /* @__PURE__ */ new Map();\n\tconst claimName = (kind, name, sourceId, span) => {\n\t\tconst previous = declaredNames.get(name);\n\t\tif (previous === void 0) {\n\t\t\tdeclaredNames.set(name, sourceId);\n\t\t\treturn true;\n\t\t}\n\t\tdiagnostics.push({\n\t\t\tcode: \"PSL_DUPLICATE_DECLARATION\",\n\t\t\tmessage: `Duplicate declaration of ${kind} \"${name}\"; first declared in ${basename(previous)}.`,\n\t\t\tsourceId,\n\t\t\tspan\n\t\t});\n\t\treturn false;\n\t};\n\tfor (const { document, sourceFile, sourceId } of input.documents) {\n\t\tconst { table, diagnostics: tableDiagnostics } = buildSymbolTable({\n\t\t\tdocument,\n\t\t\tsourceFile,\n\t\t\tpslBlockDescriptors: {}\n\t\t});\n\t\tfor (const diagnostic of tableDiagnostics) diagnostics.push({\n\t\t\tcode: diagnostic.code,\n\t\t\tmessage: diagnostic.message,\n\t\t\tsourceId,\n\t\t\tspan: rangeToPslSpan(diagnostic.range, sourceFile)\n\t\t});\n\t\tconst unsupported = (keyword, span) => {\n\t\t\tdiagnostics.push({\n\t\t\t\tcode: \"PSL_UNSUPPORTED_TOP_LEVEL_BLOCK\",\n\t\t\t\tmessage: `Unsupported top-level block \"${keyword}\"`,\n\t\t\t\tsourceId,\n\t\t\t\tspan\n\t\t\t});\n\t\t};\n\t\tfor (const block of Object.values(table.topLevel.blocks)) switch (block.keyword) {\n\t\t\tcase \"datasource\":\n\t\t\t\tdatasources.push({\n\t\t\t\t\tblock,\n\t\t\t\t\tsourceId,\n\t\t\t\t\tsourceFile\n\t\t\t\t});\n\t\t\t\tbreak;\n\t\t\tcase \"generator\": break;\n\t\t\tcase \"enum\":\n\t\t\t\tif (claimName(\"enum\", block.name, sourceId, block.span)) enumBlocks.push({\n\t\t\t\t\tblock,\n\t\t\t\t\tsourceId,\n\t\t\t\t\tsourceFile\n\t\t\t\t});\n\t\t\t\tbreak;\n\t\t\tcase \"view\":\n\t\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_VIEW_UNSUPPORTED\", `View \"${block.name}\" is not supported; Prisma 8 has no views. Remove the view or replace it with a model over the underlying table.`, sourceId, keywordPslSpan(block.node.syntax, block.keyword, sourceFile)));\n\t\t\t\tbreak;\n\t\t\tdefault: unsupported(block.keyword, keywordPslSpan(block.node.syntax, block.keyword, sourceFile));\n\t\t}\n\t\tfor (const namespace of Object.values(table.topLevel.namespaces)) unsupported(\"namespace\", namespace.span);\n\t\tfor (const compositeType of Object.values(table.topLevel.compositeTypes)) unsupported(\"type\", compositeType.span);\n\t\tfor (const namedType of Object.values(table.topLevel.namedTypes)) unsupported(\"types\", namedType.span);\n\t\tfor (const symbol of Object.values(table.topLevel.models)) {\n\t\t\tif (!claimName(\"model\", symbol.name, sourceId, symbol.span)) continue;\n\t\t\tconst declaration = readModelDeclaration(symbol, sourceId, defaultNamespaceId, binding.indexTypes, diagnostics);\n\t\t\tif (declaration === void 0) ignoredModels.add(symbol.name);\n\t\t\telse models.push(declaration);\n\t\t}\n\t}\n\tcheckDatasource(datasources, input.documents[0]?.sourceId ?? \"schema.prisma\", binding, diagnostics);\n\treportTableCollisions(models, diagnostics);\n\tconst enums = /* @__PURE__ */ new Map();\n\tfor (const source of enumBlocks) {\n\t\tconst declaration = readEnumDeclaration(source, defaultNamespaceId, diagnostics);\n\t\tif (declaration !== void 0) enums.set(declaration.name, declaration);\n\t}\n\tconst namespaceEntities = lowerNativeEnums(enums, input, diagnostics);\n\tconst modelNames = /* @__PURE__ */ new Set([...models.map((model) => model.symbol.name), ...ignoredModels]);\n\tconst scalarColumnDescriptors = collectScalarTypeConstructors(input.authoringContributions.type);\n\tconst composedExtensions = new Set(input.composedExtensions);\n\tconst builds = /* @__PURE__ */ new Map();\n\tfor (const declaration of models) {\n\t\tconst build = {\n\t\t\tdeclaration,\n\t\t\tcolumns: /* @__PURE__ */ new Map(),\n\t\t\tignoredFields: /* @__PURE__ */ new Set(),\n\t\t\tignoredRelationFields: [],\n\t\t\trejectedFields: /* @__PURE__ */ new Set(),\n\t\t\tidFields: declaration.id?.fields ?? [],\n\t\t\tuniqueIndexes: [...declaration.uniqueIndexes],\n\t\t\trelationFields: []\n\t\t};\n\t\tfor (const field of Object.values(declaration.symbol.fields)) {\n\t\t\tconst reported = diagnostics.length;\n\t\t\treadField({\n\t\t\t\tfield,\n\t\t\t\tbuild,\n\t\t\t\tmodelNames,\n\t\t\t\tignoredModels,\n\t\t\t\tenums,\n\t\t\t\tnamespaceEntities,\n\t\t\t\tscalarColumnDescriptors,\n\t\t\t\tcomposedExtensions,\n\t\t\t\tinput,\n\t\t\t\tdiagnostics\n\t\t\t});\n\t\t\tif (diagnostics.length > reported && !build.columns.has(field.name) && !build.ignoredFields.has(field.name)) build.rejectedFields.add(field.name);\n\t\t}\n\t\tbuilds.set(declaration.symbol.name, build);\n\t}\n\tconst relationModels = /* @__PURE__ */ new Map();\n\tfor (const [modelName, build] of builds) relationModels.set(modelName, {\n\t\tmodelName,\n\t\ttableName: build.declaration.tableName,\n\t\ttableSpan: build.declaration.symbol.attributes.find((attribute) => attribute.name === \"map\")?.span ?? build.declaration.symbol.span,\n\t\tnamespaceId: build.declaration.namespaceId,\n\t\tsourceId: build.declaration.sourceId,\n\t\tcolumns: build.columns,\n\t\tignoredFields: build.ignoredFields,\n\t\tignoredRelationFields: build.ignoredRelationFields,\n\t\trejectedFields: build.rejectedFields,\n\t\tidFields: build.idFields,\n\t\tuniqueFieldSets: build.uniqueIndexes.flatMap((index) => index.fields === void 0 ? [] : [index.fields]),\n\t\trelationFields: build.relationFields\n\t});\n\tconst lowered = lowerRelations(relationModels, binding, diagnostics);\n\tconst modelNodes = [];\n\tfor (const [modelName, build] of builds) {\n\t\tconst model = relationModels.get(modelName);\n\t\tif (model === void 0) continue;\n\t\tconst ignoredAmong = (fieldNames) => fieldNames?.filter((name) => build.ignoredFields.has(name)) ?? [];\n\t\tconst idAttribute = build.declaration.id;\n\t\tconst ignoredIdFields = ignoredAmong(idAttribute?.fields);\n\t\tif (idAttribute !== void 0 && ignoredIdFields.length > 0) diagnostics.push(ignoredFieldReferenced({\n\t\t\tmodelName,\n\t\t\tfieldNames: ignoredIdFields,\n\t\t\tusedBy: `@@id on model \"${modelName}\"`,\n\t\t\tconstraint: \"primary key\",\n\t\t\tsourceId: model.sourceId,\n\t\t\tspan: idAttribute.span\n\t\t}));\n\t\tconst id = keyColumns(model, model.idFields);\n\t\tconst indexes = [...build.uniqueIndexes.map((attribute) => ({\n\t\t\tattribute,\n\t\t\tunique: true\n\t\t})), ...build.declaration.indexes.map((attribute) => ({\n\t\t\tattribute,\n\t\t\tunique: false\n\t\t}))].flatMap(({ attribute, unique }) => {\n\t\t\tconst ignoredIndexFields = ignoredAmong(attribute.fields);\n\t\t\tif (ignoredIndexFields.length > 0) {\n\t\t\t\tdiagnostics.push(ignoredFieldReferenced({\n\t\t\t\t\tmodelName,\n\t\t\t\t\tfieldNames: ignoredIndexFields,\n\t\t\t\t\tusedBy: `${unique ? \"@@unique\" : \"@@index\"} on model \"${modelName}\"`,\n\t\t\t\t\tconstraint: unique ? \"unique index\" : \"index\",\n\t\t\t\t\tsourceId: model.sourceId,\n\t\t\t\t\tspan: attribute.span\n\t\t\t\t}));\n\t\t\t\treturn [];\n\t\t\t}\n\t\t\tif (attribute.fields?.some((name) => build.rejectedFields.has(name))) return [];\n\t\t\tconst columns = attribute.fields === void 0 ? void 0 : keyColumns(model, attribute.fields);\n\t\t\tif (columns === void 0) {\n\t\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_INDEX_ARGUMENT_UNSUPPORTED\", `Model \"${modelName}\": an index names a field that is not a scalar column of the model.`, model.sourceId, attribute.span));\n\t\t\t\treturn [];\n\t\t\t}\n\t\t\treturn [indexNode(model.tableName, columns, attribute, unique, binding.identifierMaxBytes)];\n\t\t});\n\t\tconst foreignKeys = lowered.foreignKeys.get(modelName);\n\t\tconst relations = lowered.relations.get(modelName);\n\t\tmodelNodes.push({\n\t\t\tmodelName,\n\t\t\ttableName: model.tableName,\n\t\t\tnamespaceId: model.namespaceId,\n\t\t\tfields: [...build.columns.values()],\n\t\t\t...id !== void 0 && id.length > 0 ? { id: { columns: id } } : {},\n\t\t\t...indexes.length > 0 ? { indexes } : {},\n\t\t\t...foreignKeys !== void 0 ? { foreignKeys } : {},\n\t\t\t...relations !== void 0 ? { relations } : {}\n\t\t});\n\t}\n\tfor (const [key, junction] of lowered.junctions) {\n\t\tconst relations = lowered.relations.get(key);\n\t\tmodelNodes.push(relations === void 0 ? junction : {\n\t\t\t...junction,\n\t\t\trelations\n\t\t});\n\t}\n\tif (diagnostics.length > 0) return notOk({\n\t\tsummary: SUMMARY,\n\t\tdiagnostics\n\t});\n\tconst createNamespace = (namespace) => {\n\t\tconst entities = namespaceEntities.get(namespace.id);\n\t\tif (entities === void 0) return binding.createNamespace(namespace);\n\t\tconst valueSet = {\n\t\t\t...namespace.entries[\"valueSet\"],\n\t\t\t...entities[\"valueSet\"]\n\t\t};\n\t\treturn binding.createNamespace({\n\t\t\t...namespace,\n\t\t\tentries: {\n\t\t\t\t...namespace.entries,\n\t\t\t\t...entities,\n\t\t\t\t...Object.keys(valueSet).length > 0 ? { valueSet } : {}\n\t\t\t}\n\t\t});\n\t};\n\treturn ok(buildSqlContractFromDefinition({\n\t\ttarget: binding.target,\n\t\twarnings: void 0,\n\t\tcreateNamespace,\n\t\t...namespaceEntities.size > 0 ? { namespaces: [...namespaceEntities.keys()] } : {},\n\t\tmodels: modelNodes\n\t}, input.codecLookup));\n}\nfunction checkDatasource(datasources, fallbackSourceId, binding, diagnostics) {\n\tconst [datasource] = datasources;\n\tconst [namedProvider] = binding.providers;\n\tif (datasource === void 0) {\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_PROVIDER_MISMATCH\", `No datasource block found; add \\`datasource db { provider = \"${namedProvider}\" }\\`.`, fallbackSourceId, void 0));\n\t\treturn;\n\t}\n\tconst block = datasource.block.block;\n\tconst provider = scalarValue(block, \"provider\");\n\tif (provider === void 0 || !binding.providers.includes(provider)) diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_PROVIDER_MISMATCH\", provider === void 0 ? `The datasource block declares no string \\`provider\\`; this contract source reads Prisma 7 schemas for provider \"${namedProvider}\".` : `The datasource provider is \"${provider}\"; this contract source reads Prisma 7 schemas for provider \"${namedProvider}\".`, datasource.sourceId, parameterSpan(block, \"provider\")));\n\tfor (const [property, edit] of Object.entries({\n\t\trelationMode: \"Removing relationMode, or setting it to \\\"foreignKeys\\\"\",\n\t\treferentialIntegrity: \"Removing referentialIntegrity, or replacing it with relationMode = \\\"foreignKeys\\\"\"\n\t})) {\n\t\tif (scalarValue(block, property) !== \"prisma\") continue;\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_RELATION_MODE_UNSUPPORTED\", `${property} = \"prisma\" is not supported: the contract declares the foreign keys its relations need, and in this mode Prisma 7 creates none. ${edit}, makes Prisma 7's next migration add those foreign keys, and that migration fails if any existing row breaks one.`, datasource.sourceId, parameterSpan(block, property)));\n\t}\n}\nfunction reportTableCollisions(models, diagnostics) {\n\tconst byTable = /* @__PURE__ */ new Map();\n\tfor (const model of models) {\n\t\tconst key = `${model.namespaceId}.${model.tableName}`;\n\t\tconst group = byTable.get(key) ?? [];\n\t\tbyTable.set(key, group);\n\t\tgroup.push(model);\n\t}\n\tfor (const group of byTable.values()) {\n\t\tif (group.length < 2) continue;\n\t\tconst names = group.map((model) => `\"${model.symbol.name}\"`).join(\", \");\n\t\tfor (const model of group) {\n\t\t\tconst mapAttribute = model.symbol.attributes.find((attribute) => attribute.name === \"map\");\n\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_TABLE_COLLISION\", `Models ${names} all map to table \"${model.namespaceId}\".\"${model.tableName}\"; each model needs its own table.`, model.sourceId, mapAttribute?.span ?? model.symbol.span));\n\t\t}\n\t}\n}\nfunction keyColumns(model, fieldNames) {\n\tconst columns = [];\n\tfor (const fieldName of fieldNames) {\n\t\tconst column = model.columns.get(fieldName);\n\t\tif (column === void 0) return void 0;\n\t\tcolumns.push(column.columnName);\n\t}\n\treturn columns;\n}\nfunction readModelDeclaration(symbol, sourceId, defaultNamespaceId, indexTypes, diagnostics) {\n\tif (symbol.attributes.some((attribute) => attribute.name === \"ignore\")) return void 0;\n\tlet tableName = symbol.name;\n\tlet namespaceId = defaultNamespaceId;\n\tlet id;\n\tconst uniqueIndexes = [];\n\tconst indexes = [];\n\tfor (const attribute of symbol.attributes) switch (attribute.name) {\n\t\tcase \"map\":\n\t\t\ttableName = requireStringArgument(attribute, symbol.name, sourceId, diagnostics) ?? tableName;\n\t\t\tbreak;\n\t\tcase \"schema\":\n\t\t\tnamespaceId = requireStringArgument(attribute, symbol.name, sourceId, diagnostics) ?? namespaceId;\n\t\t\tbreak;\n\t\tcase \"id\": {\n\t\t\tconst parsed = parseIndexAttribute(attribute, symbol.name, sourceId, indexTypes, diagnostics);\n\t\t\tif (parsed?.fields !== void 0) id = parsed;\n\t\t\tbreak;\n\t\t}\n\t\tcase \"unique\": {\n\t\t\tconst parsed = parseIndexAttribute(attribute, symbol.name, sourceId, indexTypes, diagnostics);\n\t\t\tif (parsed?.fields !== void 0) uniqueIndexes.push(parsed);\n\t\t\tbreak;\n\t\t}\n\t\tcase \"index\": {\n\t\t\tconst parsed = parseIndexAttribute(attribute, symbol.name, sourceId, indexTypes, diagnostics);\n\t\t\tif (parsed?.fields !== void 0) indexes.push(parsed);\n\t\t\tbreak;\n\t\t}\n\t\tdefault: diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_ATTRIBUTE\", `Model \"${symbol.name}\": attribute \"@@${attribute.name}\" is not supported yet by the Prisma 7 contract source.`, sourceId, attribute.span));\n\t}\n\treturn {\n\t\tsymbol,\n\t\tsourceId,\n\t\tnamespaceId,\n\t\ttableName,\n\t\tid,\n\t\tuniqueIndexes,\n\t\tindexes\n\t};\n}\nfunction requireStringArgument(attribute, owner, sourceId, diagnostics) {\n\tconst value = stringArgument(attribute);\n\tif (value === void 0) diagnostics.push({\n\t\tcode: \"PSL_INVALID_ATTRIBUTE_ARGUMENT\",\n\t\tmessage: `\"${owner}\": attribute \"${attribute.name}\" expects one string argument.`,\n\t\tsourceId,\n\t\tspan: attribute.span\n\t});\n\treturn value;\n}\nfunction readEnumDeclaration(source, defaultNamespaceId, diagnostics) {\n\tconst { block, sourceId, sourceFile } = source;\n\tlet typeName = block.name;\n\tlet namespaceId = defaultNamespaceId;\n\tfor (const attribute of readResolvedAttributes(block.node.attributes(), sourceFile)) switch (attribute.name) {\n\t\tcase \"map\":\n\t\t\ttypeName = requireStringArgument(attribute, block.name, sourceId, diagnostics) ?? typeName;\n\t\t\tbreak;\n\t\tcase \"schema\":\n\t\t\tnamespaceId = requireStringArgument(attribute, block.name, sourceId, diagnostics) ?? namespaceId;\n\t\t\tbreak;\n\t\tdefault: diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_ATTRIBUTE\", `Enum \"${block.name}\": attribute \"@@${attribute.name}\" is not supported by the Prisma 7 contract source.`, sourceId, attribute.span));\n\t}\n\tconst members = [];\n\tfor (const entry of block.node.entries()) {\n\t\tconst name = entry.key()?.name();\n\t\tif (name === void 0) continue;\n\t\tlet value = name;\n\t\tconst span = nodePslSpan(entry.syntax, sourceFile);\n\t\tfor (const attributeNode of entry.attributes()) {\n\t\t\tconst attribute = readResolvedAttribute(attributeNode, sourceFile);\n\t\t\tif (attribute.name === \"map\") value = requireStringArgument(attribute, `${block.name}.${name}`, sourceId, diagnostics) ?? value;\n\t\t\telse diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_ATTRIBUTE\", `Enum member \"${block.name}.${name}\": attribute \"@${attribute.name}\" is not supported by the Prisma 7 contract source.`, sourceId, attribute.span));\n\t\t}\n\t\tmembers.push({\n\t\t\tname,\n\t\t\tvalue,\n\t\t\tspan\n\t\t});\n\t}\n\treturn {\n\t\tname: block.name,\n\t\ttypeName,\n\t\tnamespaceId,\n\t\tmembers,\n\t\tspan: block.span,\n\t\tsourceId\n\t};\n}\nfunction lowerNativeEnums(enums, input, diagnostics) {\n\tconst result = /* @__PURE__ */ new Map();\n\tif (enums.size === 0) return result;\n\tconst { entityKind } = input.binding.nativeEnum;\n\tconst descriptor = buildEntityTypesByDiscriminator(input.authoringContributions).get(entityKind);\n\tfor (const declaration of enums.values()) {\n\t\tif (descriptor === void 0) {\n\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNSUPPORTED_TYPE\", `Enum \"${declaration.name}\" cannot be lowered: target \"${input.binding.target.targetId}\" registers no \"${entityKind}\" entity kind.`, declaration.sourceId, declaration.span));\n\t\t\tcontinue;\n\t\t}\n\t\tconst context = {\n\t\t\tfamily: input.binding.target.familyId,\n\t\t\ttarget: input.binding.target.targetId,\n\t\t\tcodecLookup: input.codecLookup,\n\t\t\tsourceId: declaration.sourceId,\n\t\t\tdiagnostics: { push: (diagnostic) => {\n\t\t\t\tdiagnostics.push(blindCast(diagnostic));\n\t\t\t} }\n\t\t};\n\t\tconst entity = instantiateAuthoringEntityType(entityKind, descriptor, [{\n\t\t\tkind: entityKind,\n\t\t\tkeyword: entityKind,\n\t\t\tname: declaration.name,\n\t\t\tparameters: Object.fromEntries(declaration.members.map((member) => [member.name, {\n\t\t\t\tkind: \"value\",\n\t\t\t\traw: JSON.stringify(member.value),\n\t\t\t\tspan: member.span\n\t\t\t}])),\n\t\t\tblockAttributes: [],\n\t\t\tattributes: { map: {\n\t\t\t\targs: { name: declaration.typeName },\n\t\t\t\tspan: declaration.span\n\t\t\t} },\n\t\t\tspan: declaration.span,\n\t\t\tnamespaceId: declaration.namespaceId\n\t\t}], context);\n\t\tif (entity === void 0) continue;\n\t\tconst entities = result.get(declaration.namespaceId) ?? {};\n\t\tresult.set(declaration.namespaceId, entities);\n\t\tentities[entityKind] = {\n\t\t\t...entities[entityKind],\n\t\t\t[declaration.name]: entity\n\t\t};\n\t\tconst valueSet = deriveValueSetFromEntity(descriptor.output, entity);\n\t\tif (valueSet !== void 0) entities[\"valueSet\"] = {\n\t\t\t...entities[\"valueSet\"],\n\t\t\t[declaration.name]: valueSet\n\t\t};\n\t}\n\treturn result;\n}\nfunction keysUsingField(field, model) {\n\tconst modelName = model.symbol.name;\n\tconst uses = [];\n\tfor (const attribute of field.attributes) {\n\t\tif (attribute.name === \"id\") uses.push({\n\t\t\tusedBy: \"its @id\",\n\t\t\tconstraint: \"primary key\"\n\t\t});\n\t\tif (attribute.name === \"unique\") uses.push({\n\t\t\tusedBy: \"its @unique\",\n\t\t\tconstraint: \"unique index\"\n\t\t});\n\t}\n\tif (model.id?.fields?.includes(field.name)) uses.push({\n\t\tusedBy: `@@id on model \"${modelName}\"`,\n\t\tconstraint: \"primary key\"\n\t});\n\tfor (const unique of model.uniqueIndexes) if (unique.fields?.includes(field.name)) uses.push({\n\t\tusedBy: `@@unique on model \"${modelName}\"`,\n\t\tconstraint: \"unique index\"\n\t});\n\tfor (const index of model.indexes) if (index.fields?.includes(field.name)) uses.push({\n\t\tusedBy: `@@index on model \"${modelName}\"`,\n\t\tconstraint: \"index\"\n\t});\n\tfor (const other of Object.values(model.symbol.fields)) {\n\t\tif (other.attributes.some((attribute) => attribute.name === \"ignore\")) continue;\n\t\tconst relation = other.attributes.find((attribute) => attribute.name === \"relation\");\n\t\tif ((relation === void 0 ? void 0 : parseRelationAttribute(relation, other.name, model.sourceId, []))?.fields?.includes(field.name)) uses.push({\n\t\t\tusedBy: `relation field \"${modelName}.${other.name}\"`,\n\t\t\tconstraint: \"foreign key\"\n\t\t});\n\t}\n\treturn uses;\n}\nfunction nativeTypeMessage(input) {\n\tconst { label, nativeType, field, model } = input;\n\tconst uses = keysUsingField(field, model);\n\tif (uses.length > 0) {\n\t\tconst constraints = [...new Set(uses.map((use) => `the ${use.constraint}`))];\n\t\treturn `${label}: native type \"@db.${nativeType}\" has no Prisma 8 codec, and ${andList(uses.map((use) => use.usedBy))} ${uses.length === 1 ? \"uses\" : \"use\"} the field, so @ignore on the field does not help: Prisma 7 still creates ${andList(constraints)} over the column. Add @@ignore to model \"${model.symbol.name}\" to keep the model out of the contract: Prisma 7's next migration is empty, but the model disappears from the Prisma 7 client too, and every relation field in another model that points to it needs @ignore, which removes that field from the Prisma 7 client as well. Changing the field's type instead changes the column type on Prisma 7's next migration.`;\n\t}\n\treturn `${label}: native type \"@db.${nativeType}\" has no Prisma 8 codec. Add @ignore to the field to keep its column out of the contract: Prisma 7's next migration is empty, and the field disappears from the Prisma 7 client too${!field.optional && !field.list && !givesColumnDefault(input.defaultAttribute) ? \"; because the field is required and its column has no default, neither client can then insert rows\" : \"\"}. Changing the field's type instead changes the column type on Prisma 7's next migration.`;\n}\nfunction readIgnoredField(field, isRelationField, args) {\n\tconst { build, diagnostics } = args;\n\tconst model = build.declaration;\n\tif (isRelationField) {\n\t\tif (args.ignoredModels.has(field.typeName)) return;\n\t\tconst relation = field.attributes.find((attribute) => attribute.name === \"relation\");\n\t\tbuild.ignoredRelationFields.push({\n\t\t\tfield,\n\t\t\ttargetModelName: field.typeName,\n\t\t\tattribute: relation === void 0 ? void 0 : parseRelationAttribute(relation, field.name, model.sourceId, [])\n\t\t});\n\t\treturn;\n\t}\n\tfor (const attribute of field.attributes) {\n\t\tif (attribute.name !== \"id\" && attribute.name !== \"unique\") continue;\n\t\tif (attribute.name === \"id\") build.idFields = [field.name];\n\t\tdiagnostics.push(ignoredFieldReferenced({\n\t\t\tmodelName: model.symbol.name,\n\t\t\tfieldNames: [field.name],\n\t\t\tusedBy: `its @${attribute.name}`,\n\t\t\tconstraint: attribute.name === \"id\" ? \"primary key\" : \"unique index\",\n\t\t\tsourceId: model.sourceId,\n\t\t\tspan: attribute.span\n\t\t}));\n\t}\n}\nfunction readField(args) {\n\tconst { field, build, diagnostics, input } = args;\n\tconst { binding } = input;\n\tconst model = build.declaration;\n\tconst sourceId = model.sourceId;\n\tconst label = `Field \"${model.symbol.name}.${field.name}\"`;\n\tconst isRelationField = args.modelNames.has(field.typeName) && field.typeConstructor === void 0;\n\tif (field.attributes.some((attribute) => attribute.name === \"ignore\")) {\n\t\tbuild.ignoredFields.add(field.name);\n\t\treadIgnoredField(field, isRelationField, args);\n\t\treturn;\n\t}\n\tlet columnName = field.name;\n\tlet nativeType;\n\tlet relation;\n\tlet defaultAttribute;\n\tlet updatedAt;\n\tfor (const attribute of field.attributes) if (attribute.name === \"map\" && !isRelationField) columnName = requireStringArgument(attribute, label, sourceId, diagnostics) ?? columnName;\n\telse if (attribute.name.startsWith(\"db.\") && !isRelationField) nativeType = {\n\t\tname: attribute.name.slice(3),\n\t\tattribute\n\t};\n\telse if (attribute.name === \"id\" && !isRelationField) {\n\t\tif (parseIndexAttribute(attribute, label, sourceId, binding.indexTypes, diagnostics) !== void 0) build.idFields = [field.name];\n\t} else if (attribute.name === \"unique\" && !isRelationField) {\n\t\tconst parsed = parseIndexAttribute(attribute, label, sourceId, binding.indexTypes, diagnostics);\n\t\tif (parsed !== void 0) build.uniqueIndexes.push({\n\t\t\t...parsed,\n\t\t\tfields: [field.name]\n\t\t});\n\t} else if (attribute.name === \"default\" && !isRelationField) defaultAttribute = attribute;\n\telse if (attribute.name === \"updatedAt\" && !isRelationField) updatedAt = attribute;\n\telse if (attribute.name === \"relation\" && isRelationField) relation = attribute;\n\telse diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_ATTRIBUTE\", `${label}: attribute \"@${attribute.name}\" is not supported yet by the Prisma 7 contract source.`, sourceId, attribute.span));\n\tif (field.malformedType) return;\n\tif (field.typeConstructor !== void 0) {\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNSUPPORTED_TYPE\", `${label} has type \"${field.typeConstructor.path.join(\".\")}(...)\", which has no Prisma 8 codec, so model \"${model.symbol.name}\" cannot use this contract source while it has the field. Prisma 7 rejects @ignore on an Unsupported field, and removing the field drops its column on Prisma 7's next migration. Adding @@ignore to model \"${model.symbol.name}\" keeps the model out of the contract: Prisma 7's next migration is empty, but the model disappears from the Prisma 7 client too, and every relation field in another model that points to it needs @ignore, which removes that field from the Prisma 7 client as well.`, sourceId, field.typeConstructor.span));\n\t\treturn;\n\t}\n\tif (args.ignoredModels.has(field.typeName)) return;\n\tif (isRelationField) {\n\t\tconst attribute = relation === void 0 ? void 0 : parseRelationAttribute(relation, label, sourceId, diagnostics);\n\t\tif (relation !== void 0 && attribute === void 0) return;\n\t\tbuild.relationFields.push({\n\t\t\tfield,\n\t\t\ttargetModelName: field.typeName,\n\t\t\tattribute\n\t\t});\n\t\treturn;\n\t}\n\tconst enumDeclaration = args.enums.get(field.typeName);\n\tlet call;\n\tif (enumDeclaration !== void 0) {\n\t\tif (enumDeclaration.namespaceId !== model.namespaceId) {\n\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_ENUM_NAMESPACE_MISMATCH\", `${label} uses enum \"${enumDeclaration.name}\" from schema \"${enumDeclaration.namespaceId}\", but the model is in schema \"${model.namespaceId}\". Prisma 8 columns reference the enum type of their own schema; declare the enum in \"${model.namespaceId}\" or move the model.`, sourceId, field.span));\n\t\t\treturn;\n\t\t}\n\t\tcall = {\n\t\t\tpath: binding.nativeEnum.typeConstructor,\n\t\t\targs: [{\n\t\t\t\tkind: \"positional\",\n\t\t\t\tvalue: enumDeclaration.name,\n\t\t\t\tspan: field.span\n\t\t\t}],\n\t\t\tspan: field.span\n\t\t};\n\t} else {\n\t\tconst scalar = prisma7ScalarMapping(binding.typeMap, field.typeName);\n\t\tif (scalar === void 0) {\n\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNSUPPORTED_TYPE\", `${label} has unknown type \"${field.typeName}\".`, sourceId, field.span));\n\t\t\treturn;\n\t\t}\n\t\tlet mapping = scalar;\n\t\tlet span = field.span;\n\t\tif (nativeType !== void 0) {\n\t\t\tconst native = prisma7NativeTypeMapping(binding.typeMap, nativeType.name, nativeType.attribute.args.map((arg) => arg.value));\n\t\t\tif (native === void 0) {\n\t\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_NATIVE_TYPE_UNSUPPORTED\", nativeTypeMessage({\n\t\t\t\t\tlabel,\n\t\t\t\t\tnativeType: nativeType.name,\n\t\t\t\t\tfield,\n\t\t\t\t\tmodel,\n\t\t\t\t\tdefaultAttribute\n\t\t\t\t}), sourceId, nativeType.attribute.span));\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tmapping = native;\n\t\t\tspan = nativeType.attribute.span;\n\t\t}\n\t\tcall = {\n\t\t\tpath: [mapping.constructorName],\n\t\t\targs: mapping.args.map((value) => ({\n\t\t\t\tkind: \"positional\",\n\t\t\t\tvalue,\n\t\t\t\tspan\n\t\t\t})),\n\t\t\tspan\n\t\t};\n\t}\n\tconst namespaceExtensionEntities = args.namespaceEntities.get(model.namespaceId);\n\tconst resolved = resolveFieldTypeDescriptor({\n\t\tfield: {\n\t\t\t...field,\n\t\t\ttypeConstructor: call\n\t\t},\n\t\tenumTypeDescriptors: EMPTY_DESCRIPTORS,\n\t\tnamedTypeDescriptors: EMPTY_DESCRIPTORS,\n\t\tscalarColumnDescriptors: args.scalarColumnDescriptors,\n\t\tauthoringContributions: input.authoringContributions,\n\t\tcomposedExtensions: args.composedExtensions,\n\t\tfamilyId: binding.target.familyId,\n\t\ttargetId: binding.target.targetId,\n\t\tdiagnostics,\n\t\tsourceId,\n\t\tentityLabel: label,\n\t\tnamespaceId: model.namespaceId,\n\t\t...ifDefined(\"namespaceExtensionEntities\", namespaceExtensionEntities),\n\t\tcodecLookup: input.codecLookup\n\t});\n\tif (!resolved.ok) {\n\t\tif (!resolved.alreadyReported) diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNSUPPORTED_TYPE\", `${label} type \"${field.typeName}\" could not be resolved against target \"${binding.target.targetId}\".`, sourceId, field.span));\n\t\treturn;\n\t}\n\tconst updatedAtGeneratorId = updatedAt === void 0 ? void 0 : binding.updatedAtGeneratorId(resolved.descriptor.codecId);\n\tif (updatedAt !== void 0 && updatedAtGeneratorId === void 0) {\n\t\tconst withoutUpdatedAt = defaultAttribute !== void 0 && givesColumnDefault(defaultAttribute) ? `. Its ${attributeText(defaultAttribute)} still sets the value on create, and neither client changes it on update.` : field.optional ? \", but neither client then fills the value, so it stays empty unless a client writes it, and updates leave it unchanged.\" : \", but neither client then fills the value, so both require it on create and leave it unchanged on update.\";\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UPDATED_AT_TYPE_UNSUPPORTED\", `${label}: @updatedAt is not supported on this column, because Prisma 8 has no generator for column type \"${resolved.descriptor.nativeType}\" yet. Remove @updatedAt: Prisma 7's next migration is empty${withoutUpdatedAt}`, sourceId, updatedAt.span));\n\t\treturn;\n\t}\n\tif (updatedAt !== void 0 && defaultAttribute !== void 0) {\n\t\tconst written = attributeText(defaultAttribute);\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UPDATED_AT_WITH_DEFAULT_UNSUPPORTED\", `${label} combines @updatedAt with ${written}, which Prisma 8 cannot express yet. Remove ${written}: @updatedAt still sets the value on create and on update, and Prisma 7's next migration removes the column default.`, sourceId, defaultAttribute.span));\n\t\treturn;\n\t}\n\tconst lowered = defaultAttribute === void 0 ? void 0 : lowerPrisma7Default({\n\t\tattribute: defaultAttribute,\n\t\tfield,\n\t\tmodelName: model.symbol.name,\n\t\tcodecId: resolved.descriptor.codecId,\n\t\tcodecLookup: input.codecLookup,\n\t\tliteralForm: binding.literalDefaultForm(resolved.descriptor),\n\t\tenumMembers: enumDeclaration === void 0 ? void 0 : new Map(enumDeclaration.members.map((member) => [member.name, member.value])),\n\t\tcontrolMutationDefaults: input.controlMutationDefaults,\n\t\tsourceId,\n\t\tdiagnostics\n\t});\n\tif (defaultAttribute !== void 0 && lowered === void 0) return;\n\tconst updatedAtGenerator = updatedAtGeneratorId === void 0 ? void 0 : {\n\t\tkind: \"generator\",\n\t\tid: updatedAtGeneratorId\n\t};\n\tconst generator = updatedAtGenerator ?? lowered?.onCreate;\n\tconst generatingAttribute = updatedAt ?? defaultAttribute;\n\tif (generator !== void 0 && generatingAttribute !== void 0 && field.optional) {\n\t\tconst written = attributeText(generatingAttribute);\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_OPTIONAL_GENERATED_FIELD_UNSUPPORTED\", `${label} is optional and its value comes from ${written}, which Prisma 8 cannot express on an optional field yet. Remove ${written} and keep the \"?\": the database does not change, and both clients then stop filling the value.`, sourceId, generatingAttribute.span));\n\t\treturn;\n\t}\n\tconst executionDefaults = updatedAtGenerator !== void 0 ? {\n\t\tonCreate: updatedAtGenerator,\n\t\tonUpdate: updatedAtGenerator\n\t} : generator !== void 0 ? { onCreate: generator } : void 0;\n\tbuild.columns.set(field.name, {\n\t\tfieldName: field.name,\n\t\tcolumnName,\n\t\tdescriptor: resolved.descriptor,\n\t\tnullable: field.optional || field.list,\n\t\t...field.list ? {\n\t\t\tmany: true,\n\t\t\tnoCheck: [\"elementNotNull\"]\n\t\t} : {},\n\t\t...ifDefined(\"default\", lowered?.storage),\n\t\t...ifDefined(\"executionDefaults\", executionDefaults)\n\t});\n}\n//#endregion\n//#region src/provider.ts\nfunction defaultOutputFromSchemaPath(schemaPath) {\n\treturn join(dirname(schemaPath), \"contract.json\");\n}\nfunction mapParseDiagnostics(diagnostics, sourceFile, sourceId) {\n\treturn diagnostics.map((diagnostic) => ({\n\t\tcode: diagnostic.code,\n\t\tmessage: diagnostic.message,\n\t\tsourceId,\n\t\tspan: rangeToPslSpan(diagnostic.range, sourceFile)\n\t}));\n}\n/**\n* The files a Prisma 7 schema input names: the file itself, or every regular\n* `.prisma` file under the directory, nested directories and symbolic links\n* included, as Prisma 7 reads a schema directory. Sorted by path so duplicate\n* detection blames the later file deterministically.\n*/\nasync function listSchemaFiles(absolutePath, displayPath) {\n\tif (!(await stat(absolutePath)).isDirectory()) return [{\n\t\tsourceId: displayPath,\n\t\tabsolutePath\n\t}];\n\tconst entries = await readdir(absolutePath, { recursive: true });\n\tconst files = [];\n\tfor (const entry of entries.filter((name) => extname(name) === \".prisma\").map((name) => normalize(name)).sort()) {\n\t\tconst entryPath = join(absolutePath, entry);\n\t\tif ((await stat(entryPath)).isFile()) files.push({\n\t\t\tsourceId: join(displayPath, entry),\n\t\t\tabsolutePath: entryPath\n\t\t});\n\t}\n\treturn files;\n}\n/**\n* The checks `contract emit` runs on the contract after `load` that the\n* contract builder does not: domain roots and relations, column defaults\n* against nullability, and model storage references. The structural check also\n* needs the target's entity kinds, which `load` does not receive.\n*/\nfunction validateInterpretedContract(contract) {\n\tvalidateContractDomain(contract);\n\tconst sqlContract = blindCast(contract);\n\tvalidateSqlStorageConsistency(sqlContract);\n\tvalidateModelStorageReferences(sqlContract);\n}\nfunction prisma7Contract(schemaPath, options) {\n\treturn {\n\t\tsource: {\n\t\t\tformat: \"prisma7\",\n\t\t\tinputs: [schemaPath],\n\t\t\tasync load(context) {\n\t\t\t\tconst [absolutePath] = context.resolvedInputs;\n\t\t\t\tif (absolutePath === void 0) throw new InternalError(\"prisma7Contract: context.resolvedInputs is empty. The CLI config loader should populate it positional-matched with source.inputs.\");\n\t\t\t\tlet files;\n\t\t\t\ttry {\n\t\t\t\t\tfiles = await listSchemaFiles(absolutePath, schemaPath);\n\t\t\t\t} catch (error) {\n\t\t\t\t\tconst message = String(error);\n\t\t\t\t\treturn notOk({\n\t\t\t\t\t\tsummary: `Failed to read Prisma 7 schema at \"${schemaPath}\"`,\n\t\t\t\t\t\tdiagnostics: [prisma7Diagnostic(\"PSL.PRISMA7_SCHEMA_READ_FAILED\", message, schemaPath, void 0)],\n\t\t\t\t\t\tmeta: {\n\t\t\t\t\t\t\tschemaPath,\n\t\t\t\t\t\t\tabsolutePath,\n\t\t\t\t\t\t\tcause: message\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\tif (files.length === 0) return notOk({\n\t\t\t\t\tsummary: `Failed to read Prisma 7 schema at \"${schemaPath}\"`,\n\t\t\t\t\tdiagnostics: [prisma7Diagnostic(\"PSL.PRISMA7_SCHEMA_READ_FAILED\", `The schema directory \"${schemaPath}\" contains no .prisma file.`, schemaPath, void 0)],\n\t\t\t\t\tmeta: {\n\t\t\t\t\t\tschemaPath,\n\t\t\t\t\t\tabsolutePath\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t\tconst documents = [];\n\t\t\t\tconst seedDiagnostics = [];\n\t\t\t\tfor (const file of files) {\n\t\t\t\t\tlet schema;\n\t\t\t\t\ttry {\n\t\t\t\t\t\tschema = await readFile(file.absolutePath, \"utf-8\");\n\t\t\t\t\t} catch (error) {\n\t\t\t\t\t\tconst message = String(error);\n\t\t\t\t\t\treturn notOk({\n\t\t\t\t\t\t\tsummary: `Failed to read Prisma 7 schema at \"${file.sourceId}\"`,\n\t\t\t\t\t\t\tdiagnostics: [prisma7Diagnostic(\"PSL.PRISMA7_SCHEMA_READ_FAILED\", message, file.sourceId, void 0)],\n\t\t\t\t\t\t\tmeta: {\n\t\t\t\t\t\t\t\tschemaPath: file.sourceId,\n\t\t\t\t\t\t\t\tabsoluteSchemaPath: file.absolutePath,\n\t\t\t\t\t\t\t\tcause: message\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t\tconst { document, sourceFile, diagnostics } = parse(schema, { grammar: \"prisma7\" });\n\t\t\t\t\tseedDiagnostics.push(...mapParseDiagnostics(diagnostics, sourceFile, file.sourceId));\n\t\t\t\t\tdocuments.push({\n\t\t\t\t\t\tdocument,\n\t\t\t\t\t\tsourceFile,\n\t\t\t\t\t\tsourceId: file.sourceId\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\tlet contract;\n\t\t\t\ttry {\n\t\t\t\t\tconst interpreted = interpretPrisma7Documents({\n\t\t\t\t\t\tdocuments,\n\t\t\t\t\t\tseedDiagnostics,\n\t\t\t\t\t\tbinding: options.binding,\n\t\t\t\t\t\tcontrolMutationDefaults: context.controlMutationDefaults,\n\t\t\t\t\t\tauthoringContributions: context.authoringContributions,\n\t\t\t\t\t\tcodecLookup: context.codecLookup,\n\t\t\t\t\t\tcomposedExtensions: context.composedExtensions\n\t\t\t\t\t});\n\t\t\t\t\tif (!interpreted.ok) return interpreted;\n\t\t\t\t\tcontract = applySqlSpecifierControlPolicy(interpreted.value, options.defaultControlPolicy, options.binding.createNamespace);\n\t\t\t\t\tvalidateInterpretedContract(contract);\n\t\t\t\t} catch (error) {\n\t\t\t\t\tif (!isStructuredError(error)) throw error;\n\t\t\t\t\treturn notOk({\n\t\t\t\t\t\tsummary: \"Prisma 7 schema interpretation failed\",\n\t\t\t\t\t\tdiagnostics: [prisma7Diagnostic(\"PSL.PRISMA7_CONTRACT_INVALID\", `This schema gives a contract that Prisma 8 rejects, and the Prisma 7 contract source has no specific diagnostic for the cause: ${error.message.replace(/\\.$/, \"\")}. This is a bug in Prisma ORM; please report it with this schema.`, schemaPath, void 0)],\n\t\t\t\t\t\tmeta: {\n\t\t\t\t\t\t\tschemaPath,\n\t\t\t\t\t\t\tcode: error.code\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\treturn ok(contract);\n\t\t\t}\n\t\t},\n\t\toutput: options.output ?? defaultOutputFromSchemaPath(schemaPath)\n\t};\n}\n//#endregion\nexport { prisma7Contract };\n\n//# sourceMappingURL=provider.mjs.map"],"mappings":";;;;;;;;;;;;;;;;;AAiBA,SAAS,kBAAkB,MAAM,SAAS,UAAU,MAAM;CACzD,OAAO;EACN;EACA;EACA;EACA,GAAG,SAAS,KAAK,IAAI,EAAE,KAAK,IAAI,CAAC;CAClC;AACD;AACA,SAAS,QAAQ,OAAO;CACvB,MAAM,UAAU,MAAM,MAAM,GAAG,EAAE;CACjC,MAAM,OAAO,MAAM,MAAM,SAAS,MAAM;CACxC,OAAO,QAAQ,WAAW,IAAI,OAAO,GAAG,QAAQ,KAAK,IAAI,EAAE,OAAO;AACnE;AACA,SAAS,UAAU,WAAW,YAAY;CACzC,OAAO,QAAQ,WAAW,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sCAAsC,KAAK,SAAS;OAC7D,aAAa,CAAC,kBAAkB,kCAAkC,SAAS,KAAK,UAAU,KAAK,CAAC,CAAC;OACjG,MAAM;QACL,YAAY,KAAK;QACjB,oBAAoB,KAAK;QACzB,OAAO;OACR;MACD,CAAC;KACF;KACA,MAAM,EAAE,UAAU,YAAY,gBAAgB,MAAM,QAAQ,EAAE,SAAS,UAAU,CAAC;KAClF,gBAAgB,KAAK,GAAG,oBAAoB,aAAa,YAAY,KAAK,QAAQ,CAAC;KACnF,UAAU,KAAK;MACd;MACA;MACA,UAAU,KAAK;KAChB,CAAC;IACF;IACA,IAAI;IACJ,IAAI;KACH,MAAM,cAAc,0BAA0B;MAC7C;MACA;MACA,SAAS,QAAQ;MACjB,yBAAyB,QAAQ;MACjC,wBAAwB,QAAQ;MAChC,aAAa,QAAQ;MACrB,oBAAoB,QAAQ;KAC7B,CAAC;KACD,IAAI,CAAC,YAAY,IAAI,OAAO;KAC5B,WAAW,+BAA+B,YAAY,OAAO,QAAQ,sBAAsB,QAAQ,QAAQ,eAAe;KAC1H,4BAA4B,QAAQ;IACrC,SAAS,OAAO;KACf,IAAI,CAAC,kBAAkB,KAAK,GAAG,MAAM;KACrC,OAAO,MAAM;MACZ,SAAS;MACT,aAAa,CAAC,kBAAkB,gCAAgC,kIAAkI,MAAM,QAAQ,QAAQ,OAAO,EAAE,EAAE,oEAAoE,YAAY,KAAK,CAAC,CAAC;MAC1T,MAAM;OACL;OACA,MAAM,MAAM;MACb;KACD,CAAC;IACF;IACA,OAAO,GAAG,QAAQ;GACnB;EACD;EACA,QAAQ,QAAQ,UAAU,4BAA4B,UAAU;CACjE;AACD"}
1
+ {"version":3,"file":"contract-prisma7__provider.mjs","names":[],"sources":["../../../../2-sql/2-authoring/contract-prisma7/dist/provider.mjs"],"sourcesContent":["import { readFile, readdir, stat } from \"node:fs/promises\";\nimport { validateContractDomain } from \"@internal/contract/validate-domain\";\nimport { buildSymbolTable, keywordPslSpan, nodePslSpan, rangeToPslSpan, readResolvedAttribute, readResolvedAttributes } from \"@internal/psl-parser\";\nimport { ArrayLiteralAst, BooleanLiteralExprAst, FunctionCallAst, IdentifierAst, NumberLiteralExprAst, StringLiteralExprAst, parse, printSyntax } from \"@internal/psl-parser/syntax\";\nimport { validateModelStorageReferences, validateSqlStorageConsistency } from \"@internal/sql-contract/validators\";\nimport { applySqlSpecifierControlPolicy, buildSqlContractFromDefinition } from \"@internal/sql-contract-ts/contract-builder\";\nimport { blindCast } from \"@internal/utils/casts\";\nimport { InternalError } from \"@internal/utils/internal-error\";\nimport { notOk, ok } from \"@internal/utils/result\";\nimport { isStructuredError } from \"@internal/utils/structured-error\";\nimport { basename, dirname, extname, join, normalize } from \"pathe\";\nimport { collectScalarTypeConstructors, instantiateAuthoringEntityType } from \"@internal/framework-components/authoring\";\nimport { deriveValueSetFromEntity } from \"@internal/sql-contract/value-set-derivation-hook\";\nimport { applyBackrelationCandidates, buildEntityTypesByDiscriminator, indexFkRelations, normalizeReferentialAction, numberLiteralDefault, resolveFieldTypeDescriptor } from \"@internal/sql-contract-psl/resolution\";\nimport { ifDefined } from \"@internal/utils/defined\";\nimport { fkRelationPairKey } from \"@internal/psl-parser/interpret\";\n//#region src/diagnostics.ts\nfunction prisma7Diagnostic(code, message, sourceId, span) {\n\treturn {\n\t\tcode,\n\t\tmessage,\n\t\tsourceId,\n\t\t...span !== void 0 ? { span } : {}\n\t};\n}\nfunction andList(items) {\n\tconst leading = items.slice(0, -1);\n\tconst last = items[items.length - 1] ?? \"\";\n\treturn leading.length === 0 ? last : `${leading.join(\", \")} and ${last}`;\n}\nfunction fieldList(modelName, fieldNames) {\n\treturn andList(fieldNames.map((name) => `\"${modelName}.${name}\"`));\n}\nfunction ignoredFieldReferenced(input) {\n\tconst fields = fieldList(input.modelName, input.fieldNames);\n\tconst one = input.fieldNames.length === 1;\n\treturn prisma7Diagnostic(\"PSL.PRISMA7_IGNORED_FIELD_REFERENCED\", `${one ? \"Field\" : \"Fields\"} ${fields} ${one ? \"is\" : \"are\"} marked @ignore, but ${input.usedBy} uses ${one ? \"it\" : \"them\"}, and Prisma 7 still creates the ${input.constraint} that includes ${one ? \"its column\" : \"their columns\"}. Remove @ignore from ${fields}; Prisma 7's next migration is then empty, and ${one ? \"the field appears\" : \"the fields appear\"} in the Prisma 7 client again.`, input.sourceId, input.span);\n}\n//#endregion\n//#region src/defaults.ts\nconst CLIENT_SIDE_GENERATORS = /* @__PURE__ */ new Set([\n\t\"uuid\",\n\t\"cuid\",\n\t\"ulid\",\n\t\"nanoid\"\n]);\nfunction givesColumnDefault(attribute) {\n\tconst expression = attribute?.args.find((arg) => arg.kind === \"positional\")?.expression;\n\tif (expression === void 0) return false;\n\tconst call = FunctionCallAst.cast(expression.syntax);\n\tif (call === void 0) return true;\n\tconst fn = call.path().join(\".\");\n\tif (CLIENT_SIDE_GENERATORS.has(fn)) return false;\n\treturn fn !== \"dbgenerated\" || [...call.args()].length > 0;\n}\n/** Positional argument keys per Prisma 7 default function, matching the target registry's signatures. */\nconst FUNCTION_ARGUMENT_KEYS = {\n\tuuid: [\"version\"],\n\tcuid: [\"version\"],\n\tnanoid: [\"size\"],\n\tdbgenerated: [\"expression\"],\n\tnow: [],\n\tautoincrement: [],\n\tulid: []\n};\nfunction literalArgument(expression) {\n\tconst text = StringLiteralExprAst.cast(expression.syntax)?.value();\n\tif (text !== void 0) return text;\n\tconst number = NumberLiteralExprAst.cast(expression.syntax)?.value();\n\tif (number !== void 0) return number;\n\treturn BooleanLiteralExprAst.cast(expression.syntax)?.value();\n}\nfunction lowerPrisma7Default(input) {\n\tconst { attribute, field, sourceId, diagnostics } = input;\n\tconst label = `Field \"${input.modelName}.${field.name}\"`;\n\tconst unknown = (reason, span) => {\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_DEFAULT\", `${label}: @default ${reason}`, sourceId, span));\n\t};\n\tconst argument = attribute.args.find((arg) => arg.kind === \"positional\");\n\tconst expression = argument?.expression;\n\tif (argument === void 0 || expression === void 0) return unknown(\"needs one value.\", attribute.span);\n\tconst call = FunctionCallAst.cast(expression.syntax);\n\tif (call !== void 0) return lowerFunction(call, input, label, unknown);\n\tconst rawLiteral = input.literalForm?.kind === \"sqlExpression\" ? sqlExpressionDefault(expression, input.literalForm, input.field.list) : void 0;\n\tif (rawLiteral === \"unreadable\") return unknown(\"holds a value this contract source does not read.\", attribute.span);\n\tif (rawLiteral !== void 0) return {\n\t\tstorage: {\n\t\t\tkind: \"function\",\n\t\t\texpression: rawLiteral.expression\n\t\t},\n\t\tonCreate: void 0\n\t};\n\tconst scalar = scalarValue$1(expression, input, unknown);\n\tif (scalar === void 0) return void 0;\n\treturn {\n\t\tstorage: {\n\t\t\tkind: \"literal\",\n\t\t\tvalue: scalar\n\t\t},\n\t\tonCreate: void 0\n\t};\n}\nfunction scalarValue$1(expression, input, unknown) {\n\tconst span = input.attribute.span;\n\tconst isJson = input.literalForm?.kind === \"json\";\n\tconst jsonNull = (holds) => {\n\t\tinput.diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_JSON_NULL_DEFAULT_UNSUPPORTED\", `Field \"${input.modelName}.${input.field.name}\": @default(${printSyntax(expression.syntax).trim()}) ${holds} the JSON value null, which the contract cannot tell apart from SQL NULL. Remove the @default or give it another JSON value; either changes the column default on Prisma 7's next migration.`, input.sourceId, span));\n\t};\n\tconst array = ArrayLiteralAst.cast(expression.syntax);\n\tif (array !== void 0) {\n\t\tconst values = [];\n\t\tfor (const element of array.elements()) {\n\t\t\tconst value = elementValue(element, input);\n\t\t\tif (value === void 0) return unknown(rejectedNumberReason(element, input) ?? \"lists may only hold literals or enum members.\", span);\n\t\t\tvalues.push(value);\n\t\t}\n\t\tif (isJson && values.includes(null)) return jsonNull(\"holds\");\n\t\treturn values;\n\t}\n\tconst value = elementValue(expression, input);\n\tif (isJson && value === null) return jsonNull(\"is\");\n\tif (value !== void 0) return value;\n\tconst numberReason = rejectedNumberReason(expression, input);\n\tif (numberReason !== void 0) return unknown(numberReason, span);\n\tconst identifier = IdentifierAst.cast(expression.syntax)?.name();\n\tif (identifier !== void 0) return unknown(input.enumMembers === void 0 ? `refers to \"${identifier}\", but the field is not an enum.` : `refers to \"${identifier}\", which is not a member of the field's enum.`, span);\n\treturn unknown(\"holds a value this contract source does not read.\", span);\n}\nfunction sqlExpressionDefault(expression, form, isList) {\n\tconst array = isList ? ArrayLiteralAst.cast(expression.syntax) : void 0;\n\tif (array === void 0) {\n\t\tconst text = StringLiteralExprAst.cast(expression.syntax)?.value();\n\t\tif (text === void 0) return void 0;\n\t\tconst literal = form.literal(text);\n\t\treturn literal === void 0 ? \"unreadable\" : { expression: literal };\n\t}\n\tconst literals = [];\n\tfor (const element of array.elements()) {\n\t\tconst text = StringLiteralExprAst.cast(element.syntax)?.value();\n\t\tconst literal = text === void 0 ? void 0 : form.literal(text);\n\t\tif (literal === void 0) return \"unreadable\";\n\t\tliterals.push(literal);\n\t}\n\treturn { expression: form.list(literals) };\n}\n/** The Prisma 7 scalars whose number defaults must be whole numbers, as each is named in a message. */\nconst WHOLE_NUMBER_SCALARS = {\n\tInt: \"an Int\",\n\tBigInt: \"a BigInt\"\n};\nconst WHOLE_NUMBER_TEXT = /^-?\\d+$/;\n/** The number literal the column codec reads neither as a number nor as text, such as `1.5` for a `BigInt`, which Prisma 7 rejects too. */\nfunction rejectedNumberReason(expression, input) {\n\tconst text = NumberLiteralExprAst.cast(expression.syntax)?.token()?.text;\n\tif (text === void 0 || numberValue(text, input) !== void 0) return void 0;\n\tconst { typeName } = input.field;\n\tconst wholeNumberScalar = Object.hasOwn(WHOLE_NUMBER_SCALARS, typeName) ? WHOLE_NUMBER_SCALARS[typeName] : void 0;\n\treturn wholeNumberScalar === void 0 ? `holds ${text}, which is not a valid ${typeName} value.` : `holds ${text}, which is not an integer; ${wholeNumberScalar} default must be a whole number.`;\n}\n/** A number default for the field: Prisma 7 accepts only whole numbers for `Int` and `BigInt`. */\nfunction numberValue(text, input) {\n\tif (Object.hasOwn(WHOLE_NUMBER_SCALARS, input.field.typeName) && !WHOLE_NUMBER_TEXT.test(text)) return;\n\treturn numberLiteralDefault(text, input.codecId, input.codecLookup);\n}\nfunction elementValue(expression, input) {\n\tconst member = IdentifierAst.cast(expression.syntax)?.name();\n\tif (member !== void 0) return input.enumMembers?.get(member);\n\tconst number = NumberLiteralExprAst.cast(expression.syntax)?.token()?.text;\n\tif (number !== void 0) return numberValue(number, input);\n\tconst text = StringLiteralExprAst.cast(expression.syntax)?.value();\n\tif (text !== void 0) {\n\t\tif (input.literalForm?.kind === \"json\") try {\n\t\t\treturn blindCast(JSON.parse(text));\n\t\t} catch {\n\t\t\treturn;\n\t\t}\n\t\treturn text;\n\t}\n\treturn BooleanLiteralExprAst.cast(expression.syntax)?.value();\n}\nfunction lowerFunction(call, input, label, unknown) {\n\tconst fn = call.path().join(\".\");\n\tconst span = input.attribute.span;\n\tconst callArgs = [...call.args()];\n\tif (fn === \"dbgenerated\" && callArgs.length === 0) {\n\t\tif (input.field.optional || input.field.list) return {\n\t\t\tstorage: void 0,\n\t\t\tonCreate: void 0\n\t\t};\n\t\tinput.diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_DEFAULT\", `${label}: @default(dbgenerated()) with no expression is not supported yet on a required field, because without a column default Prisma 8 requires the value on create. Either remove the @default, which makes Prisma 7's next migration drop the column default (ALTER COLUMN ... DROP DEFAULT) and both clients require the value on create, or write the column's database default as @default(dbgenerated(\"<expression>\")), which Prisma 7's next migration sets on the column.`, input.sourceId, span));\n\t\treturn;\n\t}\n\tconst keys = FUNCTION_ARGUMENT_KEYS[fn];\n\tconst entry = input.controlMutationDefaults.defaultFunctionRegistry.get(fn);\n\tif (keys === void 0 || entry === void 0) return unknown(`function \"${fn}()\" is not a Prisma 7 default function this target supports.`, span);\n\tconst args = {};\n\tlet index = 0;\n\tfor (const arg of callArgs) {\n\t\tconst key = arg.name()?.name() ?? keys[index];\n\t\tconst value = arg.value();\n\t\tconst literal = value === void 0 ? void 0 : literalArgument(value);\n\t\tif (key === void 0 || literal === void 0) return unknown(`function \"${fn}()\" has an argument this contract source does not read.`, span);\n\t\targs[key] = literal;\n\t\tindex += 1;\n\t}\n\tif (fn === \"cuid\") args[\"version\"] = 2;\n\tconst lowered = entry.lower({\n\t\tcall: {\n\t\t\tfn,\n\t\t\tspan,\n\t\t\targs\n\t\t},\n\t\tcontext: {\n\t\t\tsourceId: input.sourceId,\n\t\t\tmodelName: input.modelName,\n\t\t\tfieldName: input.field.name,\n\t\t\tcolumnCodecId: input.codecId\n\t\t}\n\t});\n\tif (!lowered.ok) {\n\t\tinput.diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_DEFAULT\", `${label}: ${lowered.diagnostic.message}`, input.sourceId, span));\n\t\treturn;\n\t}\n\treturn lowered.value.kind === \"storage\" ? {\n\t\tstorage: lowered.value.defaultValue,\n\t\tonCreate: void 0\n\t} : {\n\t\tstorage: void 0,\n\t\tonCreate: lowered.value.generated\n\t};\n}\n//#endregion\n//#region src/indexes.ts\nfunction parseIndexAttribute(attribute, owner, sourceId, indexTypes, diagnostics) {\n\tconst unsupported = (what, span) => {\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_INDEX_ARGUMENT_UNSUPPORTED\", `\"${owner}\": @${attribute.name} ${what}`, sourceId, span));\n\t};\n\tlet fields;\n\tlet map;\n\tlet type;\n\tfor (const arg of attribute.args) {\n\t\tconst key = arg.kind === \"positional\" ? \"fields\" : arg.name;\n\t\tconst expression = arg.expression;\n\t\tswitch (key) {\n\t\t\tcase \"fields\": {\n\t\t\t\tconst array = expression === void 0 ? void 0 : ArrayLiteralAst.cast(expression.syntax);\n\t\t\t\tif (array === void 0) return unsupported(\"expects a list of field names.\", arg.span);\n\t\t\t\tconst names = [];\n\t\t\t\tfor (const element of array.elements()) {\n\t\t\t\t\tconst name = IdentifierAst.cast(element.syntax)?.name();\n\t\t\t\t\tif (name === void 0) return unsupported(\"field arguments such as sort or length are not supported; Prisma 8 indexes carry none.\", arg.span);\n\t\t\t\t\tnames.push(name);\n\t\t\t\t}\n\t\t\t\tfields = names;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tcase \"map\":\n\t\t\t\tmap = expression === void 0 ? void 0 : StringLiteralExprAst.cast(expression.syntax)?.value();\n\t\t\t\tif (map === void 0) return unsupported(\"map must be a string.\", arg.span);\n\t\t\t\tbreak;\n\t\t\tcase \"name\": break;\n\t\t\tcase \"type\": {\n\t\t\t\tconst token = expression === void 0 ? void 0 : IdentifierAst.cast(expression.syntax)?.name();\n\t\t\t\ttype = token !== void 0 && Object.hasOwn(indexTypes, token) ? indexTypes[token] : void 0;\n\t\t\t\tif (type === void 0) return unsupported(`type \"${token ?? \"\"}\" is not an index type Prisma 8 supports.`, arg.span);\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tdefault: return unsupported(`argument \"${key ?? \"\"}\" is not supported.`, arg.span);\n\t\t}\n\t}\n\treturn {\n\t\tfields,\n\t\tmap,\n\t\ttype,\n\t\tspan: attribute.span\n\t};\n}\nconst utf8 = new TextEncoder();\n/**\n* A generated constraint name as Prisma 7 spells it: `base` cut so that\n* `base + suffix` is at most `maxBytes` bytes, cut on a character boundary,\n* with the suffix kept whole. Prisma 7.10.0 emits `..._aVeryLongCo_idx` for a\n* long `@@index`, `..._AB_pkey` and `..._B_index` for a long implicit junction,\n* and cuts a multi-byte name before the character that would cross the budget.\n*/\nfunction prisma7ConstraintName(base, suffix, maxBytes) {\n\tconst budget = maxBytes - utf8.encode(suffix).length;\n\tlet bytes = 0;\n\tlet kept = \"\";\n\tfor (const character of base) {\n\t\tbytes += utf8.encode(character).length;\n\t\tif (bytes > budget) break;\n\t\tkept += character;\n\t}\n\treturn `${kept}${suffix}`;\n}\n/** Prisma 7's default index name: `{table}_{columns}_idx`, or `_key` for a unique index, cut to `maxBytes`. */\nfunction defaultIndexName(tableName, columns, unique, maxBytes) {\n\treturn prisma7ConstraintName(`${tableName}_${columns.join(\"_\")}`, unique ? \"_key\" : \"_idx\", maxBytes);\n}\nfunction indexNode(tableName, columns, attribute, unique, maxBytes) {\n\treturn {\n\t\tcolumns,\n\t\t...attribute.type === void 0 ? {\n\t\t\ttype: void 0,\n\t\t\toptions: void 0\n\t\t} : {\n\t\t\ttype: attribute.type,\n\t\t\toptions: {}\n\t\t},\n\t\twhere: void 0,\n\t\tunique: unique ? true : void 0,\n\t\tmap: attribute.map ?? defaultIndexName(tableName, columns, unique, maxBytes),\n\t\tname: void 0\n\t};\n}\n//#endregion\n//#region src/native-types.ts\nfunction prisma7ScalarMapping(typeMap, scalar) {\n\treturn Object.hasOwn(typeMap.scalars, scalar) ? typeMap.scalars[scalar] : void 0;\n}\nfunction prisma7NativeTypeMapping(typeMap, nativeType, args) {\n\tconst mapping = Object.hasOwn(typeMap.nativeTypes, nativeType) ? typeMap.nativeTypes[nativeType] : void 0;\n\tif (mapping === void 0) return void 0;\n\treturn args.length === 0 ? mapping : {\n\t\tconstructorName: mapping.constructorName,\n\t\targs\n\t};\n}\n//#endregion\n//#region src/relations.ts\n/** The codes `applyBackrelationCandidates` reports, each shown as `PSL.PRISMA7_RELATION_UNRESOLVED`. */\nconst RELATION_PAIRING_CODES = /* @__PURE__ */ new Set([\n\t\"PSL_ORPHANED_BACKRELATION\",\n\t\"PSL_AMBIGUOUS_BACKRELATION\",\n\t\"PSL_NON_UNIQUE_BACKRELATION\",\n\t\"PSL_REQUIRED_ONE_TO_ONE_BACKRELATION\",\n\t\"PSL_JUNCTION_ID_NOT_FK_COVERING\",\n\t\"PSL_JUNCTION_TARGET_FK_NOT_ID\"\n]);\nfunction identifierNames(expression) {\n\tif (expression === void 0) return void 0;\n\tconst array = ArrayLiteralAst.cast(expression.syntax);\n\tif (array === void 0) return void 0;\n\tconst names = [];\n\tfor (const element of array.elements()) {\n\t\tconst name = IdentifierAst.cast(element.syntax)?.name();\n\t\tif (name === void 0) return void 0;\n\t\tnames.push(name);\n\t}\n\treturn names;\n}\nfunction stringValue(expression) {\n\treturn expression === void 0 ? void 0 : StringLiteralExprAst.cast(expression.syntax)?.value();\n}\nconst PRISMA7_REFERENTIAL_ACTIONS = /* @__PURE__ */ new Set([\n\t\"Cascade\",\n\t\"Restrict\",\n\t\"NoAction\",\n\t\"SetNull\",\n\t\"SetDefault\"\n]);\nfunction actionValue(expression) {\n\tconst token = expression === void 0 ? void 0 : IdentifierAst.cast(expression.syntax)?.name();\n\treturn token !== void 0 && PRISMA7_REFERENTIAL_ACTIONS.has(token) ? normalizeReferentialAction(token) : void 0;\n}\nfunction parseRelationAttribute(attribute, label, sourceId, diagnostics) {\n\tlet name;\n\tlet fields;\n\tlet references;\n\tlet onDelete;\n\tlet onUpdate;\n\tconst invalid = (what, span) => {\n\t\tdiagnostics.push({\n\t\t\tcode: \"PSL_INVALID_ATTRIBUTE_ARGUMENT\",\n\t\t\tmessage: `${label}: @relation ${what}.`,\n\t\t\tsourceId,\n\t\t\tspan\n\t\t});\n\t};\n\tfor (const arg of attribute.args) {\n\t\tconst key = arg.kind === \"positional\" ? \"name\" : arg.name;\n\t\tswitch (key) {\n\t\t\tcase \"name\":\n\t\t\t\tname = stringValue(arg.expression);\n\t\t\t\tif (name === void 0) return invalid(\"name must be a string\", arg.span);\n\t\t\t\tbreak;\n\t\t\tcase \"fields\":\n\t\t\t\tfields = identifierNames(arg.expression);\n\t\t\t\tif (fields === void 0) return invalid(\"fields must be a list of field names\", arg.span);\n\t\t\t\tbreak;\n\t\t\tcase \"references\":\n\t\t\t\treferences = identifierNames(arg.expression);\n\t\t\t\tif (references === void 0) return invalid(\"references must be a list of field names\", arg.span);\n\t\t\t\tbreak;\n\t\t\tcase \"onDelete\":\n\t\t\t\tonDelete = actionValue(arg.expression);\n\t\t\t\tif (onDelete === void 0) return invalid(\"onDelete must be a referential action\", arg.span);\n\t\t\t\tbreak;\n\t\t\tcase \"onUpdate\":\n\t\t\t\tonUpdate = actionValue(arg.expression);\n\t\t\t\tif (onUpdate === void 0) return invalid(\"onUpdate must be a referential action\", arg.span);\n\t\t\t\tbreak;\n\t\t\tcase \"map\": break;\n\t\t\tdefault: return invalid(`argument \"${key ?? \"\"}\" is not supported`, arg.span);\n\t\t}\n\t}\n\treturn {\n\t\tname,\n\t\tfields,\n\t\treferences,\n\t\tonDelete,\n\t\tonUpdate,\n\t\tspan: attribute.span\n\t};\n}\nfunction columnNames(model, fieldNames) {\n\tconst columns = [];\n\tfor (const fieldName of fieldNames) {\n\t\tconst column = model.columns.get(fieldName);\n\t\tif (column === void 0) return void 0;\n\t\tcolumns.push(column.columnName);\n\t}\n\treturn columns;\n}\nfunction unresolved(label, reason, sourceId, span) {\n\treturn prisma7Diagnostic(\"PSL.PRISMA7_RELATION_UNRESOLVED\", `${label} ${reason}`, sourceId, span);\n}\nfunction groupBy(items, keyOf) {\n\tconst groups = /* @__PURE__ */ new Map();\n\tfor (const item of items) {\n\t\tconst group = groups.get(keyOf(item)) ?? [];\n\t\tgroups.set(keyOf(item), group);\n\t\tgroup.push(item);\n\t}\n\treturn groups;\n}\nfunction orderJunctionSides(requester, partner) {\n\treturn (requester.model === partner.model ? requester.field.field.name < partner.field.field.name : requester.model.modelName < partner.model.modelName) ? [requester, partner] : [partner, requester];\n}\nfunction junctionKey(namespaceId, name) {\n\treturn JSON.stringify([namespaceId, name]);\n}\n/**\n* Prisma 7's default relation name: the two model names in alphabetical\n* order joined by `To`. Giving every unnamed relation that name lets the\n* shared pairing helper match Prisma 7's rule that an unnamed side pairs only\n* with the unnamed side of the same model pair.\n*/\nfunction effectiveRelationName(attribute, modelName, targetModelName) {\n\tif (attribute?.name !== void 0) return attribute.name;\n\tconst [first, second] = modelName < targetModelName ? [modelName, targetModelName] : [targetModelName, modelName];\n\treturn `${first}To${second}`;\n}\n/**\n* Prisma 7 accepts `SetNull` over a required field and `SetDefault` over a\n* required field with no default, and writes them into the foreign key; the\n* contract rejects both, because the action would fail the first time it runs.\n*/\nfunction referentialActionRejections(input) {\n\tconst { model, relationField, label, fieldNames, span } = input;\n\tconst anotherAction = \"choose another action, which replaces the foreign key on Prisma 7's next migration and leaves the Prisma 7 client unchanged.\";\n\tconst fieldsWhere = (predicate) => fieldNames.filter((name) => {\n\t\tconst column = model.columns.get(name);\n\t\treturn column !== void 0 && predicate(column);\n\t});\n\tconst rejections = [];\n\tfor (const [key, action] of Object.entries(input.actions)) {\n\t\tif (action === \"setNull\") {\n\t\t\tconst required = fieldsWhere((column) => !column.nullable);\n\t\t\tif (required.length === 0) continue;\n\t\t\tconst fields = fieldList(model.modelName, required);\n\t\t\trejections.push(prisma7Diagnostic(\"PSL.PRISMA7_REFERENTIAL_ACTION_UNSUPPORTED\", `${label}: ${key}: SetNull sets the foreign key fields to null, but ${fields} ${required.length === 1 ? \"is\" : \"are\"} required, so Prisma 8 cannot describe this foreign key. Make ${fields}${relationField.optional ? \"\" : ` and \"${model.modelName}.${relationField.name}\"`} optional, which drops NOT NULL on Prisma 7's next migration and makes ${required.length === 1 && relationField.optional ? \"it\" : \"them\"} nullable in the Prisma 7 client, or ${anotherAction}`, model.sourceId, span));\n\t\t}\n\t\tif (action === \"setDefault\") {\n\t\t\tconst withoutDefault = fieldsWhere((column) => !column.nullable && column.default === void 0);\n\t\t\tif (withoutDefault.length === 0) continue;\n\t\t\tconst fields = fieldList(model.modelName, withoutDefault);\n\t\t\tconst one = withoutDefault.length === 1;\n\t\t\tconst generated = withoutDefault.filter((name) => model.columns.get(name)?.executionDefaults?.onCreate !== void 0);\n\t\t\tconst plain = withoutDefault.filter((name) => !generated.includes(name));\n\t\t\tconst generatorNote = generated.length > 0 ? \" (a client-side generator such as uuid() does not give the column one)\" : \"\";\n\t\t\tconst example = \"a column default, such as a literal or @default(dbgenerated(\\\"<expression>\\\"))\";\n\t\t\tconst plainFields = fieldList(model.modelName, plain);\n\t\t\tconst generatedFields = fieldList(model.modelName, generated);\n\t\t\tconst edit = generated.length === 0 ? `Give ${plainFields} ${example}` : plain.length === 0 ? `Replace the @default on ${generatedFields} with ${example}, because a field takes only one @default` : `Give ${plainFields} ${example}, and replace the @default on ${generatedFields} with one, because a field takes only one @default`;\n\t\t\tconst effects = [\n\t\t\t\t`Prisma 7's next migration sets ${one ? \"it\" : \"them\"}`,\n\t\t\t\t...plain.length > 0 ? [`${plainFields} ${plain.length === 1 ? \"becomes\" : \"become\"} optional when creating records with the Prisma 7 client`] : [],\n\t\t\t\t...generated.length > 0 ? [`the Prisma 7 client stops generating ${generated.length === 1 ? \"a value\" : \"values\"} for ${generatedFields}`] : []\n\t\t\t];\n\t\t\trejections.push(prisma7Diagnostic(\"PSL.PRISMA7_REFERENTIAL_ACTION_UNSUPPORTED\", `${label}: ${key}: SetDefault sets the foreign key fields to their column defaults, but ${fields} ${one ? \"is\" : \"are\"} required and ${one ? \"has\" : \"have\"} no column default${generatorNote}, so Prisma 8 cannot describe this foreign key. ${edit}: ${andList(effects)}. Or ${anotherAction}`, model.sourceId, span));\n\t\t}\n\t}\n\treturn rejections;\n}\nfunction lowerRelations(models, naming, diagnostics) {\n\tconst fkRelationMetadata = [];\n\tconst candidates = [];\n\tconst invalidFkPairings = [];\n\tconst foreignKeys = /* @__PURE__ */ new Map();\n\tconst junctions = /* @__PURE__ */ new Map();\n\tconst reportedJunctionNames = /* @__PURE__ */ new Set();\n\tconst junctionRequests = [];\n\tconst addForeignKey = (modelName, node) => {\n\t\tconst existing = foreignKeys.get(modelName) ?? [];\n\t\tforeignKeys.set(modelName, existing);\n\t\texisting.push(node);\n\t};\n\tconst isFkSide = (relationField) => relationField.attribute?.fields !== void 0;\n\tconst sameName = (left, right) => left.attribute?.name === right.attribute?.name;\n\tconst rejectFkSide = (model, relationField, ...rejections) => {\n\t\tdiagnostics.push(...rejections);\n\t\tinvalidFkPairings.push({\n\t\t\tpairKey: fkRelationPairKey(model.modelName, relationField.targetModelName),\n\t\t\trelationName: effectiveRelationName(relationField.attribute, model.modelName, relationField.targetModelName)\n\t\t});\n\t};\n\tfor (const model of models.values()) for (const relationField of model.relationFields) {\n\t\tconst { field, targetModelName } = relationField;\n\t\tconst label = `Relation field \"${model.modelName}.${field.name}\"`;\n\t\tconst target = models.get(targetModelName);\n\t\tif (target === void 0) continue;\n\t\tif (isFkSide(relationField)) {\n\t\t\tconst attribute = relationField.attribute;\n\t\t\tif (attribute === void 0 || attribute.fields === void 0) continue;\n\t\t\tconst ignoredScalars = attribute.fields.filter((name) => model.ignoredFields.has(name));\n\t\t\tif (ignoredScalars.length > 0) {\n\t\t\t\trejectFkSide(model, relationField, ignoredFieldReferenced({\n\t\t\t\t\tmodelName: model.modelName,\n\t\t\t\t\tfieldNames: ignoredScalars,\n\t\t\t\t\tusedBy: `relation field \"${model.modelName}.${field.name}\"`,\n\t\t\t\t\tconstraint: \"foreign key\",\n\t\t\t\t\tsourceId: model.sourceId,\n\t\t\t\t\tspan: attribute.span\n\t\t\t\t}));\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tif (attribute.references === void 0) {\n\t\t\t\trejectFkSide(model, relationField, unresolved(label, \"declares fields without references.\", model.sourceId, attribute.span));\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tif (attribute.fields.some((name) => model.rejectedFields.has(name)) || attribute.references.some((name) => target.ignoredFields.has(name) || target.rejectedFields.has(name))) {\n\t\t\t\trejectFkSide(model, relationField);\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst localColumns = columnNames(model, attribute.fields);\n\t\t\tconst referencedColumns = columnNames(target, attribute.references);\n\t\t\tif (localColumns === void 0 || referencedColumns === void 0) {\n\t\t\t\trejectFkSide(model, relationField, unresolved(label, \"names a field that is not a scalar column of the model or its target.\", model.sourceId, attribute.span));\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tif (localColumns.length !== referencedColumns.length) {\n\t\t\t\trejectFkSide(model, relationField, unresolved(label, \"must list as many fields as references.\", model.sourceId, attribute.span));\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst nullability = attribute.fields.map((name) => model.columns.get(name)?.nullable === true);\n\t\t\tconst anyNullable = nullability.includes(true);\n\t\t\tif (anyNullable && !field.optional) {\n\t\t\t\trejectFkSide(model, relationField, unresolved(label, \"must be optional because one of its fields is optional.\", model.sourceId, field.span));\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tconst onDelete = attribute.onDelete ?? (nullability.includes(false) ? \"restrict\" : \"setNull\");\n\t\t\tconst onUpdate = attribute.onUpdate ?? \"cascade\";\n\t\t\tconst actionRejections = referentialActionRejections({\n\t\t\t\tmodel,\n\t\t\t\trelationField: field,\n\t\t\t\tlabel,\n\t\t\t\tfieldNames: attribute.fields,\n\t\t\t\tactions: {\n\t\t\t\t\tonDelete,\n\t\t\t\t\tonUpdate\n\t\t\t\t},\n\t\t\t\tspan: attribute.span\n\t\t\t});\n\t\t\tif (actionRejections.length > 0) {\n\t\t\t\trejectFkSide(model, relationField, ...actionRejections);\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\taddForeignKey(model.modelName, {\n\t\t\t\tcolumns: localColumns,\n\t\t\t\treferences: {\n\t\t\t\t\tmodel: target.modelName,\n\t\t\t\t\ttable: target.tableName,\n\t\t\t\t\tcolumns: referencedColumns,\n\t\t\t\t\tnamespaceId: target.namespaceId\n\t\t\t\t},\n\t\t\t\tonDelete,\n\t\t\t\tonUpdate,\n\t\t\t\tindex: false\n\t\t\t});\n\t\t\tfkRelationMetadata.push({\n\t\t\t\tdeclaringModelName: model.modelName,\n\t\t\t\tdeclaringFieldName: field.name,\n\t\t\t\tdeclaringTableName: model.tableName,\n\t\t\t\tdeclaringNamespaceId: model.namespaceId,\n\t\t\t\ttargetModelName: target.modelName,\n\t\t\t\ttargetTableName: target.tableName,\n\t\t\t\ttargetNamespaceId: target.namespaceId,\n\t\t\t\trelationName: effectiveRelationName(attribute, model.modelName, target.modelName),\n\t\t\t\tnullable: anyNullable,\n\t\t\t\tlocalColumns,\n\t\t\t\treferencedColumns\n\t\t\t});\n\t\t\tcontinue;\n\t\t}\n\t\tif (target.ignoredRelationFields.some((other) => other.targetModelName === model.modelName && sameName(other, relationField))) continue;\n\t\tif (target.relationFields.filter((other) => other.targetModelName === model.modelName && isFkSide(other) && sameName(other, relationField)).length > 0 || !field.list) {\n\t\t\tcandidates.push({\n\t\t\t\tmodelName: model.modelName,\n\t\t\t\ttableName: model.tableName,\n\t\t\t\tfield,\n\t\t\t\ttargetModelName: target.modelName,\n\t\t\t\tisList: field.list,\n\t\t\t\trelationName: effectiveRelationName(relationField.attribute, model.modelName, target.modelName)\n\t\t\t});\n\t\t\tcontinue;\n\t\t}\n\t\tconst partners = target.relationFields.filter((other) => other !== relationField && other.targetModelName === model.modelName && other.field.list && !isFkSide(other) && sameName(other, relationField));\n\t\tconst [partner] = partners;\n\t\tif (partner === void 0) {\n\t\t\tdiagnostics.push(unresolved(label, `has no matching relation field on \"${target.modelName}\".`, model.sourceId, field.span));\n\t\t\tcontinue;\n\t\t}\n\t\tif (partners.length > 1 || target === model && relationField.attribute?.name === void 0) {\n\t\t\tdiagnostics.push(unresolved(label, `is ambiguous: more than one list field on \"${target.modelName}\" could pair with it. Name both sides with @relation(\"name\").`, model.sourceId, field.span));\n\t\t\tcontinue;\n\t\t}\n\t\tconst junctionName = effectiveRelationName(relationField.attribute, model.modelName, target.modelName);\n\t\tconst requester = {\n\t\t\tmodel,\n\t\t\tfield: relationField\n\t\t};\n\t\tconst partnerSide = {\n\t\t\tmodel: target,\n\t\t\tfield: partner\n\t\t};\n\t\tconst junctionNamespaceId = orderJunctionSides(requester, partnerSide)[0].model.namespaceId;\n\t\tconst namesake = models.get(junctionName);\n\t\tif (namesake !== void 0 && namesake.namespaceId === junctionNamespaceId) {\n\t\t\tconst reportedKey = junctionKey(junctionNamespaceId, junctionName);\n\t\t\tif (!reportedJunctionNames.has(reportedKey)) {\n\t\t\t\treportedJunctionNames.add(reportedKey);\n\t\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_JUNCTION_NAME_COLLISION\", `${label} is an implicit many-to-many relation whose junction model would be named \"${junctionName}\", but model \"${junctionName}\" already has that name. Rename model \"${junctionName}\" and keep its table with @@map(\"${namesake.tableName}\"); Prisma 7's next migration is then empty.`, model.sourceId, field.span));\n\t\t\t}\n\t\t\tcontinue;\n\t\t}\n\t\tjunctionRequests.push({\n\t\t\trequester,\n\t\t\tpartner: partnerSide,\n\t\t\tname: junctionName\n\t\t});\n\t}\n\tconst requestsByJunction = groupBy(junctionRequests, (request) => junctionKey(orderJunctionSides(request.requester, request.partner)[0].model.namespaceId, request.name));\n\tfor (const requests of requestsByJunction.values()) {\n\t\tconst [first] = requests;\n\t\tif (first === void 0) continue;\n\t\tconst name = first.name;\n\t\tconst [sideA] = orderJunctionSides(first.requester, first.partner);\n\t\tconst tableName = prisma7ConstraintName(`_${name}`, \"\", naming.identifierMaxBytes);\n\t\tconst sideLabel = (side) => `${side.model.modelName}.${side.field.field.name}`;\n\t\tconst pairs = /* @__PURE__ */ new Map();\n\t\tfor (const request of requests) {\n\t\t\tconst key = [sideLabel(request.requester), sideLabel(request.partner)].sort().join(\"|\");\n\t\t\tif (!pairs.has(key)) pairs.set(key, request);\n\t\t}\n\t\tif (pairs.size > 1) {\n\t\t\tconst pairRequests = [...pairs.values()];\n\t\t\tfor (const request of pairRequests) {\n\t\t\t\tconst others = pairRequests.filter((other) => other !== request).map((other) => `\"${sideLabel(other.requester)}\"`);\n\t\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_RELATION_NAME_SHARED\", `Relation field \"${sideLabel(request.requester)}\" is an implicit many-to-many relation named \"${name}\", and so ${others.length === 1 ? \"is relation field\" : \"are relation fields\"} ${andList(others)}; Prisma 7 creates one table \"${tableName}\" for them, wired to only one of the relations (its foreign keys show which). Give each relation its own name with @relation(\"<name>\") on both fields: renaming a relation that \"${tableName}\" does not reference makes Prisma 7's next migration create its own table, while renaming the one it references moves \"${tableName}\"'s foreign keys to another relation, which fails on rows whose ids that relation's models lack and attaches the rest to the wrong records.`, request.requester.model.sourceId, request.requester.field.field.span));\n\t\t\t}\n\t\t\tcontinue;\n\t\t}\n\t\tconst tableOwner = [...models.values()].find((other) => other.tableName === tableName && other.namespaceId === sideA.model.namespaceId);\n\t\tif (tableOwner !== void 0) {\n\t\t\tconst relationField = `${first.requester.model.modelName}.${first.requester.field.field.name}`;\n\t\t\tconst message = `Model \"${tableOwner.modelName}\" and the implicit many-to-many relation \"${relationField}\" both use table \"${tableOwner.namespaceId}\".\"${tableName}\"; Prisma 7 creates the relation's table there and never creates the model's. Rename the model's table with @@map, which makes Prisma 7's next migration create it, or give the relation its own name with @relation(\"<name>\") on both fields, which makes Prisma 7's next migration rebuild \"${tableName}\" as the model's table and create an empty table for the relation, losing the relation's rows.`;\n\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_TABLE_COLLISION\", message, tableOwner.sourceId, tableOwner.tableSpan), prisma7Diagnostic(\"PSL.PRISMA7_TABLE_COLLISION\", message, first.requester.model.sourceId, first.requester.field.field.span));\n\t\t\tcontinue;\n\t\t}\n\t\tfor (const { requester, partner } of requests) {\n\t\t\tconst junction = synthesizeJunction(requester, partner, naming, diagnostics);\n\t\t\tif (junction === void 0) continue;\n\t\t\tif (!junctions.has(junction.key)) {\n\t\t\t\tjunctions.set(junction.key, junction.node);\n\t\t\t\tfkRelationMetadata.push(...junction.foreignKeys);\n\t\t\t}\n\t\t\tcandidates.push({\n\t\t\t\tmodelName: requester.model.modelName,\n\t\t\t\ttableName: requester.model.tableName,\n\t\t\t\tfield: requester.field.field,\n\t\t\t\ttargetModelName: partner.model.modelName,\n\t\t\t\tisList: true,\n\t\t\t\trelationName: junction.candidateRelationName\n\t\t\t});\n\t\t}\n\t}\n\tconst { modelRelations, fkRelationsByPair, fkRelationsByDeclaringModel } = indexFkRelations({ fkRelationMetadata });\n\tconst modelIdColumns = /* @__PURE__ */ new Map();\n\tconst modelUniqueColumnSets = /* @__PURE__ */ new Map();\n\tfor (const model of models.values()) {\n\t\tconst id = columnNames(model, model.idFields);\n\t\tif (id !== void 0 && id.length > 0) modelIdColumns.set(model.modelName, id);\n\t\tconst sets = [];\n\t\tif (id !== void 0 && id.length > 0) sets.push(id);\n\t\tfor (const unique of model.uniqueFieldSets) {\n\t\t\tconst columns = columnNames(model, unique);\n\t\t\tif (columns !== void 0) sets.push(columns);\n\t\t}\n\t\tmodelUniqueColumnSets.set(model.modelName, sets);\n\t}\n\tfor (const key of junctions.keys()) {\n\t\tmodelIdColumns.set(key, [\"A\", \"B\"]);\n\t\tmodelUniqueColumnSets.set(key, [[\"A\", \"B\"]]);\n\t}\n\tconst pairingDiagnostics = [];\n\tconst candidatesBySourceId = /* @__PURE__ */ new Map();\n\tfor (const candidate of candidates) {\n\t\tconst sourceId = models.get(candidate.modelName)?.sourceId ?? \"schema.prisma\";\n\t\tconst group = candidatesBySourceId.get(sourceId) ?? [];\n\t\tcandidatesBySourceId.set(sourceId, group);\n\t\tgroup.push(candidate);\n\t}\n\tfor (const [sourceId, backrelationCandidates] of candidatesBySourceId) applyBackrelationCandidates({\n\t\tbackrelationCandidates,\n\t\tfkRelationsByPair,\n\t\tinvalidFkPairings,\n\t\tfkRelationsByDeclaringModel,\n\t\tmodelIdColumns,\n\t\tmodelUniqueColumnSets,\n\t\tmodelRelations,\n\t\tdiagnostics: pairingDiagnostics,\n\t\tsourceId\n\t});\n\tfor (const diagnostic of pairingDiagnostics) diagnostics.push(RELATION_PAIRING_CODES.has(diagnostic.code) ? {\n\t\t...diagnostic,\n\t\tcode: \"PSL.PRISMA7_RELATION_UNRESOLVED\"\n\t} : diagnostic);\n\tconst relations = /* @__PURE__ */ new Map();\n\tfor (const [modelName, nodes] of modelRelations) relations.set(modelName, [...nodes].sort((left, right) => left.fieldName.localeCompare(right.fieldName)));\n\treturn {\n\t\tjunctions,\n\t\tforeignKeys,\n\t\trelations\n\t};\n}\n/**\n* The id column a junction side contributes. The diagnostic names the\n* requesting relation field, so it is located at that field, whichever side's\n* id is at fault.\n*/\nfunction singleIdColumn(side, requester, diagnostics) {\n\tif (side.model.idFields.some((name) => side.model.ignoredFields.has(name) || side.model.rejectedFields.has(name))) return;\n\tconst [idField, ...rest] = side.model.idFields;\n\tconst column = idField === void 0 ? void 0 : side.model.columns.get(idField);\n\tif (column === void 0 || rest.length > 0) {\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_JUNCTION_ID_UNSUPPORTED\", `Relation field \"${requester.model.modelName}.${requester.field.field.name}\" is an implicit many-to-many relation, but \"${side.model.modelName}\" ${column === void 0 ? \"has no single-field @id\" : \"has a composite id\"}; Prisma 7 requires a single-field @id on both models of an implicit many-to-many relation.`, requester.model.sourceId, requester.field.field.span));\n\t\treturn;\n\t}\n\treturn column;\n}\n/**\n* Prisma 7's implicit junction: table `_AToB` (or `_Name`), columns `A` and `B`\n* typed like the two ids, primary key `(A, B)`, index `_AToB_B_index`, and two\n* cascading foreign keys, with relation fields named as `contract infer` names\n* them. `A` is the model whose name is smaller in plain\n* string order; for a self-relation, the field whose name is smaller. This is\n* prisma-engines' rule (`psl/parser-database/src/relations.rs`,\n* `ingest_relation`: the side with the greater model name, or field name for a\n* self relation, is skipped so the smaller one owns `field_a`).\n*/\nfunction synthesizeJunction(requester, partner, naming, diagnostics) {\n\tconst [sideA, sideB] = orderJunctionSides(requester, partner);\n\tconst requesterFirst = sideA === requester;\n\tconst name = requester.field.attribute?.name ?? `${sideA.model.modelName}To${sideB.model.modelName}`;\n\tconst idA = singleIdColumn(sideA, requester, diagnostics);\n\tconst idB = singleIdColumn(sideB, requester, diagnostics);\n\tif (idA === void 0 || idB === void 0) return void 0;\n\tconst tableName = prisma7ConstraintName(`_${name}`, \"\", naming.identifierMaxBytes);\n\tconst namespaceId = sideA.model.namespaceId;\n\tconst key = junctionKey(namespaceId, name);\n\tconst [relationFieldA, relationFieldB] = naming.junctionRelationFieldNames(sideA.model.tableName, sideB.model.tableName);\n\tconst foreignKey = (column, side, id) => ({\n\t\tcolumns: [column],\n\t\treferences: {\n\t\t\tmodel: side.model.modelName,\n\t\t\ttable: side.model.tableName,\n\t\t\tcolumns: [id.columnName],\n\t\t\tnamespaceId: side.model.namespaceId\n\t\t},\n\t\tonDelete: \"cascade\",\n\t\tonUpdate: \"cascade\",\n\t\tindex: false\n\t});\n\tconst metadata = (column, side, id) => ({\n\t\tdeclaringModelName: key,\n\t\tdeclaringFieldName: column === \"A\" ? relationFieldA : relationFieldB,\n\t\tdeclaringTableName: tableName,\n\t\tdeclaringNamespaceId: namespaceId,\n\t\ttargetModelName: side.model.modelName,\n\t\ttargetTableName: side.model.tableName,\n\t\ttargetNamespaceId: side.model.namespaceId,\n\t\trelationName: `${name}:${column}`,\n\t\tnullable: false,\n\t\tlocalColumns: [column],\n\t\treferencedColumns: [id.columnName]\n\t});\n\tconst index = {\n\t\tcolumns: [\"B\"],\n\t\ttype: void 0,\n\t\toptions: void 0,\n\t\twhere: void 0,\n\t\tunique: void 0,\n\t\tmap: prisma7ConstraintName(`_${name}`, \"_B_index\", naming.identifierMaxBytes),\n\t\tname: void 0\n\t};\n\treturn {\n\t\tkey,\n\t\tnode: {\n\t\t\tmodelName: name,\n\t\t\ttableName,\n\t\t\tnamespaceId,\n\t\t\tfields: [{\n\t\t\t\tfieldName: \"A\",\n\t\t\t\tcolumnName: \"A\",\n\t\t\t\tdescriptor: idA.descriptor,\n\t\t\t\tnullable: false\n\t\t\t}, {\n\t\t\t\tfieldName: \"B\",\n\t\t\t\tcolumnName: \"B\",\n\t\t\t\tdescriptor: idB.descriptor,\n\t\t\t\tnullable: false\n\t\t\t}],\n\t\t\tid: { columns: [\"A\", \"B\"] },\n\t\t\tindexes: [index],\n\t\t\tforeignKeys: [foreignKey(\"A\", sideA, idA), foreignKey(\"B\", sideB, idB)]\n\t\t},\n\t\tforeignKeys: [metadata(\"A\", sideA, idA), metadata(\"B\", sideB, idB)],\n\t\tcandidateRelationName: requesterFirst ? `${name}:A` : `${name}:B`\n\t};\n}\n//#endregion\n//#region src/interpreter.ts\nconst SUMMARY = \"Prisma 7 schema interpretation failed\";\nconst EMPTY_DESCRIPTORS = /* @__PURE__ */ new Map();\nfunction attributeText(attribute) {\n\tconst args = attribute.args.map((arg) => arg.kind === \"named\" ? `${arg.name}: ${arg.value}` : arg.value);\n\treturn args.length === 0 ? `@${attribute.name}` : `@${attribute.name}(${args.join(\", \")})`;\n}\nfunction stringArgument(attribute) {\n\tconst expression = (attribute.args.find((arg) => arg.kind === \"positional\") ?? attribute.args.find((arg) => arg.name === \"name\"))?.expression;\n\tif (expression === void 0) return void 0;\n\treturn StringLiteralExprAst.cast(expression.syntax)?.value();\n}\nfunction scalarValue(block, key) {\n\tconst parameter = block.parameters[key];\n\tif (parameter?.kind !== \"value\") return void 0;\n\ttry {\n\t\tconst parsed = JSON.parse(parameter.raw);\n\t\treturn typeof parsed === \"string\" ? parsed : void 0;\n\t} catch {\n\t\treturn;\n\t}\n}\nfunction parameterSpan(block, key) {\n\tconst parameter = block.parameters[key];\n\treturn parameter === void 0 ? block.span : parameter.span;\n}\nfunction interpretPrisma7Documents(input) {\n\tconst { binding } = input;\n\tconst diagnostics = [...input.seedDiagnostics];\n\tconst defaultNamespaceId = binding.target.defaultNamespaceId;\n\tconst datasources = [];\n\tconst enumBlocks = [];\n\tconst models = [];\n\tconst ignoredModels = /* @__PURE__ */ new Set();\n\tconst declaredNames = /* @__PURE__ */ new Map();\n\tconst claimName = (kind, name, sourceId, span) => {\n\t\tconst previous = declaredNames.get(name);\n\t\tif (previous === void 0) {\n\t\t\tdeclaredNames.set(name, sourceId);\n\t\t\treturn true;\n\t\t}\n\t\tdiagnostics.push({\n\t\t\tcode: \"PSL_DUPLICATE_DECLARATION\",\n\t\t\tmessage: `Duplicate declaration of ${kind} \"${name}\"; first declared in ${basename(previous)}.`,\n\t\t\tsourceId,\n\t\t\tspan\n\t\t});\n\t\treturn false;\n\t};\n\tfor (const { document, sourceFile, sourceId } of input.documents) {\n\t\tconst { table, diagnostics: tableDiagnostics } = buildSymbolTable({\n\t\t\tdocument,\n\t\t\tsourceFile,\n\t\t\tpslBlockDescriptors: {}\n\t\t});\n\t\tfor (const diagnostic of tableDiagnostics) diagnostics.push({\n\t\t\tcode: diagnostic.code,\n\t\t\tmessage: diagnostic.message,\n\t\t\tsourceId,\n\t\t\tspan: rangeToPslSpan(diagnostic.range, sourceFile)\n\t\t});\n\t\tconst unsupported = (keyword, span) => {\n\t\t\tdiagnostics.push({\n\t\t\t\tcode: \"PSL_UNSUPPORTED_TOP_LEVEL_BLOCK\",\n\t\t\t\tmessage: `Unsupported top-level block \"${keyword}\"`,\n\t\t\t\tsourceId,\n\t\t\t\tspan\n\t\t\t});\n\t\t};\n\t\tfor (const block of Object.values(table.topLevel.blocks)) switch (block.keyword) {\n\t\t\tcase \"datasource\":\n\t\t\t\tdatasources.push({\n\t\t\t\t\tblock,\n\t\t\t\t\tsourceId,\n\t\t\t\t\tsourceFile\n\t\t\t\t});\n\t\t\t\tbreak;\n\t\t\tcase \"generator\": break;\n\t\t\tcase \"enum\":\n\t\t\t\tif (claimName(\"enum\", block.name, sourceId, block.span)) enumBlocks.push({\n\t\t\t\t\tblock,\n\t\t\t\t\tsourceId,\n\t\t\t\t\tsourceFile\n\t\t\t\t});\n\t\t\t\tbreak;\n\t\t\tcase \"view\":\n\t\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_VIEW_UNSUPPORTED\", `View \"${block.name}\" is not supported; Prisma 8 has no views. Remove the view or replace it with a model over the underlying table.`, sourceId, keywordPslSpan(block.node.syntax, block.keyword, sourceFile)));\n\t\t\t\tbreak;\n\t\t\tdefault: unsupported(block.keyword, keywordPslSpan(block.node.syntax, block.keyword, sourceFile));\n\t\t}\n\t\tfor (const namespace of Object.values(table.topLevel.namespaces)) for (const { span } of namespace.declarations) unsupported(\"namespace\", span);\n\t\tfor (const compositeType of Object.values(table.topLevel.compositeTypes)) unsupported(\"type\", compositeType.span);\n\t\tfor (const namedType of Object.values(table.topLevel.namedTypes)) unsupported(\"types\", namedType.span);\n\t\tfor (const symbol of Object.values(table.topLevel.models)) {\n\t\t\tif (!claimName(\"model\", symbol.name, sourceId, symbol.span)) continue;\n\t\t\tconst declaration = readModelDeclaration(symbol, sourceId, defaultNamespaceId, binding.indexTypes, diagnostics);\n\t\t\tif (declaration === void 0) ignoredModels.add(symbol.name);\n\t\t\telse models.push(declaration);\n\t\t}\n\t}\n\tcheckDatasource(datasources, input.documents[0]?.sourceId ?? \"schema.prisma\", binding, diagnostics);\n\treportTableCollisions(models, diagnostics);\n\tconst enums = /* @__PURE__ */ new Map();\n\tfor (const source of enumBlocks) {\n\t\tconst declaration = readEnumDeclaration(source, defaultNamespaceId, diagnostics);\n\t\tif (declaration !== void 0) enums.set(declaration.name, declaration);\n\t}\n\tconst namespaceEntities = lowerNativeEnums(enums, input, diagnostics);\n\tconst modelNames = /* @__PURE__ */ new Set([...models.map((model) => model.symbol.name), ...ignoredModels]);\n\tconst scalarColumnDescriptors = collectScalarTypeConstructors(input.authoringContributions.type);\n\tconst composedExtensions = new Set(input.composedExtensions);\n\tconst builds = /* @__PURE__ */ new Map();\n\tfor (const declaration of models) {\n\t\tconst build = {\n\t\t\tdeclaration,\n\t\t\tcolumns: /* @__PURE__ */ new Map(),\n\t\t\tignoredFields: /* @__PURE__ */ new Set(),\n\t\t\tignoredRelationFields: [],\n\t\t\trejectedFields: /* @__PURE__ */ new Set(),\n\t\t\tidFields: declaration.id?.fields ?? [],\n\t\t\tuniqueIndexes: [...declaration.uniqueIndexes],\n\t\t\trelationFields: []\n\t\t};\n\t\tfor (const field of Object.values(declaration.symbol.fields)) {\n\t\t\tconst reported = diagnostics.length;\n\t\t\treadField({\n\t\t\t\tfield,\n\t\t\t\tbuild,\n\t\t\t\tmodelNames,\n\t\t\t\tignoredModels,\n\t\t\t\tenums,\n\t\t\t\tnamespaceEntities,\n\t\t\t\tscalarColumnDescriptors,\n\t\t\t\tcomposedExtensions,\n\t\t\t\tinput,\n\t\t\t\tdiagnostics\n\t\t\t});\n\t\t\tif (diagnostics.length > reported && !build.columns.has(field.name) && !build.ignoredFields.has(field.name)) build.rejectedFields.add(field.name);\n\t\t}\n\t\tbuilds.set(declaration.symbol.name, build);\n\t}\n\tconst relationModels = /* @__PURE__ */ new Map();\n\tfor (const [modelName, build] of builds) relationModels.set(modelName, {\n\t\tmodelName,\n\t\ttableName: build.declaration.tableName,\n\t\ttableSpan: build.declaration.symbol.attributes.find((attribute) => attribute.name === \"map\")?.span ?? build.declaration.symbol.span,\n\t\tnamespaceId: build.declaration.namespaceId,\n\t\tsourceId: build.declaration.sourceId,\n\t\tcolumns: build.columns,\n\t\tignoredFields: build.ignoredFields,\n\t\tignoredRelationFields: build.ignoredRelationFields,\n\t\trejectedFields: build.rejectedFields,\n\t\tidFields: build.idFields,\n\t\tuniqueFieldSets: build.uniqueIndexes.flatMap((index) => index.fields === void 0 ? [] : [index.fields]),\n\t\trelationFields: build.relationFields\n\t});\n\tconst lowered = lowerRelations(relationModels, binding, diagnostics);\n\tconst modelNodes = [];\n\tfor (const [modelName, build] of builds) {\n\t\tconst model = relationModels.get(modelName);\n\t\tif (model === void 0) continue;\n\t\tconst ignoredAmong = (fieldNames) => fieldNames?.filter((name) => build.ignoredFields.has(name)) ?? [];\n\t\tconst idAttribute = build.declaration.id;\n\t\tconst ignoredIdFields = ignoredAmong(idAttribute?.fields);\n\t\tif (idAttribute !== void 0 && ignoredIdFields.length > 0) diagnostics.push(ignoredFieldReferenced({\n\t\t\tmodelName,\n\t\t\tfieldNames: ignoredIdFields,\n\t\t\tusedBy: `@@id on model \"${modelName}\"`,\n\t\t\tconstraint: \"primary key\",\n\t\t\tsourceId: model.sourceId,\n\t\t\tspan: idAttribute.span\n\t\t}));\n\t\tconst id = keyColumns(model, model.idFields);\n\t\tconst indexes = [...build.uniqueIndexes.map((attribute) => ({\n\t\t\tattribute,\n\t\t\tunique: true\n\t\t})), ...build.declaration.indexes.map((attribute) => ({\n\t\t\tattribute,\n\t\t\tunique: false\n\t\t}))].flatMap(({ attribute, unique }) => {\n\t\t\tconst ignoredIndexFields = ignoredAmong(attribute.fields);\n\t\t\tif (ignoredIndexFields.length > 0) {\n\t\t\t\tdiagnostics.push(ignoredFieldReferenced({\n\t\t\t\t\tmodelName,\n\t\t\t\t\tfieldNames: ignoredIndexFields,\n\t\t\t\t\tusedBy: `${unique ? \"@@unique\" : \"@@index\"} on model \"${modelName}\"`,\n\t\t\t\t\tconstraint: unique ? \"unique index\" : \"index\",\n\t\t\t\t\tsourceId: model.sourceId,\n\t\t\t\t\tspan: attribute.span\n\t\t\t\t}));\n\t\t\t\treturn [];\n\t\t\t}\n\t\t\tif (attribute.fields?.some((name) => build.rejectedFields.has(name))) return [];\n\t\t\tconst columns = attribute.fields === void 0 ? void 0 : keyColumns(model, attribute.fields);\n\t\t\tif (columns === void 0) {\n\t\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_INDEX_ARGUMENT_UNSUPPORTED\", `Model \"${modelName}\": an index names a field that is not a scalar column of the model.`, model.sourceId, attribute.span));\n\t\t\t\treturn [];\n\t\t\t}\n\t\t\treturn [indexNode(model.tableName, columns, attribute, unique, binding.identifierMaxBytes)];\n\t\t});\n\t\tconst foreignKeys = lowered.foreignKeys.get(modelName);\n\t\tconst relations = lowered.relations.get(modelName);\n\t\tmodelNodes.push({\n\t\t\tmodelName,\n\t\t\ttableName: model.tableName,\n\t\t\tnamespaceId: model.namespaceId,\n\t\t\tfields: [...build.columns.values()],\n\t\t\t...id !== void 0 && id.length > 0 ? { id: { columns: id } } : {},\n\t\t\t...indexes.length > 0 ? { indexes } : {},\n\t\t\t...foreignKeys !== void 0 ? { foreignKeys } : {},\n\t\t\t...relations !== void 0 ? { relations } : {}\n\t\t});\n\t}\n\tfor (const [key, junction] of lowered.junctions) {\n\t\tconst relations = lowered.relations.get(key);\n\t\tmodelNodes.push(relations === void 0 ? junction : {\n\t\t\t...junction,\n\t\t\trelations\n\t\t});\n\t}\n\tif (diagnostics.length > 0) return notOk({\n\t\tsummary: SUMMARY,\n\t\tdiagnostics\n\t});\n\tconst createNamespace = (namespace) => {\n\t\tconst entities = namespaceEntities.get(namespace.id);\n\t\tif (entities === void 0) return binding.createNamespace(namespace);\n\t\tconst valueSet = {\n\t\t\t...namespace.entries[\"valueSet\"],\n\t\t\t...entities[\"valueSet\"]\n\t\t};\n\t\treturn binding.createNamespace({\n\t\t\t...namespace,\n\t\t\tentries: {\n\t\t\t\t...namespace.entries,\n\t\t\t\t...entities,\n\t\t\t\t...Object.keys(valueSet).length > 0 ? { valueSet } : {}\n\t\t\t}\n\t\t});\n\t};\n\treturn ok(buildSqlContractFromDefinition({\n\t\ttarget: binding.target,\n\t\twarnings: void 0,\n\t\tcreateNamespace,\n\t\t...namespaceEntities.size > 0 ? { namespaces: [...namespaceEntities.keys()] } : {},\n\t\tmodels: modelNodes\n\t}, input.codecLookup));\n}\nfunction checkDatasource(datasources, fallbackSourceId, binding, diagnostics) {\n\tconst [datasource] = datasources;\n\tconst [namedProvider] = binding.providers;\n\tif (datasource === void 0) {\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_PROVIDER_MISMATCH\", `No datasource block found; add \\`datasource db { provider = \"${namedProvider}\" }\\`.`, fallbackSourceId, void 0));\n\t\treturn;\n\t}\n\tconst block = datasource.block.block;\n\tconst provider = scalarValue(block, \"provider\");\n\tif (provider === void 0 || !binding.providers.includes(provider)) diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_PROVIDER_MISMATCH\", provider === void 0 ? `The datasource block declares no string \\`provider\\`; this contract source reads Prisma 7 schemas for provider \"${namedProvider}\".` : `The datasource provider is \"${provider}\"; this contract source reads Prisma 7 schemas for provider \"${namedProvider}\".`, datasource.sourceId, parameterSpan(block, \"provider\")));\n\tfor (const [property, edit] of Object.entries({\n\t\trelationMode: \"Removing relationMode, or setting it to \\\"foreignKeys\\\"\",\n\t\treferentialIntegrity: \"Removing referentialIntegrity, or replacing it with relationMode = \\\"foreignKeys\\\"\"\n\t})) {\n\t\tif (scalarValue(block, property) !== \"prisma\") continue;\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_RELATION_MODE_UNSUPPORTED\", `${property} = \"prisma\" is not supported: the contract declares the foreign keys its relations need, and in this mode Prisma 7 creates none. ${edit}, makes Prisma 7's next migration add those foreign keys, and that migration fails if any existing row breaks one.`, datasource.sourceId, parameterSpan(block, property)));\n\t}\n}\nfunction reportTableCollisions(models, diagnostics) {\n\tconst byTable = /* @__PURE__ */ new Map();\n\tfor (const model of models) {\n\t\tconst key = `${model.namespaceId}.${model.tableName}`;\n\t\tconst group = byTable.get(key) ?? [];\n\t\tbyTable.set(key, group);\n\t\tgroup.push(model);\n\t}\n\tfor (const group of byTable.values()) {\n\t\tif (group.length < 2) continue;\n\t\tconst names = group.map((model) => `\"${model.symbol.name}\"`).join(\", \");\n\t\tfor (const model of group) {\n\t\t\tconst mapAttribute = model.symbol.attributes.find((attribute) => attribute.name === \"map\");\n\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_TABLE_COLLISION\", `Models ${names} all map to table \"${model.namespaceId}\".\"${model.tableName}\"; each model needs its own table.`, model.sourceId, mapAttribute?.span ?? model.symbol.span));\n\t\t}\n\t}\n}\nfunction keyColumns(model, fieldNames) {\n\tconst columns = [];\n\tfor (const fieldName of fieldNames) {\n\t\tconst column = model.columns.get(fieldName);\n\t\tif (column === void 0) return void 0;\n\t\tcolumns.push(column.columnName);\n\t}\n\treturn columns;\n}\nfunction readModelDeclaration(symbol, sourceId, defaultNamespaceId, indexTypes, diagnostics) {\n\tif (symbol.attributes.some((attribute) => attribute.name === \"ignore\")) return void 0;\n\tlet tableName = symbol.name;\n\tlet namespaceId = defaultNamespaceId;\n\tlet id;\n\tconst uniqueIndexes = [];\n\tconst indexes = [];\n\tfor (const attribute of symbol.attributes) switch (attribute.name) {\n\t\tcase \"map\":\n\t\t\ttableName = requireStringArgument(attribute, symbol.name, sourceId, diagnostics) ?? tableName;\n\t\t\tbreak;\n\t\tcase \"schema\":\n\t\t\tnamespaceId = requireStringArgument(attribute, symbol.name, sourceId, diagnostics) ?? namespaceId;\n\t\t\tbreak;\n\t\tcase \"id\": {\n\t\t\tconst parsed = parseIndexAttribute(attribute, symbol.name, sourceId, indexTypes, diagnostics);\n\t\t\tif (parsed?.fields !== void 0) id = parsed;\n\t\t\tbreak;\n\t\t}\n\t\tcase \"unique\": {\n\t\t\tconst parsed = parseIndexAttribute(attribute, symbol.name, sourceId, indexTypes, diagnostics);\n\t\t\tif (parsed?.fields !== void 0) uniqueIndexes.push(parsed);\n\t\t\tbreak;\n\t\t}\n\t\tcase \"index\": {\n\t\t\tconst parsed = parseIndexAttribute(attribute, symbol.name, sourceId, indexTypes, diagnostics);\n\t\t\tif (parsed?.fields !== void 0) indexes.push(parsed);\n\t\t\tbreak;\n\t\t}\n\t\tdefault: diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_ATTRIBUTE\", `Model \"${symbol.name}\": attribute \"@@${attribute.name}\" is not supported yet by the Prisma 7 contract source.`, sourceId, attribute.span));\n\t}\n\treturn {\n\t\tsymbol,\n\t\tsourceId,\n\t\tnamespaceId,\n\t\ttableName,\n\t\tid,\n\t\tuniqueIndexes,\n\t\tindexes\n\t};\n}\nfunction requireStringArgument(attribute, owner, sourceId, diagnostics) {\n\tconst value = stringArgument(attribute);\n\tif (value === void 0) diagnostics.push({\n\t\tcode: \"PSL_INVALID_ATTRIBUTE_ARGUMENT\",\n\t\tmessage: `\"${owner}\": attribute \"${attribute.name}\" expects one string argument.`,\n\t\tsourceId,\n\t\tspan: attribute.span\n\t});\n\treturn value;\n}\nfunction readEnumDeclaration(source, defaultNamespaceId, diagnostics) {\n\tconst { block, sourceId, sourceFile } = source;\n\tlet typeName = block.name;\n\tlet namespaceId = defaultNamespaceId;\n\tfor (const attribute of readResolvedAttributes(block.node.attributes(), sourceFile)) switch (attribute.name) {\n\t\tcase \"map\":\n\t\t\ttypeName = requireStringArgument(attribute, block.name, sourceId, diagnostics) ?? typeName;\n\t\t\tbreak;\n\t\tcase \"schema\":\n\t\t\tnamespaceId = requireStringArgument(attribute, block.name, sourceId, diagnostics) ?? namespaceId;\n\t\t\tbreak;\n\t\tdefault: diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_ATTRIBUTE\", `Enum \"${block.name}\": attribute \"@@${attribute.name}\" is not supported by the Prisma 7 contract source.`, sourceId, attribute.span));\n\t}\n\tconst members = [];\n\tfor (const entry of block.node.entries()) {\n\t\tconst name = entry.key()?.name();\n\t\tif (name === void 0) continue;\n\t\tlet value = name;\n\t\tconst span = nodePslSpan(entry.syntax, sourceFile);\n\t\tfor (const attributeNode of entry.attributes()) {\n\t\t\tconst attribute = readResolvedAttribute(attributeNode, sourceFile);\n\t\t\tif (attribute.name === \"map\") value = requireStringArgument(attribute, `${block.name}.${name}`, sourceId, diagnostics) ?? value;\n\t\t\telse diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_ATTRIBUTE\", `Enum member \"${block.name}.${name}\": attribute \"@${attribute.name}\" is not supported by the Prisma 7 contract source.`, sourceId, attribute.span));\n\t\t}\n\t\tmembers.push({\n\t\t\tname,\n\t\t\tvalue,\n\t\t\tspan\n\t\t});\n\t}\n\treturn {\n\t\tname: block.name,\n\t\ttypeName,\n\t\tnamespaceId,\n\t\tmembers,\n\t\tspan: block.span,\n\t\tsourceId\n\t};\n}\nfunction lowerNativeEnums(enums, input, diagnostics) {\n\tconst result = /* @__PURE__ */ new Map();\n\tif (enums.size === 0) return result;\n\tconst { entityKind } = input.binding.nativeEnum;\n\tconst descriptor = buildEntityTypesByDiscriminator(input.authoringContributions).get(entityKind);\n\tfor (const declaration of enums.values()) {\n\t\tif (descriptor === void 0) {\n\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNSUPPORTED_TYPE\", `Enum \"${declaration.name}\" cannot be lowered: target \"${input.binding.target.targetId}\" registers no \"${entityKind}\" entity kind.`, declaration.sourceId, declaration.span));\n\t\t\tcontinue;\n\t\t}\n\t\tconst context = {\n\t\t\tfamily: input.binding.target.familyId,\n\t\t\ttarget: input.binding.target.targetId,\n\t\t\tcodecLookup: input.codecLookup,\n\t\t\tsourceId: declaration.sourceId,\n\t\t\tdiagnostics: { push: (diagnostic) => {\n\t\t\t\tdiagnostics.push(blindCast(diagnostic));\n\t\t\t} }\n\t\t};\n\t\tconst entity = instantiateAuthoringEntityType(entityKind, descriptor, [{\n\t\t\tkind: entityKind,\n\t\t\tkeyword: entityKind,\n\t\t\tname: declaration.name,\n\t\t\tparameters: Object.fromEntries(declaration.members.map((member) => [member.name, {\n\t\t\t\tkind: \"value\",\n\t\t\t\traw: JSON.stringify(member.value),\n\t\t\t\tspan: member.span\n\t\t\t}])),\n\t\t\tblockAttributes: [],\n\t\t\tattributes: { map: {\n\t\t\t\targs: { name: declaration.typeName },\n\t\t\t\tspan: declaration.span\n\t\t\t} },\n\t\t\tspan: declaration.span,\n\t\t\tnamespaceId: declaration.namespaceId\n\t\t}], context);\n\t\tif (entity === void 0) continue;\n\t\tconst entities = result.get(declaration.namespaceId) ?? {};\n\t\tresult.set(declaration.namespaceId, entities);\n\t\tentities[entityKind] = {\n\t\t\t...entities[entityKind],\n\t\t\t[declaration.name]: entity\n\t\t};\n\t\tconst valueSet = deriveValueSetFromEntity(descriptor.output, entity);\n\t\tif (valueSet !== void 0) entities[\"valueSet\"] = {\n\t\t\t...entities[\"valueSet\"],\n\t\t\t[declaration.name]: valueSet\n\t\t};\n\t}\n\treturn result;\n}\nfunction keysUsingField(field, model) {\n\tconst modelName = model.symbol.name;\n\tconst uses = [];\n\tfor (const attribute of field.attributes) {\n\t\tif (attribute.name === \"id\") uses.push({\n\t\t\tusedBy: \"its @id\",\n\t\t\tconstraint: \"primary key\"\n\t\t});\n\t\tif (attribute.name === \"unique\") uses.push({\n\t\t\tusedBy: \"its @unique\",\n\t\t\tconstraint: \"unique index\"\n\t\t});\n\t}\n\tif (model.id?.fields?.includes(field.name)) uses.push({\n\t\tusedBy: `@@id on model \"${modelName}\"`,\n\t\tconstraint: \"primary key\"\n\t});\n\tfor (const unique of model.uniqueIndexes) if (unique.fields?.includes(field.name)) uses.push({\n\t\tusedBy: `@@unique on model \"${modelName}\"`,\n\t\tconstraint: \"unique index\"\n\t});\n\tfor (const index of model.indexes) if (index.fields?.includes(field.name)) uses.push({\n\t\tusedBy: `@@index on model \"${modelName}\"`,\n\t\tconstraint: \"index\"\n\t});\n\tfor (const other of Object.values(model.symbol.fields)) {\n\t\tif (other.attributes.some((attribute) => attribute.name === \"ignore\")) continue;\n\t\tconst relation = other.attributes.find((attribute) => attribute.name === \"relation\");\n\t\tif ((relation === void 0 ? void 0 : parseRelationAttribute(relation, other.name, model.sourceId, []))?.fields?.includes(field.name)) uses.push({\n\t\t\tusedBy: `relation field \"${modelName}.${other.name}\"`,\n\t\t\tconstraint: \"foreign key\"\n\t\t});\n\t}\n\treturn uses;\n}\nfunction nativeTypeMessage(input) {\n\tconst { label, nativeType, field, model } = input;\n\tconst uses = keysUsingField(field, model);\n\tif (uses.length > 0) {\n\t\tconst constraints = [...new Set(uses.map((use) => `the ${use.constraint}`))];\n\t\treturn `${label}: native type \"@db.${nativeType}\" has no Prisma 8 codec, and ${andList(uses.map((use) => use.usedBy))} ${uses.length === 1 ? \"uses\" : \"use\"} the field, so @ignore on the field does not help: Prisma 7 still creates ${andList(constraints)} over the column. Add @@ignore to model \"${model.symbol.name}\" to keep the model out of the contract: Prisma 7's next migration is empty, but the model disappears from the Prisma 7 client too, and every relation field in another model that points to it needs @ignore, which removes that field from the Prisma 7 client as well. Changing the field's type instead changes the column type on Prisma 7's next migration.`;\n\t}\n\treturn `${label}: native type \"@db.${nativeType}\" has no Prisma 8 codec. Add @ignore to the field to keep its column out of the contract: Prisma 7's next migration is empty, and the field disappears from the Prisma 7 client too${!field.optional && !field.list && !givesColumnDefault(input.defaultAttribute) ? \"; because the field is required and its column has no default, neither client can then insert rows\" : \"\"}. Changing the field's type instead changes the column type on Prisma 7's next migration.`;\n}\nfunction readIgnoredField(field, isRelationField, args) {\n\tconst { build, diagnostics } = args;\n\tconst model = build.declaration;\n\tif (isRelationField) {\n\t\tif (args.ignoredModels.has(field.typeName)) return;\n\t\tconst relation = field.attributes.find((attribute) => attribute.name === \"relation\");\n\t\tbuild.ignoredRelationFields.push({\n\t\t\tfield,\n\t\t\ttargetModelName: field.typeName,\n\t\t\tattribute: relation === void 0 ? void 0 : parseRelationAttribute(relation, field.name, model.sourceId, [])\n\t\t});\n\t\treturn;\n\t}\n\tfor (const attribute of field.attributes) {\n\t\tif (attribute.name !== \"id\" && attribute.name !== \"unique\") continue;\n\t\tif (attribute.name === \"id\") build.idFields = [field.name];\n\t\tdiagnostics.push(ignoredFieldReferenced({\n\t\t\tmodelName: model.symbol.name,\n\t\t\tfieldNames: [field.name],\n\t\t\tusedBy: `its @${attribute.name}`,\n\t\t\tconstraint: attribute.name === \"id\" ? \"primary key\" : \"unique index\",\n\t\t\tsourceId: model.sourceId,\n\t\t\tspan: attribute.span\n\t\t}));\n\t}\n}\nfunction readField(args) {\n\tconst { field, build, diagnostics, input } = args;\n\tconst { binding } = input;\n\tconst model = build.declaration;\n\tconst sourceId = model.sourceId;\n\tconst label = `Field \"${model.symbol.name}.${field.name}\"`;\n\tconst isRelationField = args.modelNames.has(field.typeName) && field.typeConstructor === void 0;\n\tif (field.attributes.some((attribute) => attribute.name === \"ignore\")) {\n\t\tbuild.ignoredFields.add(field.name);\n\t\treadIgnoredField(field, isRelationField, args);\n\t\treturn;\n\t}\n\tlet columnName = field.name;\n\tlet nativeType;\n\tlet relation;\n\tlet defaultAttribute;\n\tlet updatedAt;\n\tfor (const attribute of field.attributes) if (attribute.name === \"map\" && !isRelationField) columnName = requireStringArgument(attribute, label, sourceId, diagnostics) ?? columnName;\n\telse if (attribute.name.startsWith(\"db.\") && !isRelationField) nativeType = {\n\t\tname: attribute.name.slice(3),\n\t\tattribute\n\t};\n\telse if (attribute.name === \"id\" && !isRelationField) {\n\t\tif (parseIndexAttribute(attribute, label, sourceId, binding.indexTypes, diagnostics) !== void 0) build.idFields = [field.name];\n\t} else if (attribute.name === \"unique\" && !isRelationField) {\n\t\tconst parsed = parseIndexAttribute(attribute, label, sourceId, binding.indexTypes, diagnostics);\n\t\tif (parsed !== void 0) build.uniqueIndexes.push({\n\t\t\t...parsed,\n\t\t\tfields: [field.name]\n\t\t});\n\t} else if (attribute.name === \"default\" && !isRelationField) defaultAttribute = attribute;\n\telse if (attribute.name === \"updatedAt\" && !isRelationField) updatedAt = attribute;\n\telse if (attribute.name === \"relation\" && isRelationField) relation = attribute;\n\telse diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNKNOWN_ATTRIBUTE\", `${label}: attribute \"@${attribute.name}\" is not supported yet by the Prisma 7 contract source.`, sourceId, attribute.span));\n\tif (field.malformedType) return;\n\tif (field.typeConstructor !== void 0) {\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNSUPPORTED_TYPE\", `${label} has type \"${field.typeConstructor.path.join(\".\")}(...)\", which has no Prisma 8 codec, so model \"${model.symbol.name}\" cannot use this contract source while it has the field. Prisma 7 rejects @ignore on an Unsupported field, and removing the field drops its column on Prisma 7's next migration. Adding @@ignore to model \"${model.symbol.name}\" keeps the model out of the contract: Prisma 7's next migration is empty, but the model disappears from the Prisma 7 client too, and every relation field in another model that points to it needs @ignore, which removes that field from the Prisma 7 client as well.`, sourceId, field.typeConstructor.span));\n\t\treturn;\n\t}\n\tif (args.ignoredModels.has(field.typeName)) return;\n\tif (isRelationField) {\n\t\tconst attribute = relation === void 0 ? void 0 : parseRelationAttribute(relation, label, sourceId, diagnostics);\n\t\tif (relation !== void 0 && attribute === void 0) return;\n\t\tbuild.relationFields.push({\n\t\t\tfield,\n\t\t\ttargetModelName: field.typeName,\n\t\t\tattribute\n\t\t});\n\t\treturn;\n\t}\n\tconst enumDeclaration = args.enums.get(field.typeName);\n\tlet call;\n\tif (enumDeclaration !== void 0) {\n\t\tif (enumDeclaration.namespaceId !== model.namespaceId) {\n\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_ENUM_NAMESPACE_MISMATCH\", `${label} uses enum \"${enumDeclaration.name}\" from schema \"${enumDeclaration.namespaceId}\", but the model is in schema \"${model.namespaceId}\". Prisma 8 columns reference the enum type of their own schema; declare the enum in \"${model.namespaceId}\" or move the model.`, sourceId, field.span));\n\t\t\treturn;\n\t\t}\n\t\tcall = {\n\t\t\tpath: binding.nativeEnum.typeConstructor,\n\t\t\targs: [{\n\t\t\t\tkind: \"positional\",\n\t\t\t\tvalue: enumDeclaration.name,\n\t\t\t\tspan: field.span\n\t\t\t}],\n\t\t\tspan: field.span\n\t\t};\n\t} else {\n\t\tconst scalar = prisma7ScalarMapping(binding.typeMap, field.typeName);\n\t\tif (scalar === void 0) {\n\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNSUPPORTED_TYPE\", `${label} has unknown type \"${field.typeName}\".`, sourceId, field.span));\n\t\t\treturn;\n\t\t}\n\t\tlet mapping = scalar;\n\t\tlet span = field.span;\n\t\tif (nativeType !== void 0) {\n\t\t\tconst native = prisma7NativeTypeMapping(binding.typeMap, nativeType.name, nativeType.attribute.args.map((arg) => arg.value));\n\t\t\tif (native === void 0) {\n\t\t\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_NATIVE_TYPE_UNSUPPORTED\", nativeTypeMessage({\n\t\t\t\t\tlabel,\n\t\t\t\t\tnativeType: nativeType.name,\n\t\t\t\t\tfield,\n\t\t\t\t\tmodel,\n\t\t\t\t\tdefaultAttribute\n\t\t\t\t}), sourceId, nativeType.attribute.span));\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tmapping = native;\n\t\t\tspan = nativeType.attribute.span;\n\t\t}\n\t\tcall = {\n\t\t\tpath: [mapping.constructorName],\n\t\t\targs: mapping.args.map((value) => ({\n\t\t\t\tkind: \"positional\",\n\t\t\t\tvalue,\n\t\t\t\tspan\n\t\t\t})),\n\t\t\tspan\n\t\t};\n\t}\n\tconst namespaceExtensionEntities = args.namespaceEntities.get(model.namespaceId);\n\tconst resolved = resolveFieldTypeDescriptor({\n\t\tfield: {\n\t\t\t...field,\n\t\t\ttypeConstructor: call\n\t\t},\n\t\tenumTypeDescriptors: EMPTY_DESCRIPTORS,\n\t\tnamedTypeDescriptors: EMPTY_DESCRIPTORS,\n\t\tscalarColumnDescriptors: args.scalarColumnDescriptors,\n\t\tauthoringContributions: input.authoringContributions,\n\t\tcomposedExtensions: args.composedExtensions,\n\t\tfamilyId: binding.target.familyId,\n\t\ttargetId: binding.target.targetId,\n\t\tdiagnostics,\n\t\tsourceId,\n\t\tentityLabel: label,\n\t\tnamespaceId: model.namespaceId,\n\t\t...ifDefined(\"namespaceExtensionEntities\", namespaceExtensionEntities),\n\t\tcodecLookup: input.codecLookup\n\t});\n\tif (!resolved.ok) {\n\t\tif (!resolved.alreadyReported) diagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UNSUPPORTED_TYPE\", `${label} type \"${field.typeName}\" could not be resolved against target \"${binding.target.targetId}\".`, sourceId, field.span));\n\t\treturn;\n\t}\n\tconst updatedAtGeneratorId = updatedAt === void 0 ? void 0 : binding.updatedAtGeneratorId(resolved.descriptor.codecId);\n\tif (updatedAt !== void 0 && updatedAtGeneratorId === void 0) {\n\t\tconst withoutUpdatedAt = defaultAttribute !== void 0 && givesColumnDefault(defaultAttribute) ? `. Its ${attributeText(defaultAttribute)} still sets the value on create, and neither client changes it on update.` : field.optional ? \", but neither client then fills the value, so it stays empty unless a client writes it, and updates leave it unchanged.\" : \", but neither client then fills the value, so both require it on create and leave it unchanged on update.\";\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UPDATED_AT_TYPE_UNSUPPORTED\", `${label}: @updatedAt is not supported on this column, because Prisma 8 has no generator for column type \"${resolved.descriptor.nativeType}\" yet. Remove @updatedAt: Prisma 7's next migration is empty${withoutUpdatedAt}`, sourceId, updatedAt.span));\n\t\treturn;\n\t}\n\tif (updatedAt !== void 0 && defaultAttribute !== void 0) {\n\t\tconst written = attributeText(defaultAttribute);\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_UPDATED_AT_WITH_DEFAULT_UNSUPPORTED\", `${label} combines @updatedAt with ${written}, which Prisma 8 cannot express yet. Remove ${written}: @updatedAt still sets the value on create and on update, and Prisma 7's next migration removes the column default.`, sourceId, defaultAttribute.span));\n\t\treturn;\n\t}\n\tconst lowered = defaultAttribute === void 0 ? void 0 : lowerPrisma7Default({\n\t\tattribute: defaultAttribute,\n\t\tfield,\n\t\tmodelName: model.symbol.name,\n\t\tcodecId: resolved.descriptor.codecId,\n\t\tcodecLookup: input.codecLookup,\n\t\tliteralForm: binding.literalDefaultForm(resolved.descriptor),\n\t\tenumMembers: enumDeclaration === void 0 ? void 0 : new Map(enumDeclaration.members.map((member) => [member.name, member.value])),\n\t\tcontrolMutationDefaults: input.controlMutationDefaults,\n\t\tsourceId,\n\t\tdiagnostics\n\t});\n\tif (defaultAttribute !== void 0 && lowered === void 0) return;\n\tconst updatedAtGenerator = updatedAtGeneratorId === void 0 ? void 0 : {\n\t\tkind: \"generator\",\n\t\tid: updatedAtGeneratorId\n\t};\n\tconst generator = updatedAtGenerator ?? lowered?.onCreate;\n\tconst generatingAttribute = updatedAt ?? defaultAttribute;\n\tif (generator !== void 0 && generatingAttribute !== void 0 && field.optional) {\n\t\tconst written = attributeText(generatingAttribute);\n\t\tdiagnostics.push(prisma7Diagnostic(\"PSL.PRISMA7_OPTIONAL_GENERATED_FIELD_UNSUPPORTED\", `${label} is optional and its value comes from ${written}, which Prisma 8 cannot express on an optional field yet. Remove ${written} and keep the \"?\": the database does not change, and both clients then stop filling the value.`, sourceId, generatingAttribute.span));\n\t\treturn;\n\t}\n\tconst executionDefaults = updatedAtGenerator !== void 0 ? {\n\t\tonCreate: updatedAtGenerator,\n\t\tonUpdate: updatedAtGenerator\n\t} : generator !== void 0 ? { onCreate: generator } : void 0;\n\tbuild.columns.set(field.name, {\n\t\tfieldName: field.name,\n\t\tcolumnName,\n\t\tdescriptor: resolved.descriptor,\n\t\tnullable: field.optional || field.list,\n\t\t...field.list ? {\n\t\t\tmany: true,\n\t\t\tnoCheck: [\"elementNotNull\"]\n\t\t} : {},\n\t\t...ifDefined(\"default\", lowered?.storage),\n\t\t...ifDefined(\"executionDefaults\", executionDefaults)\n\t});\n}\n//#endregion\n//#region src/provider.ts\nfunction defaultOutputFromSchemaPath(schemaPath) {\n\treturn join(dirname(schemaPath), \"contract.json\");\n}\nfunction mapParseDiagnostics(diagnostics, sourceFile, sourceId) {\n\treturn diagnostics.map((diagnostic) => ({\n\t\tcode: diagnostic.code,\n\t\tmessage: diagnostic.message,\n\t\tsourceId,\n\t\tspan: rangeToPslSpan(diagnostic.range, sourceFile)\n\t}));\n}\n/**\n* The files a Prisma 7 schema input names: the file itself, or every regular\n* `.prisma` file under the directory, nested directories and symbolic links\n* included, as Prisma 7 reads a schema directory. Sorted by path so duplicate\n* detection blames the later file deterministically.\n*/\nasync function listSchemaFiles(absolutePath, displayPath) {\n\tif (!(await stat(absolutePath)).isDirectory()) return [{\n\t\tsourceId: displayPath,\n\t\tabsolutePath\n\t}];\n\tconst entries = await readdir(absolutePath, { recursive: true });\n\tconst files = [];\n\tfor (const entry of entries.filter((name) => extname(name) === \".prisma\").map((name) => normalize(name)).sort()) {\n\t\tconst entryPath = join(absolutePath, entry);\n\t\tif ((await stat(entryPath)).isFile()) files.push({\n\t\t\tsourceId: join(displayPath, entry),\n\t\t\tabsolutePath: entryPath\n\t\t});\n\t}\n\treturn files;\n}\n/**\n* The checks `contract emit` runs on the contract after `load` that the\n* contract builder does not: domain roots and relations, column defaults\n* against nullability, and model storage references. The structural check also\n* needs the target's entity kinds, which `load` does not receive.\n*/\nfunction validateInterpretedContract(contract) {\n\tvalidateContractDomain(contract);\n\tconst sqlContract = blindCast(contract);\n\tvalidateSqlStorageConsistency(sqlContract);\n\tvalidateModelStorageReferences(sqlContract);\n}\nfunction prisma7Contract(schemaPath, options) {\n\treturn {\n\t\tsource: {\n\t\t\tformat: \"prisma7\",\n\t\t\tinputs: [schemaPath],\n\t\t\tasync load(context) {\n\t\t\t\tconst [absolutePath] = context.resolvedInputs;\n\t\t\t\tif (absolutePath === void 0) throw new InternalError(\"prisma7Contract: context.resolvedInputs is empty. The CLI config loader should populate it positional-matched with source.inputs.\");\n\t\t\t\tlet files;\n\t\t\t\ttry {\n\t\t\t\t\tfiles = await listSchemaFiles(absolutePath, schemaPath);\n\t\t\t\t} catch (error) {\n\t\t\t\t\tconst message = String(error);\n\t\t\t\t\treturn notOk({\n\t\t\t\t\t\tsummary: `Failed to read Prisma 7 schema at \"${schemaPath}\"`,\n\t\t\t\t\t\tdiagnostics: [prisma7Diagnostic(\"PSL.PRISMA7_SCHEMA_READ_FAILED\", message, schemaPath, void 0)],\n\t\t\t\t\t\tmeta: {\n\t\t\t\t\t\t\tschemaPath,\n\t\t\t\t\t\t\tabsolutePath,\n\t\t\t\t\t\t\tcause: message\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\tif (files.length === 0) return notOk({\n\t\t\t\t\tsummary: `Failed to read Prisma 7 schema at \"${schemaPath}\"`,\n\t\t\t\t\tdiagnostics: [prisma7Diagnostic(\"PSL.PRISMA7_SCHEMA_READ_FAILED\", `The schema directory \"${schemaPath}\" contains no .prisma file.`, schemaPath, void 0)],\n\t\t\t\t\tmeta: {\n\t\t\t\t\t\tschemaPath,\n\t\t\t\t\t\tabsolutePath\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t\tconst documents = [];\n\t\t\t\tconst seedDiagnostics = [];\n\t\t\t\tfor (const file of files) {\n\t\t\t\t\tlet schema;\n\t\t\t\t\ttry {\n\t\t\t\t\t\tschema = await readFile(file.absolutePath, \"utf-8\");\n\t\t\t\t\t} catch (error) {\n\t\t\t\t\t\tconst message = String(error);\n\t\t\t\t\t\treturn notOk({\n\t\t\t\t\t\t\tsummary: `Failed to read Prisma 7 schema at \"${file.sourceId}\"`,\n\t\t\t\t\t\t\tdiagnostics: [prisma7Diagnostic(\"PSL.PRISMA7_SCHEMA_READ_FAILED\", message, file.sourceId, void 0)],\n\t\t\t\t\t\t\tmeta: {\n\t\t\t\t\t\t\t\tschemaPath: file.sourceId,\n\t\t\t\t\t\t\t\tabsoluteSchemaPath: file.absolutePath,\n\t\t\t\t\t\t\t\tcause: message\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t\tconst { document, sourceFile, diagnostics } = parse(schema, { grammar: \"prisma7\" });\n\t\t\t\t\tseedDiagnostics.push(...mapParseDiagnostics(diagnostics, sourceFile, file.sourceId));\n\t\t\t\t\tdocuments.push({\n\t\t\t\t\t\tdocument,\n\t\t\t\t\t\tsourceFile,\n\t\t\t\t\t\tsourceId: file.sourceId\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\tlet contract;\n\t\t\t\ttry {\n\t\t\t\t\tconst interpreted = interpretPrisma7Documents({\n\t\t\t\t\t\tdocuments,\n\t\t\t\t\t\tseedDiagnostics,\n\t\t\t\t\t\tbinding: options.binding,\n\t\t\t\t\t\tcontrolMutationDefaults: context.controlMutationDefaults,\n\t\t\t\t\t\tauthoringContributions: context.authoringContributions,\n\t\t\t\t\t\tcodecLookup: context.codecLookup,\n\t\t\t\t\t\tcomposedExtensions: context.composedExtensions\n\t\t\t\t\t});\n\t\t\t\t\tif (!interpreted.ok) return interpreted;\n\t\t\t\t\tcontract = applySqlSpecifierControlPolicy(interpreted.value, options.defaultControlPolicy, options.binding.createNamespace);\n\t\t\t\t\tvalidateInterpretedContract(contract);\n\t\t\t\t} catch (error) {\n\t\t\t\t\tif (!isStructuredError(error)) throw error;\n\t\t\t\t\treturn notOk({\n\t\t\t\t\t\tsummary: \"Prisma 7 schema interpretation failed\",\n\t\t\t\t\t\tdiagnostics: [prisma7Diagnostic(\"PSL.PRISMA7_CONTRACT_INVALID\", `This schema gives a contract that Prisma 8 rejects, and the Prisma 7 contract source has no specific diagnostic for the cause: ${error.message.replace(/\\.$/, \"\")}. This is a bug in Prisma ORM; please report it with this schema.`, schemaPath, void 0)],\n\t\t\t\t\t\tmeta: {\n\t\t\t\t\t\t\tschemaPath,\n\t\t\t\t\t\t\tcode: error.code\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t\treturn ok(contract);\n\t\t\t}\n\t\t},\n\t\toutput: options.output ?? defaultOutputFromSchemaPath(schemaPath)\n\t};\n}\n//#endregion\nexport { prisma7Contract };\n\n//# sourceMappingURL=provider.mjs.map"],"mappings":";;;;;;;;;;;;;;;;;AAiBA,SAAS,kBAAkB,MAAM,SAAS,UAAU,MAAM;CACzD,OAAO;EACN;EACA;EACA;EACA,GAAG,SAAS,KAAK,IAAI,EAAE,KAAK,IAAI,CAAC;CAClC;AACD;AACA,SAAS,QAAQ,OAAO;CACvB,MAAM,UAAU,MAAM,MAAM,GAAG,EAAE;CACjC,MAAM,OAAO,MAAM,MAAM,SAAS,MAAM;CACxC,OAAO,QAAQ,WAAW,IAAI,OAAO,GAAG,QAAQ,KAAK,IAAI,EAAE,OAAO;AACnE;AACA,SAAS,UAAU,WAAW,YAAY;CACzC,OAAO,QAAQ,WAAW,KAAK,SAAS,IAAI,UAAU,GAAG,KAAK,EAAE,CAAC;AAClE;AACA,SAAS,uBAAuB,OAAO;CACtC,MAAM,SAAS,UAAU,MAAM,WAAW,MAAM,UAAU;CAC1D,MAAM,MAAM,MAAM,WAAW,WAAW;CACxC,OAAO,kBAAkB,wCAAwC,GAAG,MAAM,UAAU,SAAS,GAAG,OAAO,GAAG,MAAM,OAAO,MAAM,uBAAuB,MAAM,OAAO,QAAQ,MAAM,OAAO,OAAO,mCAAmC,MAAM,WAAW,iBAAiB,MAAM,eAAe,gBA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C;KACnF,UAAU,KAAK;MACd;MACA;MACA,UAAU,KAAK;KAChB,CAAC;IACF;IACA,IAAI;IACJ,IAAI;KACH,MAAM,cAAc,0BAA0B;MAC7C;MACA;MACA,SAAS,QAAQ;MACjB,yBAAyB,QAAQ;MACjC,wBAAwB,QAAQ;MAChC,aAAa,QAAQ;MACrB,oBAAoB,QAAQ;KAC7B,CAAC;KACD,IAAI,CAAC,YAAY,IAAI,OAAO;KAC5B,WAAW,+BAA+B,YAAY,OAAO,QAAQ,sBAAsB,QAAQ,QAAQ,eAAe;KAC1H,4BAA4B,QAAQ;IACrC,SAAS,OAAO;KACf,IAAI,CAAC,kBAAkB,KAAK,GAAG,MAAM;KACrC,OAAO,MAAM;MACZ,SAAS;MACT,aAAa,CAAC,kBAAkB,gCAAgC,kIAAkI,MAAM,QAAQ,QAAQ,OAAO,EAAE,EAAE,oEAAoE,YAAY,KAAK,CAAC,CAAC;MAC1T,MAAM;OACL;OACA,MAAM,MAAM;MACb;KACD,CAAC;IACF;IACA,OAAO,GAAG,QAAQ;GACnB;EACD;EACA,QAAQ,QAAQ,UAAU,4BAA4B,UAAU;CACjE;AACD"}
@@ -1,2 +1,2 @@
1
- import { i as interpretPslDocumentToSqlContract } from "./interpreter-CRJpMQRR-BjjPK_dV.mjs";
1
+ import { i as interpretPslDocumentToSqlContract } from "./interpreter-9Ru2E-MH-CQdWmnh8.mjs";
2
2
  export { interpretPslDocumentToSqlContract };