MCPcopy
hub / github.com/simstudioai/sim / markTableDeleteFailed

Function markTableDeleteFailed

apps/sim/lib/table/delete-runner.ts:168–183  ·  view source on GitHub ↗
(
  tableId: string,
  jobId: string,
  error: unknown
)

Source from the content-addressed store, hash-verified

166 * web-container fallback (no retries). Scoped to jobId — a no-op if a newer job has taken over.
167 */
168export async function markTableDeleteFailed(
169 tableId: string,
170 jobId: string,
171 error: unknown
172): Promise<void> {
173 const message = truncate(getErrorMessage(toError(error).cause ?? error, 'Delete failed'), 500)
174 await markJobFailed(tableId, jobId, message).catch(() => {})
175 void appendTableEvent({
176 kind: 'job',
177 type: 'delete',
178 tableId,
179 jobId,
180 status: 'failed',
181 error: message,
182 })
183}

Callers 4

dispatchDeleteJobFunction · 0.90
route.tsFile · 0.90
table-delete.tsFile · 0.90

Calls 5

truncateFunction · 0.90
getErrorMessageFunction · 0.90
toErrorFunction · 0.90
markJobFailedFunction · 0.90
appendTableEventFunction · 0.90

Tested by

no test coverage detected