From 28706510da4f3f09a12c4db6250dfe8f2a12eaa3 Mon Sep 17 00:00:00 2001 From: Felipe Lalanne Date: Thu, 4 Jul 2024 18:41:33 -0400 Subject: [PATCH] Remove custom typings for docker-delta This are no longer needed since docker-delta migrated to typescript in v4 and the custom typings were actually masking some bugs Change-type: patch --- src/lib/docker-utils.ts | 2 +- typings/docker-delta.d.ts | 12 ------------ 2 files changed, 1 insertion(+), 13 deletions(-) delete mode 100644 typings/docker-delta.d.ts diff --git a/src/lib/docker-utils.ts b/src/lib/docker-utils.ts index 2543dd30..25845154 100644 --- a/src/lib/docker-utils.ts +++ b/src/lib/docker-utils.ts @@ -327,7 +327,7 @@ async function applyRsyncDelta( } else if (parseInt(res.headers['content-length'] || '0', 10) === 0) { reject(new Error('Invalid delta URL')); } else { - const deltaStream = applyDelta(imgSrc, { + const deltaStream = applyDelta(docker, imgSrc, { log: logFn, timeout: applyTimeout, }); diff --git a/typings/docker-delta.d.ts b/typings/docker-delta.d.ts deleted file mode 100644 index 998ddc6b..00000000 --- a/typings/docker-delta.d.ts +++ /dev/null @@ -1,12 +0,0 @@ -declare module 'docker-delta' { - // Incomplete type definitions - import type { Duplex } from 'stream'; - import { TypedError } from 'typed-error'; - - export class OutOfSyncError extends TypedError {} - - export function applyDelta( - imageSource: string, - opts: { log: (str: string) => void; timeout: number }, - ): Duplex; -}