rezo 1.0.75 → 1.0.77
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/adapters/entries/curl.d.ts +1 -1
- package/dist/adapters/entries/fetch.d.ts +1 -1
- package/dist/adapters/entries/http.d.ts +1 -1
- package/dist/adapters/entries/http2.d.ts +1 -1
- package/dist/adapters/entries/react-native.d.ts +1 -1
- package/dist/adapters/entries/xhr.d.ts +1 -1
- package/dist/adapters/http.cjs +1 -1
- package/dist/adapters/http.js +1 -1
- package/dist/adapters/index.cjs +6 -6
- package/dist/cache/index.cjs +9 -9
- package/dist/crawler/crawler.cjs +46 -36
- package/dist/crawler/crawler.js +46 -36
- package/dist/crawler/index.cjs +40 -40
- package/dist/crawler/plugin/index.cjs +1 -1
- package/dist/crawler.d.ts +12 -0
- package/dist/entries/crawler.cjs +4 -4
- package/dist/index.cjs +30 -30
- package/dist/index.d.ts +1 -1
- package/dist/internal/agents/index.cjs +14 -14
- package/dist/platform/browser.d.ts +1 -1
- package/dist/platform/bun.d.ts +1 -1
- package/dist/platform/deno.d.ts +1 -1
- package/dist/platform/node.d.ts +1 -1
- package/dist/platform/react-native.d.ts +1 -1
- package/dist/platform/worker.d.ts +1 -1
- package/dist/proxy/index.cjs +4 -4
- package/dist/queue/index.cjs +8 -8
- package/dist/responses/universal/index.cjs +11 -11
- package/dist/version.cjs +1 -1
- package/dist/version.js +1 -1
- package/dist/wget/index.cjs +49 -49
- package/package.json +1 -1
|
@@ -4582,7 +4582,7 @@ export interface RezoInstance extends Rezo {
|
|
|
4582
4582
|
*
|
|
4583
4583
|
* IMPORTANT: Update these values when bumping package version.
|
|
4584
4584
|
*/
|
|
4585
|
-
export declare const VERSION = "1.0.
|
|
4585
|
+
export declare const VERSION = "1.0.77";
|
|
4586
4586
|
/**
|
|
4587
4587
|
* cURL Options Configuration
|
|
4588
4588
|
*
|
|
@@ -4582,7 +4582,7 @@ export interface RezoInstance extends Rezo {
|
|
|
4582
4582
|
*
|
|
4583
4583
|
* IMPORTANT: Update these values when bumping package version.
|
|
4584
4584
|
*/
|
|
4585
|
-
export declare const VERSION = "1.0.
|
|
4585
|
+
export declare const VERSION = "1.0.77";
|
|
4586
4586
|
export declare const isRezoError: typeof RezoError.isRezoError;
|
|
4587
4587
|
export declare const Cancel: typeof RezoError;
|
|
4588
4588
|
export declare const CancelToken: {
|
|
@@ -4582,7 +4582,7 @@ export interface RezoInstance extends Rezo {
|
|
|
4582
4582
|
*
|
|
4583
4583
|
* IMPORTANT: Update these values when bumping package version.
|
|
4584
4584
|
*/
|
|
4585
|
-
export declare const VERSION = "1.0.
|
|
4585
|
+
export declare const VERSION = "1.0.77";
|
|
4586
4586
|
/**
|
|
4587
4587
|
* Type guard to check if an error is a RezoError instance.
|
|
4588
4588
|
*/
|
|
@@ -4582,7 +4582,7 @@ export interface RezoInstance extends Rezo {
|
|
|
4582
4582
|
*
|
|
4583
4583
|
* IMPORTANT: Update these values when bumping package version.
|
|
4584
4584
|
*/
|
|
4585
|
-
export declare const VERSION = "1.0.
|
|
4585
|
+
export declare const VERSION = "1.0.77";
|
|
4586
4586
|
export declare const isRezoError: typeof RezoError.isRezoError;
|
|
4587
4587
|
export declare const Cancel: typeof RezoError;
|
|
4588
4588
|
export declare const CancelToken: {
|
|
@@ -4582,7 +4582,7 @@ export interface RezoInstance extends Rezo {
|
|
|
4582
4582
|
*
|
|
4583
4583
|
* IMPORTANT: Update these values when bumping package version.
|
|
4584
4584
|
*/
|
|
4585
|
-
export declare const VERSION = "1.0.
|
|
4585
|
+
export declare const VERSION = "1.0.77";
|
|
4586
4586
|
export declare const isRezoError: typeof RezoError.isRezoError;
|
|
4587
4587
|
export declare const Cancel: typeof RezoError;
|
|
4588
4588
|
export declare const CancelToken: {
|
|
@@ -4582,7 +4582,7 @@ export interface RezoInstance extends Rezo {
|
|
|
4582
4582
|
*
|
|
4583
4583
|
* IMPORTANT: Update these values when bumping package version.
|
|
4584
4584
|
*/
|
|
4585
|
-
export declare const VERSION = "1.0.
|
|
4585
|
+
export declare const VERSION = "1.0.77";
|
|
4586
4586
|
export declare const isRezoError: typeof RezoError.isRezoError;
|
|
4587
4587
|
export declare const Cancel: typeof RezoError;
|
|
4588
4588
|
export declare const CancelToken: {
|
package/dist/adapters/http.cjs
CHANGED
|
@@ -24,7 +24,7 @@ const { StagedTimeoutManager, parseStagedTimeouts } = require('../utils/staged-t
|
|
|
24
24
|
const { handleRateLimitWait, shouldWaitOnStatus } = require('../utils/rate-limit-wait.cjs');
|
|
25
25
|
const { getSocketTelemetry, beginRequestContext } = require('../utils/socket-telemetry.cjs');
|
|
26
26
|
const dns = require("node:dns");
|
|
27
|
-
const { bunHttp, isBunRuntime, isBunSocksRequest } = require('../internal/agents.cjs');
|
|
27
|
+
const { bunHttp, isBunRuntime, isBunSocksRequest } = require('../internal/agents/bun-socks-http.cjs');
|
|
28
28
|
const debugLog = {
|
|
29
29
|
requestStart: (config, url, method) => {
|
|
30
30
|
if (config.debug) {
|
package/dist/adapters/http.js
CHANGED
|
@@ -24,7 +24,7 @@ import { StagedTimeoutManager, parseStagedTimeouts } from '../utils/staged-timeo
|
|
|
24
24
|
import { handleRateLimitWait, shouldWaitOnStatus } from '../utils/rate-limit-wait.js';
|
|
25
25
|
import { getSocketTelemetry, beginRequestContext } from '../utils/socket-telemetry.js';
|
|
26
26
|
import dns from "node:dns";
|
|
27
|
-
import { bunHttp, isBunRuntime, isBunSocksRequest } from '../internal/agents.js';
|
|
27
|
+
import { bunHttp, isBunRuntime, isBunSocksRequest } from '../internal/agents/bun-socks-http.js';
|
|
28
28
|
const debugLog = {
|
|
29
29
|
requestStart: (config, url, method) => {
|
|
30
30
|
if (config.debug) {
|
package/dist/adapters/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
const
|
|
2
|
-
exports.detectRuntime =
|
|
3
|
-
exports.getAdapterCapabilities =
|
|
4
|
-
exports.buildAdapterContext =
|
|
5
|
-
exports.getAvailableAdapters =
|
|
6
|
-
exports.selectAdapter =
|
|
1
|
+
const _mod_r5y4ts = require('./picker.cjs');
|
|
2
|
+
exports.detectRuntime = _mod_r5y4ts.detectRuntime;
|
|
3
|
+
exports.getAdapterCapabilities = _mod_r5y4ts.getAdapterCapabilities;
|
|
4
|
+
exports.buildAdapterContext = _mod_r5y4ts.buildAdapterContext;
|
|
5
|
+
exports.getAvailableAdapters = _mod_r5y4ts.getAvailableAdapters;
|
|
6
|
+
exports.selectAdapter = _mod_r5y4ts.selectAdapter;;
|
package/dist/cache/index.cjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
const
|
|
2
|
-
exports.LRUCache =
|
|
3
|
-
const
|
|
4
|
-
exports.DNSCache =
|
|
5
|
-
exports.getGlobalDNSCache =
|
|
6
|
-
exports.resetGlobalDNSCache =
|
|
7
|
-
const
|
|
8
|
-
exports.ResponseCache =
|
|
9
|
-
exports.normalizeResponseCacheConfig =
|
|
1
|
+
const _mod_51htpc = require('./lru-cache.cjs');
|
|
2
|
+
exports.LRUCache = _mod_51htpc.LRUCache;;
|
|
3
|
+
const _mod_uwmuk0 = require('./dns-cache.cjs');
|
|
4
|
+
exports.DNSCache = _mod_uwmuk0.DNSCache;
|
|
5
|
+
exports.getGlobalDNSCache = _mod_uwmuk0.getGlobalDNSCache;
|
|
6
|
+
exports.resetGlobalDNSCache = _mod_uwmuk0.resetGlobalDNSCache;;
|
|
7
|
+
const _mod_r0farf = require('./response-cache.cjs');
|
|
8
|
+
exports.ResponseCache = _mod_r0farf.ResponseCache;
|
|
9
|
+
exports.normalizeResponseCacheConfig = _mod_r0farf.normalizeResponseCacheConfig;;
|
package/dist/crawler/crawler.cjs
CHANGED
|
@@ -45,6 +45,7 @@ class Crawler {
|
|
|
45
45
|
rawResponseEvents = [];
|
|
46
46
|
emailDiscoveredEvents = [];
|
|
47
47
|
emailLeadsEvents = [];
|
|
48
|
+
eventCount = 0;
|
|
48
49
|
cacher = null;
|
|
49
50
|
queue;
|
|
50
51
|
scraperQueue;
|
|
@@ -728,8 +729,35 @@ class Crawler {
|
|
|
728
729
|
}
|
|
729
730
|
}
|
|
730
731
|
}
|
|
732
|
+
_runHandler(handler, arg) {
|
|
733
|
+
this.eventCount++;
|
|
734
|
+
new Promise(async (resolve) => {
|
|
735
|
+
try {
|
|
736
|
+
await handler(arg);
|
|
737
|
+
} catch (err) {
|
|
738
|
+
if (this.config.debug)
|
|
739
|
+
console.error("[Crawler] Handler error:", err);
|
|
740
|
+
}
|
|
741
|
+
resolve();
|
|
742
|
+
}).finally(() => {
|
|
743
|
+
this.eventCount--;
|
|
744
|
+
});
|
|
745
|
+
}
|
|
746
|
+
_runBoundHandler(fn) {
|
|
747
|
+
this.eventCount++;
|
|
748
|
+
Promise.resolve().then(async () => {
|
|
749
|
+
try {
|
|
750
|
+
await fn();
|
|
751
|
+
} catch (err) {
|
|
752
|
+
if (this.config.debug)
|
|
753
|
+
console.error("[Crawler] Handler error:", err);
|
|
754
|
+
}
|
|
755
|
+
}).finally(() => {
|
|
756
|
+
this.eventCount--;
|
|
757
|
+
});
|
|
758
|
+
}
|
|
731
759
|
_onBody(handler, document) {
|
|
732
|
-
this.
|
|
760
|
+
this._runHandler(handler, document.body);
|
|
733
761
|
}
|
|
734
762
|
_onAttribute(selection, attribute, handler, document) {
|
|
735
763
|
const isSimpleForm = typeof attribute === "function";
|
|
@@ -741,7 +769,7 @@ class Crawler {
|
|
|
741
769
|
const el = elements[i];
|
|
742
770
|
if (el.hasAttribute(actualAttribute)) {
|
|
743
771
|
const value = el.getAttribute(actualAttribute);
|
|
744
|
-
this.
|
|
772
|
+
this._runBoundHandler(() => actualHandler.call(el, value, actualAttribute));
|
|
745
773
|
}
|
|
746
774
|
}
|
|
747
775
|
}
|
|
@@ -750,19 +778,19 @@ class Crawler {
|
|
|
750
778
|
for (let i = 0;i < elements.length; i++) {
|
|
751
779
|
const el = elements[i];
|
|
752
780
|
const text = el.textContent;
|
|
753
|
-
this.
|
|
781
|
+
this._runBoundHandler(() => handler.call(el, text));
|
|
754
782
|
}
|
|
755
783
|
}
|
|
756
784
|
_onSelection(selection, handler, document) {
|
|
757
785
|
const elements = document.querySelectorAll(selection);
|
|
758
786
|
for (let i = 0;i < elements.length; i++) {
|
|
759
|
-
this.
|
|
787
|
+
this._runHandler(handler, elements[i]);
|
|
760
788
|
}
|
|
761
789
|
}
|
|
762
790
|
_onElement(handler, document) {
|
|
763
791
|
const elements = document.querySelectorAll("*");
|
|
764
792
|
for (let i = 0;i < elements.length; i++) {
|
|
765
|
-
this.
|
|
793
|
+
this._runHandler(handler, elements[i]);
|
|
766
794
|
}
|
|
767
795
|
}
|
|
768
796
|
_onHref(handler, document) {
|
|
@@ -771,7 +799,7 @@ class Crawler {
|
|
|
771
799
|
const el = elements[i];
|
|
772
800
|
if (el.hasAttribute("href")) {
|
|
773
801
|
const href = new URL(el.getAttribute("href"), document.URL).href;
|
|
774
|
-
this.
|
|
802
|
+
this._runBoundHandler(() => handler.call(el, href));
|
|
775
803
|
}
|
|
776
804
|
}
|
|
777
805
|
}
|
|
@@ -782,29 +810,29 @@ class Crawler {
|
|
|
782
810
|
for (let i = 0;i < elements.length; i++) {
|
|
783
811
|
if (elements[i]?.href && document.baseURI)
|
|
784
812
|
elements[i].href = new URL(elements[i].getAttribute("href"), document.baseURI).href;
|
|
785
|
-
this.
|
|
813
|
+
this._runHandler(handler, elements[i]);
|
|
786
814
|
}
|
|
787
815
|
}
|
|
788
816
|
_onDocument(handler, document) {
|
|
789
|
-
this.
|
|
817
|
+
this._runHandler(handler, document);
|
|
790
818
|
}
|
|
791
819
|
_onJson(handler, json) {
|
|
792
|
-
this.
|
|
820
|
+
this._runHandler(handler, json);
|
|
793
821
|
}
|
|
794
822
|
_onError(handler, error) {
|
|
795
|
-
this.
|
|
823
|
+
this._runHandler(handler, error);
|
|
796
824
|
}
|
|
797
825
|
async _onEmailDiscovered(handler, email) {
|
|
798
|
-
this.
|
|
826
|
+
this._runHandler(handler, email);
|
|
799
827
|
}
|
|
800
828
|
async _onEmailLeads(handler, emails) {
|
|
801
|
-
this.
|
|
829
|
+
this._runHandler(handler, emails);
|
|
802
830
|
}
|
|
803
831
|
_onRawResponse(handler, rawResponse) {
|
|
804
|
-
this.
|
|
832
|
+
this._runHandler(handler, rawResponse);
|
|
805
833
|
}
|
|
806
834
|
_onResponse(handler, response) {
|
|
807
|
-
this.
|
|
835
|
+
this._runHandler(handler, response);
|
|
808
836
|
}
|
|
809
837
|
calculateAutoThrottleDelay(domain, responseTime) {
|
|
810
838
|
if (!this.config.autoThrottle)
|
|
@@ -1015,13 +1043,7 @@ class Crawler {
|
|
|
1015
1043
|
this.crawlStats.startTime = Date.now();
|
|
1016
1044
|
this.startPeriodicCleanup();
|
|
1017
1045
|
for (const handler of this.startHandlers) {
|
|
1018
|
-
|
|
1019
|
-
this.queue.add(() => handler());
|
|
1020
|
-
} catch (error) {
|
|
1021
|
-
if (this.config.debug) {
|
|
1022
|
-
console.error("[Crawler] onStart handler error:", error);
|
|
1023
|
-
}
|
|
1024
|
-
}
|
|
1046
|
+
this._runBoundHandler(() => handler());
|
|
1025
1047
|
}
|
|
1026
1048
|
})();
|
|
1027
1049
|
return this.startHandlersPromise;
|
|
@@ -1029,24 +1051,12 @@ class Crawler {
|
|
|
1029
1051
|
async triggerFinishHandlers() {
|
|
1030
1052
|
this.crawlStats.endTime = Date.now();
|
|
1031
1053
|
for (const handler of this.finishHandlers) {
|
|
1032
|
-
|
|
1033
|
-
this.queue.add(() => handler(this.crawlStats));
|
|
1034
|
-
} catch (error) {
|
|
1035
|
-
if (this.config.debug) {
|
|
1036
|
-
console.error("[Crawler] onFinish handler error:", error);
|
|
1037
|
-
}
|
|
1038
|
-
}
|
|
1054
|
+
this._runHandler(handler, this.crawlStats);
|
|
1039
1055
|
}
|
|
1040
1056
|
}
|
|
1041
1057
|
async triggerRedirectHandlers(event) {
|
|
1042
1058
|
for (const handler of this.redirectHandlers) {
|
|
1043
|
-
|
|
1044
|
-
this.queue.add(() => handler(event));
|
|
1045
|
-
} catch (error) {
|
|
1046
|
-
if (this.config.debug) {
|
|
1047
|
-
console.error("[Crawler] onRedirect handler error:", error);
|
|
1048
|
-
}
|
|
1049
|
-
}
|
|
1059
|
+
this._runHandler(handler, event);
|
|
1050
1060
|
}
|
|
1051
1061
|
}
|
|
1052
1062
|
buildUrl(url, params) {
|
|
@@ -1362,7 +1372,7 @@ class Crawler {
|
|
|
1362
1372
|
if (scraperSize === 0 && scraperPending === 0) {
|
|
1363
1373
|
const queueSize = this.queue.size;
|
|
1364
1374
|
const queuePending = this.queue.pending;
|
|
1365
|
-
if (queueSize === 0 && queuePending === 0) {
|
|
1375
|
+
if (queueSize === 0 && queuePending === 0 && this.eventCount === 0) {
|
|
1366
1376
|
consecutiveIdleChecks++;
|
|
1367
1377
|
if (consecutiveIdleChecks >= REQUIRED_IDLE_CHECKS) {
|
|
1368
1378
|
break;
|
package/dist/crawler/crawler.js
CHANGED
|
@@ -45,6 +45,7 @@ export class Crawler {
|
|
|
45
45
|
rawResponseEvents = [];
|
|
46
46
|
emailDiscoveredEvents = [];
|
|
47
47
|
emailLeadsEvents = [];
|
|
48
|
+
eventCount = 0;
|
|
48
49
|
cacher = null;
|
|
49
50
|
queue;
|
|
50
51
|
scraperQueue;
|
|
@@ -728,8 +729,35 @@ export class Crawler {
|
|
|
728
729
|
}
|
|
729
730
|
}
|
|
730
731
|
}
|
|
732
|
+
_runHandler(handler, arg) {
|
|
733
|
+
this.eventCount++;
|
|
734
|
+
new Promise(async (resolve) => {
|
|
735
|
+
try {
|
|
736
|
+
await handler(arg);
|
|
737
|
+
} catch (err) {
|
|
738
|
+
if (this.config.debug)
|
|
739
|
+
console.error("[Crawler] Handler error:", err);
|
|
740
|
+
}
|
|
741
|
+
resolve();
|
|
742
|
+
}).finally(() => {
|
|
743
|
+
this.eventCount--;
|
|
744
|
+
});
|
|
745
|
+
}
|
|
746
|
+
_runBoundHandler(fn) {
|
|
747
|
+
this.eventCount++;
|
|
748
|
+
Promise.resolve().then(async () => {
|
|
749
|
+
try {
|
|
750
|
+
await fn();
|
|
751
|
+
} catch (err) {
|
|
752
|
+
if (this.config.debug)
|
|
753
|
+
console.error("[Crawler] Handler error:", err);
|
|
754
|
+
}
|
|
755
|
+
}).finally(() => {
|
|
756
|
+
this.eventCount--;
|
|
757
|
+
});
|
|
758
|
+
}
|
|
731
759
|
_onBody(handler, document) {
|
|
732
|
-
this.
|
|
760
|
+
this._runHandler(handler, document.body);
|
|
733
761
|
}
|
|
734
762
|
_onAttribute(selection, attribute, handler, document) {
|
|
735
763
|
const isSimpleForm = typeof attribute === "function";
|
|
@@ -741,7 +769,7 @@ export class Crawler {
|
|
|
741
769
|
const el = elements[i];
|
|
742
770
|
if (el.hasAttribute(actualAttribute)) {
|
|
743
771
|
const value = el.getAttribute(actualAttribute);
|
|
744
|
-
this.
|
|
772
|
+
this._runBoundHandler(() => actualHandler.call(el, value, actualAttribute));
|
|
745
773
|
}
|
|
746
774
|
}
|
|
747
775
|
}
|
|
@@ -750,19 +778,19 @@ export class Crawler {
|
|
|
750
778
|
for (let i = 0;i < elements.length; i++) {
|
|
751
779
|
const el = elements[i];
|
|
752
780
|
const text = el.textContent;
|
|
753
|
-
this.
|
|
781
|
+
this._runBoundHandler(() => handler.call(el, text));
|
|
754
782
|
}
|
|
755
783
|
}
|
|
756
784
|
_onSelection(selection, handler, document) {
|
|
757
785
|
const elements = document.querySelectorAll(selection);
|
|
758
786
|
for (let i = 0;i < elements.length; i++) {
|
|
759
|
-
this.
|
|
787
|
+
this._runHandler(handler, elements[i]);
|
|
760
788
|
}
|
|
761
789
|
}
|
|
762
790
|
_onElement(handler, document) {
|
|
763
791
|
const elements = document.querySelectorAll("*");
|
|
764
792
|
for (let i = 0;i < elements.length; i++) {
|
|
765
|
-
this.
|
|
793
|
+
this._runHandler(handler, elements[i]);
|
|
766
794
|
}
|
|
767
795
|
}
|
|
768
796
|
_onHref(handler, document) {
|
|
@@ -771,7 +799,7 @@ export class Crawler {
|
|
|
771
799
|
const el = elements[i];
|
|
772
800
|
if (el.hasAttribute("href")) {
|
|
773
801
|
const href = new URL(el.getAttribute("href"), document.URL).href;
|
|
774
|
-
this.
|
|
802
|
+
this._runBoundHandler(() => handler.call(el, href));
|
|
775
803
|
}
|
|
776
804
|
}
|
|
777
805
|
}
|
|
@@ -782,29 +810,29 @@ export class Crawler {
|
|
|
782
810
|
for (let i = 0;i < elements.length; i++) {
|
|
783
811
|
if (elements[i]?.href && document.baseURI)
|
|
784
812
|
elements[i].href = new URL(elements[i].getAttribute("href"), document.baseURI).href;
|
|
785
|
-
this.
|
|
813
|
+
this._runHandler(handler, elements[i]);
|
|
786
814
|
}
|
|
787
815
|
}
|
|
788
816
|
_onDocument(handler, document) {
|
|
789
|
-
this.
|
|
817
|
+
this._runHandler(handler, document);
|
|
790
818
|
}
|
|
791
819
|
_onJson(handler, json) {
|
|
792
|
-
this.
|
|
820
|
+
this._runHandler(handler, json);
|
|
793
821
|
}
|
|
794
822
|
_onError(handler, error) {
|
|
795
|
-
this.
|
|
823
|
+
this._runHandler(handler, error);
|
|
796
824
|
}
|
|
797
825
|
async _onEmailDiscovered(handler, email) {
|
|
798
|
-
this.
|
|
826
|
+
this._runHandler(handler, email);
|
|
799
827
|
}
|
|
800
828
|
async _onEmailLeads(handler, emails) {
|
|
801
|
-
this.
|
|
829
|
+
this._runHandler(handler, emails);
|
|
802
830
|
}
|
|
803
831
|
_onRawResponse(handler, rawResponse) {
|
|
804
|
-
this.
|
|
832
|
+
this._runHandler(handler, rawResponse);
|
|
805
833
|
}
|
|
806
834
|
_onResponse(handler, response) {
|
|
807
|
-
this.
|
|
835
|
+
this._runHandler(handler, response);
|
|
808
836
|
}
|
|
809
837
|
calculateAutoThrottleDelay(domain, responseTime) {
|
|
810
838
|
if (!this.config.autoThrottle)
|
|
@@ -1015,13 +1043,7 @@ export class Crawler {
|
|
|
1015
1043
|
this.crawlStats.startTime = Date.now();
|
|
1016
1044
|
this.startPeriodicCleanup();
|
|
1017
1045
|
for (const handler of this.startHandlers) {
|
|
1018
|
-
|
|
1019
|
-
this.queue.add(() => handler());
|
|
1020
|
-
} catch (error) {
|
|
1021
|
-
if (this.config.debug) {
|
|
1022
|
-
console.error("[Crawler] onStart handler error:", error);
|
|
1023
|
-
}
|
|
1024
|
-
}
|
|
1046
|
+
this._runBoundHandler(() => handler());
|
|
1025
1047
|
}
|
|
1026
1048
|
})();
|
|
1027
1049
|
return this.startHandlersPromise;
|
|
@@ -1029,24 +1051,12 @@ export class Crawler {
|
|
|
1029
1051
|
async triggerFinishHandlers() {
|
|
1030
1052
|
this.crawlStats.endTime = Date.now();
|
|
1031
1053
|
for (const handler of this.finishHandlers) {
|
|
1032
|
-
|
|
1033
|
-
this.queue.add(() => handler(this.crawlStats));
|
|
1034
|
-
} catch (error) {
|
|
1035
|
-
if (this.config.debug) {
|
|
1036
|
-
console.error("[Crawler] onFinish handler error:", error);
|
|
1037
|
-
}
|
|
1038
|
-
}
|
|
1054
|
+
this._runHandler(handler, this.crawlStats);
|
|
1039
1055
|
}
|
|
1040
1056
|
}
|
|
1041
1057
|
async triggerRedirectHandlers(event) {
|
|
1042
1058
|
for (const handler of this.redirectHandlers) {
|
|
1043
|
-
|
|
1044
|
-
this.queue.add(() => handler(event));
|
|
1045
|
-
} catch (error) {
|
|
1046
|
-
if (this.config.debug) {
|
|
1047
|
-
console.error("[Crawler] onRedirect handler error:", error);
|
|
1048
|
-
}
|
|
1049
|
-
}
|
|
1059
|
+
this._runHandler(handler, event);
|
|
1050
1060
|
}
|
|
1051
1061
|
}
|
|
1052
1062
|
buildUrl(url, params) {
|
|
@@ -1362,7 +1372,7 @@ export class Crawler {
|
|
|
1362
1372
|
if (scraperSize === 0 && scraperPending === 0) {
|
|
1363
1373
|
const queueSize = this.queue.size;
|
|
1364
1374
|
const queuePending = this.queue.pending;
|
|
1365
|
-
if (queueSize === 0 && queuePending === 0) {
|
|
1375
|
+
if (queueSize === 0 && queuePending === 0 && this.eventCount === 0) {
|
|
1366
1376
|
consecutiveIdleChecks++;
|
|
1367
1377
|
if (consecutiveIdleChecks >= REQUIRED_IDLE_CHECKS) {
|
|
1368
1378
|
break;
|
package/dist/crawler/index.cjs
CHANGED
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
const
|
|
2
|
-
exports.Crawler =
|
|
3
|
-
const
|
|
4
|
-
exports.CrawlerOptions =
|
|
5
|
-
const
|
|
6
|
-
exports.RobotsTxt =
|
|
7
|
-
const
|
|
8
|
-
exports.FileCacher =
|
|
9
|
-
const
|
|
10
|
-
exports.UrlStore =
|
|
11
|
-
const
|
|
12
|
-
exports.NavigationHistory =
|
|
13
|
-
const
|
|
14
|
-
exports.Oxylabs =
|
|
15
|
-
const
|
|
16
|
-
exports.OXYLABS_BROWSER_TYPES =
|
|
17
|
-
exports.OXYLABS_COMMON_LOCALES =
|
|
18
|
-
exports.OXYLABS_COMMON_GEO_LOCATIONS =
|
|
19
|
-
exports.OXYLABS_US_STATES =
|
|
20
|
-
exports.OXYLABS_EUROPEAN_COUNTRIES =
|
|
21
|
-
exports.OXYLABS_ASIAN_COUNTRIES =
|
|
22
|
-
exports.getRandomOxylabsBrowserType =
|
|
23
|
-
exports.getRandomOxylabsLocale =
|
|
24
|
-
exports.getRandomOxylabsGeoLocation =
|
|
25
|
-
const
|
|
26
|
-
exports.Decodo =
|
|
27
|
-
const
|
|
28
|
-
exports.DECODO_DEVICE_TYPES =
|
|
29
|
-
exports.DECODO_HEADLESS_MODES =
|
|
30
|
-
exports.DECODO_COMMON_LOCALES =
|
|
31
|
-
exports.DECODO_COMMON_COUNTRIES =
|
|
32
|
-
exports.DECODO_EUROPEAN_COUNTRIES =
|
|
33
|
-
exports.DECODO_ASIAN_COUNTRIES =
|
|
34
|
-
exports.DECODO_US_STATES =
|
|
35
|
-
exports.DECODO_COMMON_CITIES =
|
|
36
|
-
exports.getRandomDecodoDeviceType =
|
|
37
|
-
exports.getRandomDecodoLocale =
|
|
38
|
-
exports.getRandomDecodoCountry =
|
|
39
|
-
exports.getRandomDecodoCity =
|
|
40
|
-
exports.generateDecodoSessionId =
|
|
1
|
+
const _mod_830eza = require('./crawler.cjs');
|
|
2
|
+
exports.Crawler = _mod_830eza.Crawler;;
|
|
3
|
+
const _mod_lxjhdi = require('./crawler-options.cjs');
|
|
4
|
+
exports.CrawlerOptions = _mod_lxjhdi.CrawlerOptions;;
|
|
5
|
+
const _mod_dtyti5 = require('./plugin/robots-txt.cjs');
|
|
6
|
+
exports.RobotsTxt = _mod_dtyti5.RobotsTxt;;
|
|
7
|
+
const _mod_d775ku = require('./plugin/file-cacher.cjs');
|
|
8
|
+
exports.FileCacher = _mod_d775ku.FileCacher;;
|
|
9
|
+
const _mod_auits6 = require('./plugin/url-store.cjs');
|
|
10
|
+
exports.UrlStore = _mod_auits6.UrlStore;;
|
|
11
|
+
const _mod_5qv1tt = require('./plugin/navigation-history.cjs');
|
|
12
|
+
exports.NavigationHistory = _mod_5qv1tt.NavigationHistory;;
|
|
13
|
+
const _mod_7gxdja = require('./addon/oxylabs/index.cjs');
|
|
14
|
+
exports.Oxylabs = _mod_7gxdja.Oxylabs;;
|
|
15
|
+
const _mod_st70b4 = require('./addon/oxylabs/options.cjs');
|
|
16
|
+
exports.OXYLABS_BROWSER_TYPES = _mod_st70b4.OXYLABS_BROWSER_TYPES;
|
|
17
|
+
exports.OXYLABS_COMMON_LOCALES = _mod_st70b4.OXYLABS_COMMON_LOCALES;
|
|
18
|
+
exports.OXYLABS_COMMON_GEO_LOCATIONS = _mod_st70b4.OXYLABS_COMMON_GEO_LOCATIONS;
|
|
19
|
+
exports.OXYLABS_US_STATES = _mod_st70b4.OXYLABS_US_STATES;
|
|
20
|
+
exports.OXYLABS_EUROPEAN_COUNTRIES = _mod_st70b4.OXYLABS_EUROPEAN_COUNTRIES;
|
|
21
|
+
exports.OXYLABS_ASIAN_COUNTRIES = _mod_st70b4.OXYLABS_ASIAN_COUNTRIES;
|
|
22
|
+
exports.getRandomOxylabsBrowserType = _mod_st70b4.getRandomBrowserType;
|
|
23
|
+
exports.getRandomOxylabsLocale = _mod_st70b4.getRandomLocale;
|
|
24
|
+
exports.getRandomOxylabsGeoLocation = _mod_st70b4.getRandomGeoLocation;;
|
|
25
|
+
const _mod_1btns4 = require('./addon/decodo/index.cjs');
|
|
26
|
+
exports.Decodo = _mod_1btns4.Decodo;;
|
|
27
|
+
const _mod_b145ak = require('./addon/decodo/options.cjs');
|
|
28
|
+
exports.DECODO_DEVICE_TYPES = _mod_b145ak.DECODO_DEVICE_TYPES;
|
|
29
|
+
exports.DECODO_HEADLESS_MODES = _mod_b145ak.DECODO_HEADLESS_MODES;
|
|
30
|
+
exports.DECODO_COMMON_LOCALES = _mod_b145ak.DECODO_COMMON_LOCALES;
|
|
31
|
+
exports.DECODO_COMMON_COUNTRIES = _mod_b145ak.DECODO_COMMON_COUNTRIES;
|
|
32
|
+
exports.DECODO_EUROPEAN_COUNTRIES = _mod_b145ak.DECODO_EUROPEAN_COUNTRIES;
|
|
33
|
+
exports.DECODO_ASIAN_COUNTRIES = _mod_b145ak.DECODO_ASIAN_COUNTRIES;
|
|
34
|
+
exports.DECODO_US_STATES = _mod_b145ak.DECODO_US_STATES;
|
|
35
|
+
exports.DECODO_COMMON_CITIES = _mod_b145ak.DECODO_COMMON_CITIES;
|
|
36
|
+
exports.getRandomDecodoDeviceType = _mod_b145ak.getRandomDeviceType;
|
|
37
|
+
exports.getRandomDecodoLocale = _mod_b145ak.getRandomLocale;
|
|
38
|
+
exports.getRandomDecodoCountry = _mod_b145ak.getRandomCountry;
|
|
39
|
+
exports.getRandomDecodoCity = _mod_b145ak.getRandomCity;
|
|
40
|
+
exports.generateDecodoSessionId = _mod_b145ak.generateSessionId;;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var e=require("./file-cacher.cjs");exports.FileCacher=e.FileCacher;var r=require("./url-store.cjs");exports.UrlStore=r.UrlStore;var o=require("./result-stream.cjs");exports.ResultStream=o.ResultStream;var t=require("./memory-monitor.cjs");exports.MemoryMonitor=t.MemoryMonitor;var
|
|
1
|
+
var e=require("./file-cacher.cjs");exports.FileCacher=e.FileCacher;var r=require("./url-store.cjs");exports.UrlStore=r.UrlStore;var o=require("./result-stream.cjs");exports.ResultStream=o.ResultStream;var t=require("./memory-monitor.cjs");exports.MemoryMonitor=t.MemoryMonitor;var a=require("./health-metrics.cjs");exports.HealthMetrics=a.HealthMetrics;var i=require("./capped-map.cjs");exports.CappedMap=i.CappedMap;var d=require("./capped-array.cjs");exports.CappedArray=d.CappedArray;
|
package/dist/crawler.d.ts
CHANGED
|
@@ -7200,6 +7200,8 @@ export declare class Crawler {
|
|
|
7200
7200
|
private readonly rawResponseEvents;
|
|
7201
7201
|
private emailDiscoveredEvents;
|
|
7202
7202
|
private emailLeadsEvents;
|
|
7203
|
+
/** Counter for active event handlers (not queued, runs directly) */
|
|
7204
|
+
private eventCount;
|
|
7203
7205
|
/**
|
|
7204
7206
|
* Key-value cache instance for storing HTTP responses.
|
|
7205
7207
|
* Uses SQLite as the underlying storage mechanism.
|
|
@@ -7751,6 +7753,16 @@ export declare class Crawler {
|
|
|
7751
7753
|
* Called when onQueueChange handlers are registered to ensure limiter events are captured.
|
|
7752
7754
|
*/
|
|
7753
7755
|
private _subscribeToLimiterQueues;
|
|
7756
|
+
/**
|
|
7757
|
+
* Run a handler with event tracking (not through queue).
|
|
7758
|
+
* Increments eventCount before running, decrements after completion.
|
|
7759
|
+
* This allows waitForAll() to wait for handlers without queue bloat.
|
|
7760
|
+
*/
|
|
7761
|
+
private _runHandler;
|
|
7762
|
+
/**
|
|
7763
|
+
* Run a bound handler (using .call()) with event tracking.
|
|
7764
|
+
*/
|
|
7765
|
+
private _runBoundHandler;
|
|
7754
7766
|
private _onBody;
|
|
7755
7767
|
private _onAttribute;
|
|
7756
7768
|
private _onText;
|
package/dist/entries/crawler.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const
|
|
2
|
-
exports.Crawler =
|
|
3
|
-
const
|
|
4
|
-
exports.CrawlerOptions =
|
|
1
|
+
const _mod_ioqjf8 = require('../crawler/crawler.cjs');
|
|
2
|
+
exports.Crawler = _mod_ioqjf8.Crawler;;
|
|
3
|
+
const _mod_q43cpd = require('../crawler/crawler-options.cjs');
|
|
4
|
+
exports.CrawlerOptions = _mod_q43cpd.CrawlerOptions;;
|
package/dist/index.cjs
CHANGED
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
const
|
|
2
|
-
exports.Rezo =
|
|
3
|
-
exports.createRezoInstance =
|
|
4
|
-
exports.createDefaultInstance =
|
|
5
|
-
const
|
|
6
|
-
exports.RezoError =
|
|
7
|
-
exports.RezoErrorCode =
|
|
8
|
-
const
|
|
9
|
-
exports.RezoHeaders =
|
|
10
|
-
const
|
|
11
|
-
exports.RezoFormData =
|
|
12
|
-
const
|
|
13
|
-
exports.RezoCookieJar =
|
|
14
|
-
exports.Cookie =
|
|
15
|
-
const
|
|
16
|
-
exports.toCurl =
|
|
17
|
-
exports.fromCurl =
|
|
18
|
-
const
|
|
19
|
-
exports.createDefaultHooks =
|
|
20
|
-
exports.mergeHooks =
|
|
21
|
-
const
|
|
22
|
-
exports.ProxyManager =
|
|
23
|
-
const
|
|
24
|
-
exports.RezoQueue =
|
|
25
|
-
exports.HttpQueue =
|
|
26
|
-
exports.Priority =
|
|
27
|
-
exports.HttpMethodPriority =
|
|
1
|
+
const _mod_z8hnjj = require('./core/rezo.cjs');
|
|
2
|
+
exports.Rezo = _mod_z8hnjj.Rezo;
|
|
3
|
+
exports.createRezoInstance = _mod_z8hnjj.createRezoInstance;
|
|
4
|
+
exports.createDefaultInstance = _mod_z8hnjj.createDefaultInstance;;
|
|
5
|
+
const _mod_xud1je = require('./errors/rezo-error.cjs');
|
|
6
|
+
exports.RezoError = _mod_xud1je.RezoError;
|
|
7
|
+
exports.RezoErrorCode = _mod_xud1je.RezoErrorCode;;
|
|
8
|
+
const _mod_6560f8 = require('./utils/headers.cjs');
|
|
9
|
+
exports.RezoHeaders = _mod_6560f8.RezoHeaders;;
|
|
10
|
+
const _mod_lxkkq1 = require('./utils/form-data.cjs');
|
|
11
|
+
exports.RezoFormData = _mod_lxkkq1.RezoFormData;;
|
|
12
|
+
const _mod_i2hy45 = require('./utils/cookies.cjs');
|
|
13
|
+
exports.RezoCookieJar = _mod_i2hy45.RezoCookieJar;
|
|
14
|
+
exports.Cookie = _mod_i2hy45.Cookie;;
|
|
15
|
+
const _mod_z2kao1 = require('./utils/curl.cjs');
|
|
16
|
+
exports.toCurl = _mod_z2kao1.toCurl;
|
|
17
|
+
exports.fromCurl = _mod_z2kao1.fromCurl;;
|
|
18
|
+
const _mod_5yvopr = require('./core/hooks.cjs');
|
|
19
|
+
exports.createDefaultHooks = _mod_5yvopr.createDefaultHooks;
|
|
20
|
+
exports.mergeHooks = _mod_5yvopr.mergeHooks;;
|
|
21
|
+
const _mod_fcvk6n = require('./proxy/manager.cjs');
|
|
22
|
+
exports.ProxyManager = _mod_fcvk6n.ProxyManager;;
|
|
23
|
+
const _mod_cugc0r = require('./queue/index.cjs');
|
|
24
|
+
exports.RezoQueue = _mod_cugc0r.RezoQueue;
|
|
25
|
+
exports.HttpQueue = _mod_cugc0r.HttpQueue;
|
|
26
|
+
exports.Priority = _mod_cugc0r.Priority;
|
|
27
|
+
exports.HttpMethodPriority = _mod_cugc0r.HttpMethodPriority;;
|
|
28
28
|
const { RezoError } = require('./errors/rezo-error.cjs');
|
|
29
29
|
const isRezoError = exports.isRezoError = RezoError.isRezoError;
|
|
30
30
|
const Cancel = exports.Cancel = RezoError;
|
|
@@ -34,9 +34,9 @@ const isCancel = exports.isCancel = (error) => {
|
|
|
34
34
|
};
|
|
35
35
|
const all = exports.all = Promise.all.bind(Promise);
|
|
36
36
|
const spread = exports.spread = (callback) => (array) => callback(...array);
|
|
37
|
-
const
|
|
38
|
-
exports.VERSION =
|
|
39
|
-
exports.PACKAGE_NAME =
|
|
37
|
+
const _mod_7ix2oo = require('./version.cjs');
|
|
38
|
+
exports.VERSION = _mod_7ix2oo.VERSION;
|
|
39
|
+
exports.PACKAGE_NAME = _mod_7ix2oo.PACKAGE_NAME;;
|
|
40
40
|
const { executeRequest } = require('./adapters/http.cjs');
|
|
41
41
|
const { setGlobalAdapter, createRezoInstance } = require('./core/rezo.cjs');
|
|
42
42
|
setGlobalAdapter(executeRequest);
|
package/dist/index.d.ts
CHANGED
|
@@ -4886,7 +4886,7 @@ export declare class HttpQueue extends RezoQueue<any> {
|
|
|
4886
4886
|
*
|
|
4887
4887
|
* IMPORTANT: Update these values when bumping package version.
|
|
4888
4888
|
*/
|
|
4889
|
-
export declare const VERSION = "1.0.
|
|
4889
|
+
export declare const VERSION = "1.0.77";
|
|
4890
4890
|
export declare const PACKAGE_NAME = "rezo";
|
|
4891
4891
|
export declare const isRezoError: typeof RezoError.isRezoError;
|
|
4892
4892
|
export declare const Cancel: typeof RezoError;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
const
|
|
2
|
-
exports.Agent =
|
|
3
|
-
const
|
|
4
|
-
exports.HttpProxyAgent =
|
|
5
|
-
const
|
|
6
|
-
exports.HttpsProxyAgent =
|
|
7
|
-
const
|
|
8
|
-
exports.SocksProxyAgent =
|
|
9
|
-
const
|
|
10
|
-
exports.SocksClient =
|
|
11
|
-
const
|
|
12
|
-
exports.bunHttp =
|
|
13
|
-
exports.isBunRuntime =
|
|
14
|
-
exports.isBunSocksRequest =
|
|
1
|
+
const _mod_vl5xp9 = require('./base.cjs');
|
|
2
|
+
exports.Agent = _mod_vl5xp9.Agent;;
|
|
3
|
+
const _mod_888dt6 = require('./http-proxy.cjs');
|
|
4
|
+
exports.HttpProxyAgent = _mod_888dt6.HttpProxyAgent;;
|
|
5
|
+
const _mod_0s5ut8 = require('./https-proxy.cjs');
|
|
6
|
+
exports.HttpsProxyAgent = _mod_0s5ut8.HttpsProxyAgent;;
|
|
7
|
+
const _mod_syvwkb = require('./socks-proxy.cjs');
|
|
8
|
+
exports.SocksProxyAgent = _mod_syvwkb.SocksProxyAgent;;
|
|
9
|
+
const _mod_0q362j = require('./socks-client.cjs');
|
|
10
|
+
exports.SocksClient = _mod_0q362j.SocksClient;;
|
|
11
|
+
const _mod_gq08rk = require('./bun-socks-http.cjs');
|
|
12
|
+
exports.bunHttp = _mod_gq08rk.bunHttp;
|
|
13
|
+
exports.isBunRuntime = _mod_gq08rk.isBunRuntime;
|
|
14
|
+
exports.isBunSocksRequest = _mod_gq08rk.isBunSocksRequest;;
|
|
@@ -4582,7 +4582,7 @@ export interface RezoInstance extends Rezo {
|
|
|
4582
4582
|
*
|
|
4583
4583
|
* IMPORTANT: Update these values when bumping package version.
|
|
4584
4584
|
*/
|
|
4585
|
-
export declare const VERSION = "1.0.
|
|
4585
|
+
export declare const VERSION = "1.0.77";
|
|
4586
4586
|
export declare const isRezoError: typeof RezoError.isRezoError;
|
|
4587
4587
|
export declare const Cancel: typeof RezoError;
|
|
4588
4588
|
export declare const CancelToken: {
|
package/dist/platform/bun.d.ts
CHANGED
|
@@ -4582,7 +4582,7 @@ export interface RezoInstance extends Rezo {
|
|
|
4582
4582
|
*
|
|
4583
4583
|
* IMPORTANT: Update these values when bumping package version.
|
|
4584
4584
|
*/
|
|
4585
|
-
export declare const VERSION = "1.0.
|
|
4585
|
+
export declare const VERSION = "1.0.77";
|
|
4586
4586
|
export declare const isRezoError: typeof RezoError.isRezoError;
|
|
4587
4587
|
export declare const Cancel: typeof RezoError;
|
|
4588
4588
|
export declare const CancelToken: {
|
package/dist/platform/deno.d.ts
CHANGED
|
@@ -4582,7 +4582,7 @@ export interface RezoInstance extends Rezo {
|
|
|
4582
4582
|
*
|
|
4583
4583
|
* IMPORTANT: Update these values when bumping package version.
|
|
4584
4584
|
*/
|
|
4585
|
-
export declare const VERSION = "1.0.
|
|
4585
|
+
export declare const VERSION = "1.0.77";
|
|
4586
4586
|
export declare const isRezoError: typeof RezoError.isRezoError;
|
|
4587
4587
|
export declare const Cancel: typeof RezoError;
|
|
4588
4588
|
export declare const CancelToken: {
|
package/dist/platform/node.d.ts
CHANGED
|
@@ -4582,7 +4582,7 @@ export interface RezoInstance extends Rezo {
|
|
|
4582
4582
|
*
|
|
4583
4583
|
* IMPORTANT: Update these values when bumping package version.
|
|
4584
4584
|
*/
|
|
4585
|
-
export declare const VERSION = "1.0.
|
|
4585
|
+
export declare const VERSION = "1.0.77";
|
|
4586
4586
|
export declare const isRezoError: typeof RezoError.isRezoError;
|
|
4587
4587
|
export declare const Cancel: typeof RezoError;
|
|
4588
4588
|
export declare const CancelToken: {
|
|
@@ -4582,7 +4582,7 @@ export interface RezoInstance extends Rezo {
|
|
|
4582
4582
|
*
|
|
4583
4583
|
* IMPORTANT: Update these values when bumping package version.
|
|
4584
4584
|
*/
|
|
4585
|
-
export declare const VERSION = "1.0.
|
|
4585
|
+
export declare const VERSION = "1.0.77";
|
|
4586
4586
|
export declare const isRezoError: typeof RezoError.isRezoError;
|
|
4587
4587
|
export declare const Cancel: typeof RezoError;
|
|
4588
4588
|
export declare const CancelToken: {
|
|
@@ -4582,7 +4582,7 @@ export interface RezoInstance extends Rezo {
|
|
|
4582
4582
|
*
|
|
4583
4583
|
* IMPORTANT: Update these values when bumping package version.
|
|
4584
4584
|
*/
|
|
4585
|
-
export declare const VERSION = "1.0.
|
|
4585
|
+
export declare const VERSION = "1.0.77";
|
|
4586
4586
|
export declare const isRezoError: typeof RezoError.isRezoError;
|
|
4587
4587
|
export declare const Cancel: typeof RezoError;
|
|
4588
4588
|
export declare const CancelToken: {
|
package/dist/proxy/index.cjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
const { Agent, HttpProxyAgent, HttpsProxyAgent, SocksProxyAgent } = require('../internal/agents/index.cjs');
|
|
2
2
|
const { parseProxyString } = require('./parse.cjs');
|
|
3
|
-
const
|
|
4
|
-
exports.ProxyManager =
|
|
5
|
-
const
|
|
6
|
-
exports.parseProxyString =
|
|
3
|
+
const _mod_es42to = require('./manager.cjs');
|
|
4
|
+
exports.ProxyManager = _mod_es42to.ProxyManager;;
|
|
5
|
+
const _mod_egiu3j = require('./parse.cjs');
|
|
6
|
+
exports.parseProxyString = _mod_egiu3j.parseProxyString;;
|
|
7
7
|
function createOptions(uri, opts) {
|
|
8
8
|
if (uri instanceof URL || typeof uri === "string") {
|
|
9
9
|
return {
|
package/dist/queue/index.cjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
const
|
|
2
|
-
exports.RezoQueue =
|
|
3
|
-
const
|
|
4
|
-
exports.HttpQueue =
|
|
5
|
-
exports.extractDomain =
|
|
6
|
-
const
|
|
7
|
-
exports.Priority =
|
|
8
|
-
exports.HttpMethodPriority =
|
|
1
|
+
const _mod_982q2m = require('./queue.cjs');
|
|
2
|
+
exports.RezoQueue = _mod_982q2m.RezoQueue;;
|
|
3
|
+
const _mod_nbnghv = require('./http-queue.cjs');
|
|
4
|
+
exports.HttpQueue = _mod_nbnghv.HttpQueue;
|
|
5
|
+
exports.extractDomain = _mod_nbnghv.extractDomain;;
|
|
6
|
+
const _mod_gy4d54 = require('./types.cjs');
|
|
7
|
+
exports.Priority = _mod_gy4d54.Priority;
|
|
8
|
+
exports.HttpMethodPriority = _mod_gy4d54.HttpMethodPriority;;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
const
|
|
2
|
-
exports.UniversalEventEmitter =
|
|
3
|
-
const
|
|
4
|
-
exports.UniversalStreamResponse =
|
|
5
|
-
exports.StreamResponse =
|
|
6
|
-
const
|
|
7
|
-
exports.UniversalDownloadResponse =
|
|
8
|
-
exports.DownloadResponse =
|
|
9
|
-
const
|
|
10
|
-
exports.UniversalUploadResponse =
|
|
11
|
-
exports.UploadResponse =
|
|
1
|
+
const _mod_ebx0f7 = require('./event-emitter.cjs');
|
|
2
|
+
exports.UniversalEventEmitter = _mod_ebx0f7.UniversalEventEmitter;;
|
|
3
|
+
const _mod_9ctp8o = require('./stream.cjs');
|
|
4
|
+
exports.UniversalStreamResponse = _mod_9ctp8o.UniversalStreamResponse;
|
|
5
|
+
exports.StreamResponse = _mod_9ctp8o.StreamResponse;;
|
|
6
|
+
const _mod_edmpcs = require('./download.cjs');
|
|
7
|
+
exports.UniversalDownloadResponse = _mod_edmpcs.UniversalDownloadResponse;
|
|
8
|
+
exports.DownloadResponse = _mod_edmpcs.DownloadResponse;;
|
|
9
|
+
const _mod_meacrz = require('./upload.cjs');
|
|
10
|
+
exports.UniversalUploadResponse = _mod_meacrz.UniversalUploadResponse;
|
|
11
|
+
exports.UploadResponse = _mod_meacrz.UploadResponse;;
|
package/dist/version.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const VERSION = exports.VERSION = "1.0.
|
|
1
|
+
const VERSION = exports.VERSION = "1.0.77";
|
|
2
2
|
const PACKAGE_NAME = exports.PACKAGE_NAME = "rezo";
|
package/dist/version.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = "1.0.
|
|
1
|
+
export const VERSION = "1.0.77";
|
|
2
2
|
export const PACKAGE_NAME = "rezo";
|
package/dist/wget/index.cjs
CHANGED
|
@@ -1,52 +1,52 @@
|
|
|
1
|
-
const
|
|
2
|
-
exports.WgetError =
|
|
3
|
-
const
|
|
4
|
-
exports.AssetExtractor =
|
|
5
|
-
const
|
|
6
|
-
exports.UrlFilter =
|
|
7
|
-
const
|
|
8
|
-
exports.FileWriter =
|
|
9
|
-
const
|
|
10
|
-
exports.RobotsHandler =
|
|
11
|
-
const
|
|
12
|
-
exports.ResumeHandler =
|
|
13
|
-
const
|
|
14
|
-
exports.ProgressReporter =
|
|
15
|
-
exports.ProgressTracker =
|
|
16
|
-
exports.parseSize =
|
|
17
|
-
const
|
|
18
|
-
exports.LinkConverter =
|
|
19
|
-
const
|
|
20
|
-
exports.Downloader =
|
|
21
|
-
const
|
|
22
|
-
exports.AssetOrganizer =
|
|
23
|
-
exports.DEFAULT_ASSET_FOLDERS =
|
|
24
|
-
const
|
|
25
|
-
exports.DownloadCache =
|
|
26
|
-
const
|
|
27
|
-
exports.EXECUTABLE_EXTENSIONS =
|
|
28
|
-
exports.ARCHIVE_EXTENSIONS =
|
|
29
|
-
exports.DOCUMENT_EXTENSIONS =
|
|
30
|
-
exports.IMAGE_EXTENSIONS =
|
|
31
|
-
exports.VIDEO_EXTENSIONS =
|
|
32
|
-
exports.AUDIO_EXTENSIONS =
|
|
33
|
-
exports.FONT_EXTENSIONS =
|
|
34
|
-
exports.WEB_ASSET_EXTENSIONS =
|
|
35
|
-
exports.DATA_EXTENSIONS =
|
|
36
|
-
exports.EXECUTABLE_MIME_TYPES =
|
|
37
|
-
exports.ARCHIVE_MIME_TYPES =
|
|
38
|
-
exports.DOCUMENT_MIME_TYPES =
|
|
39
|
-
exports.IMAGE_MIME_TYPES =
|
|
40
|
-
exports.VIDEO_MIME_TYPES =
|
|
41
|
-
exports.AUDIO_MIME_TYPES =
|
|
42
|
-
exports.FONT_MIME_TYPES =
|
|
43
|
-
exports.WEB_ASSET_MIME_TYPES =
|
|
44
|
-
exports.DATA_MIME_TYPES =
|
|
45
|
-
exports.SAFE_WEB_PRESET =
|
|
46
|
-
exports.DOCUMENTS_ONLY_PRESET =
|
|
47
|
-
exports.NO_MEDIA_PRESET =
|
|
48
|
-
exports.MINIMAL_MIRROR_PRESET =
|
|
49
|
-
exports.TEXT_ONLY_PRESET =
|
|
1
|
+
const _mod_2ywfel = require('./types.cjs');
|
|
2
|
+
exports.WgetError = _mod_2ywfel.WgetError;;
|
|
3
|
+
const _mod_c0trhg = require('./asset-extractor.cjs');
|
|
4
|
+
exports.AssetExtractor = _mod_c0trhg.AssetExtractor;;
|
|
5
|
+
const _mod_gwrc5v = require('./url-filter.cjs');
|
|
6
|
+
exports.UrlFilter = _mod_gwrc5v.UrlFilter;;
|
|
7
|
+
const _mod_0vtg4c = require('./file-writer.cjs');
|
|
8
|
+
exports.FileWriter = _mod_0vtg4c.FileWriter;;
|
|
9
|
+
const _mod_ogodcn = require('./robots.cjs');
|
|
10
|
+
exports.RobotsHandler = _mod_ogodcn.RobotsHandler;;
|
|
11
|
+
const _mod_z2md6p = require('./resume.cjs');
|
|
12
|
+
exports.ResumeHandler = _mod_z2md6p.ResumeHandler;;
|
|
13
|
+
const _mod_z0gqsu = require('./progress.cjs');
|
|
14
|
+
exports.ProgressReporter = _mod_z0gqsu.ProgressReporter;
|
|
15
|
+
exports.ProgressTracker = _mod_z0gqsu.ProgressTracker;
|
|
16
|
+
exports.parseSize = _mod_z0gqsu.parseSize;;
|
|
17
|
+
const _mod_47n6vp = require('./link-converter.cjs');
|
|
18
|
+
exports.LinkConverter = _mod_47n6vp.LinkConverter;;
|
|
19
|
+
const _mod_xg400m = require('./downloader.cjs');
|
|
20
|
+
exports.Downloader = _mod_xg400m.Downloader;;
|
|
21
|
+
const _mod_gxrug3 = require('./asset-organizer.cjs');
|
|
22
|
+
exports.AssetOrganizer = _mod_gxrug3.AssetOrganizer;
|
|
23
|
+
exports.DEFAULT_ASSET_FOLDERS = _mod_gxrug3.DEFAULT_ASSET_FOLDERS;;
|
|
24
|
+
const _mod_p3i8r6 = require('./download-cache.cjs');
|
|
25
|
+
exports.DownloadCache = _mod_p3i8r6.DownloadCache;;
|
|
26
|
+
const _mod_ufb6gl = require('./filter-lists.cjs');
|
|
27
|
+
exports.EXECUTABLE_EXTENSIONS = _mod_ufb6gl.EXECUTABLE_EXTENSIONS;
|
|
28
|
+
exports.ARCHIVE_EXTENSIONS = _mod_ufb6gl.ARCHIVE_EXTENSIONS;
|
|
29
|
+
exports.DOCUMENT_EXTENSIONS = _mod_ufb6gl.DOCUMENT_EXTENSIONS;
|
|
30
|
+
exports.IMAGE_EXTENSIONS = _mod_ufb6gl.IMAGE_EXTENSIONS;
|
|
31
|
+
exports.VIDEO_EXTENSIONS = _mod_ufb6gl.VIDEO_EXTENSIONS;
|
|
32
|
+
exports.AUDIO_EXTENSIONS = _mod_ufb6gl.AUDIO_EXTENSIONS;
|
|
33
|
+
exports.FONT_EXTENSIONS = _mod_ufb6gl.FONT_EXTENSIONS;
|
|
34
|
+
exports.WEB_ASSET_EXTENSIONS = _mod_ufb6gl.WEB_ASSET_EXTENSIONS;
|
|
35
|
+
exports.DATA_EXTENSIONS = _mod_ufb6gl.DATA_EXTENSIONS;
|
|
36
|
+
exports.EXECUTABLE_MIME_TYPES = _mod_ufb6gl.EXECUTABLE_MIME_TYPES;
|
|
37
|
+
exports.ARCHIVE_MIME_TYPES = _mod_ufb6gl.ARCHIVE_MIME_TYPES;
|
|
38
|
+
exports.DOCUMENT_MIME_TYPES = _mod_ufb6gl.DOCUMENT_MIME_TYPES;
|
|
39
|
+
exports.IMAGE_MIME_TYPES = _mod_ufb6gl.IMAGE_MIME_TYPES;
|
|
40
|
+
exports.VIDEO_MIME_TYPES = _mod_ufb6gl.VIDEO_MIME_TYPES;
|
|
41
|
+
exports.AUDIO_MIME_TYPES = _mod_ufb6gl.AUDIO_MIME_TYPES;
|
|
42
|
+
exports.FONT_MIME_TYPES = _mod_ufb6gl.FONT_MIME_TYPES;
|
|
43
|
+
exports.WEB_ASSET_MIME_TYPES = _mod_ufb6gl.WEB_ASSET_MIME_TYPES;
|
|
44
|
+
exports.DATA_MIME_TYPES = _mod_ufb6gl.DATA_MIME_TYPES;
|
|
45
|
+
exports.SAFE_WEB_PRESET = _mod_ufb6gl.SAFE_WEB_PRESET;
|
|
46
|
+
exports.DOCUMENTS_ONLY_PRESET = _mod_ufb6gl.DOCUMENTS_ONLY_PRESET;
|
|
47
|
+
exports.NO_MEDIA_PRESET = _mod_ufb6gl.NO_MEDIA_PRESET;
|
|
48
|
+
exports.MINIMAL_MIRROR_PRESET = _mod_ufb6gl.MINIMAL_MIRROR_PRESET;
|
|
49
|
+
exports.TEXT_ONLY_PRESET = _mod_ufb6gl.TEXT_ONLY_PRESET;;
|
|
50
50
|
const { Downloader } = require('./downloader.cjs');
|
|
51
51
|
const rezo = require('../index.cjs');
|
|
52
52
|
const { promises: fs } = require("node:fs");
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "rezo",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.77",
|
|
4
4
|
"description": "Lightning-fast, enterprise-grade HTTP client for modern JavaScript. Full HTTP/2 support, intelligent cookie management, multiple adapters (HTTP, Fetch, cURL, XHR), streaming, proxy support (HTTP/HTTPS/SOCKS), and cross-environment compatibility.",
|
|
5
5
|
"main": "dist/index.cjs",
|
|
6
6
|
"module": "dist/index.js",
|