From 5489c84e6b813bcee781758e6c0815ff014cac1e Mon Sep 17 00:00:00 2001 From: Horux Dev Date: Mon, 3 Aug 2026 04:30:44 +0000 Subject: [PATCH] =?UTF-8?q?feat(sat):=20parchea=20librer=C3=ADa=20SAT=20pa?= =?UTF-8?q?ra=20soportar=20agente=20proxy?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - HttpsWebClient acepta un cuarto parĂ¡metro opcional 'agent'. - El agente se pasa a https.request() para tunelar conexiones. - Mantiene el parche anterior de fallback para getResponse. --- ...decfdi__sat-ws-descarga-masiva@2.0.0.patch | 26 ++++++++++++++++++- pnpm-lock.yaml | 6 ++--- 2 files changed, 28 insertions(+), 4 deletions(-) diff --git a/patches/@nodecfdi__sat-ws-descarga-masiva@2.0.0.patch b/patches/@nodecfdi__sat-ws-descarga-masiva@2.0.0.patch index 178fea2..8ae51d0 100644 --- a/patches/@nodecfdi__sat-ws-descarga-masiva@2.0.0.patch +++ b/patches/@nodecfdi__sat-ws-descarga-masiva@2.0.0.patch @@ -1,5 +1,5 @@ diff --git a/build/index.js b/build/index.js -index bf7a6aafce966c4ab44ba3abb240578cc68779d6..4678df8734b098f20c7e14d8593bd4328fe759d8 100644 +index bf7a6aafce966c4ab44ba3abb240578cc68779d6..df01102262bbe6d544a5a1b4453977be8a826d0d 100644 --- a/build/index.js +++ b/build/index.js @@ -266,7 +266,13 @@ var ServiceConsumer = class _ServiceConsumer { @@ -17,3 +17,27 @@ index bf7a6aafce966c4ab44ba3abb240578cc68779d6..4678df8734b098f20c7e14d8593bd432 } this.checkErrors(request, response, exception); return response.getBody(); +@@ -2660,10 +2666,12 @@ var HttpsWebClient = class { + _fireRequestClosure; + _fireResponseClosure; + _timeout; +- constructor(onFireRequest, onFireResponse, timeout) { ++ _agent; ++ constructor(onFireRequest, onFireResponse, timeout, agent = void 0) { + this._fireRequestClosure = onFireRequest; + this._fireResponseClosure = onFireResponse; + this._timeout = timeout; ++ this._agent = agent; + } + fireRequest(request) { + if (this._fireRequestClosure) { +@@ -2679,7 +2687,8 @@ var HttpsWebClient = class { + const options = { + method: request.getMethod(), + headers: request.getHeaders(), +- timeout: this._timeout ?? request.getTimeout() ?? void 0 ++ timeout: this._timeout ?? request.getTimeout() ?? void 0, ++ agent: this._agent + }; + return new Promise((resolve, reject) => { + let clientRequest; diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f4a4241..1cd1afd 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -6,7 +6,7 @@ settings: patchedDependencies: '@nodecfdi/sat-ws-descarga-masiva@2.0.0': - hash: n2q5glw3wdhkcidljfdzrkmxnq + hash: i4ncoh7xgprkdron5l2ech4ifm path: patches/@nodecfdi__sat-ws-descarga-masiva@2.0.0.patch importers: @@ -39,7 +39,7 @@ importers: version: 3.2.0(luxon@3.7.2) '@nodecfdi/sat-ws-descarga-masiva': specifier: ^2.0.0 - version: 2.0.0(patch_hash=n2q5glw3wdhkcidljfdzrkmxnq)(@nodecfdi/cfdi-core@1.0.1)(luxon@3.7.2) + version: 2.0.0(patch_hash=i4ncoh7xgprkdron5l2ech4ifm)(@nodecfdi/cfdi-core@1.0.1)(luxon@3.7.2) '@prisma/client': specifier: ^5.22.0 version: 5.22.0(prisma@5.22.0) @@ -3133,7 +3133,7 @@ snapshots: dependencies: luxon: 3.7.2 - '@nodecfdi/sat-ws-descarga-masiva@2.0.0(patch_hash=n2q5glw3wdhkcidljfdzrkmxnq)(@nodecfdi/cfdi-core@1.0.1)(luxon@3.7.2)': + '@nodecfdi/sat-ws-descarga-masiva@2.0.0(patch_hash=i4ncoh7xgprkdron5l2ech4ifm)(@nodecfdi/cfdi-core@1.0.1)(luxon@3.7.2)': dependencies: '@nodecfdi/cfdi-core': 1.0.1 '@nodecfdi/credentials': 3.2.0(luxon@3.7.2)