@atscript/db 0.1.156 → 0.1.157
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/sync.cjs +3 -1
- package/dist/sync.mjs +3 -1
- package/package.json +1 -1
package/dist/sync.cjs
CHANGED
|
@@ -1011,7 +1011,9 @@ async function executeSyncTable(facts, safe, deps, exec) {
|
|
|
1011
1011
|
if (adapter.afterSyncTable) await adapter.afterSyncTable();
|
|
1012
1012
|
} catch (error) {
|
|
1013
1013
|
const dropped = droppedFks.length > 0 ? ` Dropped foreign keys before the failure: ${droppedFks.join(", ")} — the ones still in the model are re-added by the next run's syncForeignKeys.` : "";
|
|
1014
|
-
const
|
|
1014
|
+
const reason = error.message;
|
|
1015
|
+
const sep = dropped && !/[.!?]$/.test(reason) ? "." : "";
|
|
1016
|
+
const msg = `${phase} failed on ${name}: ${reason}${sep}${dropped}`;
|
|
1015
1017
|
deps.logger.error?.(`[schema-sync] ${msg}`);
|
|
1016
1018
|
const planned = planTableInit(facts, safe, exec.dependsOn);
|
|
1017
1019
|
return new SyncEntry({
|
package/dist/sync.mjs
CHANGED
|
@@ -1010,7 +1010,9 @@ async function executeSyncTable(facts, safe, deps, exec) {
|
|
|
1010
1010
|
if (adapter.afterSyncTable) await adapter.afterSyncTable();
|
|
1011
1011
|
} catch (error) {
|
|
1012
1012
|
const dropped = droppedFks.length > 0 ? ` Dropped foreign keys before the failure: ${droppedFks.join(", ")} — the ones still in the model are re-added by the next run's syncForeignKeys.` : "";
|
|
1013
|
-
const
|
|
1013
|
+
const reason = error.message;
|
|
1014
|
+
const sep = dropped && !/[.!?]$/.test(reason) ? "." : "";
|
|
1015
|
+
const msg = `${phase} failed on ${name}: ${reason}${sep}${dropped}`;
|
|
1014
1016
|
deps.logger.error?.(`[schema-sync] ${msg}`);
|
|
1015
1017
|
const planned = planTableInit(facts, safe, exec.dependsOn);
|
|
1016
1018
|
return new SyncEntry({
|