diff --git a/package-lock.json b/package-lock.json index cdca7e7..3309ced 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,17 +1,18 @@ { "name": "headless-task-server", - "version": "1.4.2", + "version": "1.4.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "headless-task-server", - "version": "1.4.2", + "version": "1.4.3", "hasInstallScript": true, "license": "MIT", "dependencies": { - "@ulixee/hero": "^2.0.0-alpha.21", - "@ulixee/hero-core": "^2.0.0-alpha.21", + "@ulixee/execute-js-plugin": "^2.0.0-alpha.23", + "@ulixee/hero": "^2.0.0-alpha.23", + "@ulixee/hero-core": "^2.0.0-alpha.23", "axios": "^1.3.4", "cors": "^2.8.5", "express": "^4.17.1", @@ -48,11 +49,20 @@ "node": ">=12" } }, + "node_modules/@cspotcode/source-map-support/node_modules/@jridgewell/trace-mapping": { + "version": "0.3.9", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz", + "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==", + "dev": true, + "dependencies": { + "@jridgewell/resolve-uri": "^3.0.3", + "@jridgewell/sourcemap-codec": "^1.4.10" + } + }, "node_modules/@jridgewell/resolve-uri": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.1.tgz", "integrity": "sha512-dSYZh7HhCDtCKm4QakX0xFpsRDqjjtZf/kjI/v3T3Nwt5r8/qz/M19F9ySyOqU94SXBmeG9ttTul+YnR4LOxFA==", - "dev": true, "engines": { "node": ">=6.0.0" } @@ -60,17 +70,15 @@ "node_modules/@jridgewell/sourcemap-codec": { "version": "1.4.15", "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.15.tgz", - "integrity": "sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==", - "dev": true + "integrity": "sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==" }, "node_modules/@jridgewell/trace-mapping": { - "version": "0.3.9", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz", - "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==", - "dev": true, + "version": "0.3.19", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.19.tgz", + "integrity": "sha512-kf37QtfW+Hwx/buWGMPcR60iF9ziHa6r/CZJIHbmcm4+0qrXiVdxegAH0F6yddEVQ7zdkjcGCgCzUu+BcbhQxw==", "dependencies": { - "@jridgewell/resolve-uri": "^3.0.3", - "@jridgewell/sourcemap-codec": "^1.4.10" + "@jridgewell/resolve-uri": "^3.1.0", + "@jridgewell/sourcemap-codec": "^1.4.14" } }, "node_modules/@leichtgewicht/ip-codec": { @@ -97,9 +105,9 @@ "dev": true }, "node_modules/@tsconfig/node16": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.3.tgz", - "integrity": "sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ==", + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.4.tgz", + "integrity": "sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA==", "dev": true }, "node_modules/@types/body-parser": { @@ -158,20 +166,27 @@ } }, "node_modules/@types/express-serve-static-core": { - "version": "4.17.33", - "resolved": "https://registry.npmjs.org/@types/express-serve-static-core/-/express-serve-static-core-4.17.33.tgz", - "integrity": "sha512-TPBqmR/HRYI3eC2E5hmiivIzv+bidAfXofM+sbonAGvyDhySGw9/PQZFt2BLOrjUUR++4eJVpx6KnLQK1Fk9tA==", + "version": "4.17.35", + "resolved": "https://registry.npmjs.org/@types/express-serve-static-core/-/express-serve-static-core-4.17.35.tgz", + "integrity": "sha512-wALWQwrgiB2AWTT91CB62b6Yt0sNHpznUXeZEcnPU3DRdlDIz74x8Qg1UUYKSVFi+va5vKOLYRBI1bRKiLLKIg==", "dev": true, "dependencies": { "@types/node": "*", "@types/qs": "*", - "@types/range-parser": "*" + "@types/range-parser": "*", + "@types/send": "*" } }, + "node_modules/@types/http-errors": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/@types/http-errors/-/http-errors-2.0.1.tgz", + "integrity": "sha512-/K3ds8TRAfBvi5vfjuz8y6+GiAYBZ0x4tXv1Av6CWBWn0IlADc+ZX9pMq7oU0fNQPnBwIZl3rmeLp6SBApbxSQ==", + "dev": true + }, "node_modules/@types/mime": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/@types/mime/-/mime-3.0.1.tgz", - "integrity": "sha512-Y4XFY5VJAuw0FgAqPNd6NNoV44jbq9Bz2L7Rh/J6jLTiHBSBJa9fxqQIvkIld4GsoDOcCbvzOUAbLPsSKKg+uA==", + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/@types/mime/-/mime-1.3.2.tgz", + "integrity": "sha512-YATxVxgRqNH6nHEIsvg6k2Boc1JHI9ZbH5iWFFv/MTkchz3b1ieGDa5T0a9RznNdI0KhVbdbWSN+KWWrQZRxTw==", "dev": true }, "node_modules/@types/node": { @@ -192,12 +207,23 @@ "integrity": "sha512-EEhsLsD6UsDM1yFhAvy0Cjr6VwmpMWqFBCb9w07wVugF7w9nfajxLuVmngTIpgS6svCnm6Vaw+MZhoDCKnOfsw==", "dev": true }, + "node_modules/@types/send": { + "version": "0.17.1", + "resolved": "https://registry.npmjs.org/@types/send/-/send-0.17.1.tgz", + "integrity": "sha512-Cwo8LE/0rnvX7kIIa3QHCkcuF21c05Ayb0ZfxPiv0W8VRiZiNW/WuRupHKpqqGVGf7SUA44QSOUKaEd9lIrd/Q==", + "dev": true, + "dependencies": { + "@types/mime": "^1", + "@types/node": "*" + } + }, "node_modules/@types/serve-static": { - "version": "1.15.1", - "resolved": "https://registry.npmjs.org/@types/serve-static/-/serve-static-1.15.1.tgz", - "integrity": "sha512-NUo5XNiAdULrJENtJXZZ3fHtfMolzZwczzBbnAeBbqBwG+LaG6YaJtuwzwGSQZ2wsCrxjEhNNjAkKigy3n8teQ==", + "version": "1.15.2", + "resolved": "https://registry.npmjs.org/@types/serve-static/-/serve-static-1.15.2.tgz", + "integrity": "sha512-J2LqtvFYCzaj8pVYKw8klQXrLLk7TBZmQ4ShlcdkELFKGwGMfevMLneMMRkMgZxotOD9wg497LpC7O8PcvAmfw==", "dev": true, "dependencies": { + "@types/http-errors": "*", "@types/mime": "*", "@types/node": "*" } @@ -210,10 +236,10 @@ "@ulixee/js-path": "^2.0.0-alpha.18" } }, - "node_modules/@ulixee/chrome-112-0": { - "version": "5615.138.8", - "resolved": "https://registry.npmjs.org/@ulixee/chrome-112-0/-/chrome-112-0-5615.138.8.tgz", - "integrity": "sha512-sPdxvl7CD6yHyXGFTbiw+PaV3M9irgKUjl+cmivyv9LPNEm5GsfCj/tPut7Eot8S+Q8kO3yAWM+kusB8xvaYcg==", + "node_modules/@ulixee/chrome-114-0": { + "version": "5735.199.8", + "resolved": "https://registry.npmjs.org/@ulixee/chrome-114-0/-/chrome-114-0-5735.199.8.tgz", + "integrity": "sha512-zjau/ScbH6M7NdnWu9+RIJfaG13Kg7H2JRCafzNKzN2AetT37bOPHCthE3WRLZXZ+7nzTPA8NvYm8tKKyp6pyg==", "hasInstallScript": true, "dependencies": { "@ulixee/chrome-app": "^1.0.3" @@ -233,234 +259,260 @@ } }, "node_modules/@ulixee/commons": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/commons/-/commons-2.0.0-alpha.21.tgz", - "integrity": "sha512-py2rKMgNLA06bCD6A/NaHpt41cx5NkyC1e2dSg6c4/iBY6UuVGi5cDlpstqApPVhMVNFzaukfUfF+y4FDTBVPw==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/commons/-/commons-2.0.0-alpha.23.tgz", + "integrity": "sha512-R+xxyCeqLGD8IbgGyGaUsPV9bp8Qmw26+ZEp8VE/az6Vx85pPG0UzXPM1pTIifSea+6rOHlFrw/ylaRtZA/iFA==", "dependencies": { + "@jridgewell/trace-mapping": "^0.3.18", "bech32": "^2.0.0", - "devtools-protocol": "^0.0.981744", + "devtools-protocol": "^0.0.1137505", "https-proxy-agent": "^5.0.0", - "semver": "^7.3.7", - "source-map-js": "^1.0.1" + "semver": "^7.3.7" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, "node_modules/@ulixee/default-browser-emulator": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/default-browser-emulator/-/default-browser-emulator-2.0.0-alpha.21.tgz", - "integrity": "sha512-2N8BUV6RDEnhpdmbvAwa/eamLmhHDUnNtMCt4xu7Z8kNBDVI1xKjf2Qm1F8M6+4CswHK7N58jYGm0wbSMy/1kA==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/default-browser-emulator/-/default-browser-emulator-2.0.0-alpha.23.tgz", + "integrity": "sha512-uCN9AjWS9q/h/NVPHvVQhZwNknUiukdGYEhlgwBz0wUERl48pT4l1s75fwWJaxscaJlY+4o9+oln78uOu9Gr5w==", "dependencies": { - "@ulixee/chrome-112-0": "^5615.121.7", "@ulixee/chrome-app": "^1.0.3", - "@ulixee/commons": "2.0.0-alpha.21", - "@ulixee/real-user-agents": "2.0.0-alpha.21", - "@ulixee/unblocked-agent-mitm-socket": "2.0.0-alpha.21", - "@ulixee/unblocked-specification": "2.0.0-alpha.21", + "@ulixee/commons": "2.0.0-alpha.23", + "@ulixee/real-user-agents": "2.0.0-alpha.23", + "@ulixee/unblocked-agent-mitm-socket": "2.0.0-alpha.23", + "@ulixee/unblocked-specification": "2.0.0-alpha.23", "compare-versions": "^3.6.0", - "nanoid": "^3.1.30", + "nanoid": "^3.3.6", "tough-cookie": "^4.0.0", "ua-parser-js": "^0.7.22" }, "engines": { - "node": ">=14.18.0" + "node": ">=16" } }, "node_modules/@ulixee/default-human-emulator": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/default-human-emulator/-/default-human-emulator-2.0.0-alpha.21.tgz", - "integrity": "sha512-l1mEsbECvLirsr33MKxvgtrMscG7Go8cL1vpVE1t1fjlbDireIFDbCdX0z+KzlKdkcL3IRy/MX3S3ySXaRTG3Q==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/default-human-emulator/-/default-human-emulator-2.0.0-alpha.23.tgz", + "integrity": "sha512-4Xex3oTh5zAth+nFfqdnlr0opV8uC0JpneP5IZVMobDMOHA4SKkz6vLK+4kmtOT/9l2BeVRt0mwF2A+8cD1jyg==", "dependencies": { - "@ulixee/commons": "2.0.0-alpha.21", - "@ulixee/unblocked-specification": "2.0.0-alpha.21" + "@ulixee/commons": "2.0.0-alpha.23", + "@ulixee/unblocked-specification": "2.0.0-alpha.23" }, "engines": { - "node": ">=14.18.0" + "node": ">=16" + } + }, + "node_modules/@ulixee/execute-js-plugin": { + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/execute-js-plugin/-/execute-js-plugin-2.0.0-alpha.23.tgz", + "integrity": "sha512-6hPkh6he6G0h1h4QmXB2XQTDPeT7M7xPdO7jXb++DknzsSBYd1r8GBFDqSH1vUM0Fy7yYigi0+J694R9FNgbrw==", + "dependencies": { + "@ulixee/hero-interfaces": "2.0.0-alpha.23", + "@ulixee/hero-plugin-utils": "2.0.0-alpha.23" + }, + "engines": { + "node": ">=16" } }, "node_modules/@ulixee/hero": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/hero/-/hero-2.0.0-alpha.21.tgz", - "integrity": "sha512-pNMHSwDG5YyVyvmoniyDLH2DQryXOixsewoyTOoLt8fx0HE1BrFo73MT946+ZKQBjtl1O8OdFtEJCYsxrcMHpA==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/hero/-/hero-2.0.0-alpha.23.tgz", + "integrity": "sha512-gAhdLVxoTWz8LMZCkQYV1sEwMaLIKXrBW0bDn0zjJOKPBJ7femgn1VV/uUvkLgwdEKKaYdLx20zprpW0+gXR0g==", "dependencies": { "@ulixee/awaited-dom": "1.4.2", - "@ulixee/commons": "2.0.0-alpha.21", - "@ulixee/hero-interfaces": "2.0.0-alpha.21", - "@ulixee/hero-plugin-utils": "2.0.0-alpha.21", - "@ulixee/js-path": "2.0.0-alpha.21", - "@ulixee/net": "2.0.0-alpha.21", - "@ulixee/unblocked-specification": "2.0.0-alpha.21", + "@ulixee/commons": "2.0.0-alpha.23", + "@ulixee/hero-interfaces": "2.0.0-alpha.23", + "@ulixee/hero-plugin-utils": "2.0.0-alpha.23", + "@ulixee/js-path": "2.0.0-alpha.23", + "@ulixee/net": "2.0.0-alpha.23", + "@ulixee/unblocked-specification": "2.0.0-alpha.23", "linkedom": "^0.14.11" }, "engines": { - "node": ">=14.0.0" + "node": ">=16" } }, "node_modules/@ulixee/hero-core": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/hero-core/-/hero-core-2.0.0-alpha.21.tgz", - "integrity": "sha512-X3ELmDjR3FDG2HpkdelYaSGjoT1DbqBEhlRI/mKG0i4v4QInxErEXtJF8urv2sg/OEE+28ILoKDWatCvOB3idg==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/hero-core/-/hero-core-2.0.0-alpha.23.tgz", + "integrity": "sha512-+kaKtehbKtPij6FZw3S1fgwiIFmZUl+Sz54ey7+FlY2BlH/yvbB+MWwomEDkCo6y9vQyiDMOZ0EG1FaF5sBOgQ==", "dependencies": { "@ulixee/awaited-dom": "1.4.2", - "@ulixee/commons": "2.0.0-alpha.21", - "@ulixee/default-browser-emulator": "2.0.0-alpha.21", - "@ulixee/default-human-emulator": "2.0.0-alpha.21", - "@ulixee/hero-interfaces": "2.0.0-alpha.21", - "@ulixee/hero-plugin-utils": "2.0.0-alpha.21", - "@ulixee/hero-timetravel": "2.0.0-alpha.21", - "@ulixee/js-path": "2.0.0-alpha.21", - "@ulixee/net": "2.0.0-alpha.21", - "@ulixee/unblocked-agent": "2.0.0-alpha.21", - "@ulixee/unblocked-agent-mitm": "2.0.0-alpha.21", - "@ulixee/unblocked-specification": "2.0.0-alpha.21", - "better-sqlite3": "^8.0.1", + "@ulixee/commons": "2.0.0-alpha.23", + "@ulixee/default-browser-emulator": "2.0.0-alpha.23", + "@ulixee/default-human-emulator": "2.0.0-alpha.23", + "@ulixee/hero-interfaces": "2.0.0-alpha.23", + "@ulixee/hero-plugin-utils": "2.0.0-alpha.23", + "@ulixee/hero-timetravel": "2.0.0-alpha.23", + "@ulixee/js-path": "2.0.0-alpha.23", + "@ulixee/net": "2.0.0-alpha.23", + "@ulixee/unblocked-agent": "2.0.0-alpha.23", + "@ulixee/unblocked-agent-mitm": "2.0.0-alpha.23", + "@ulixee/unblocked-specification": "2.0.0-alpha.23", + "better-sqlite3": "^8.4.0", "moment": "^2.29.4", - "nanoid": "^3.1.30", + "nanoid": "^3.3.6", "ws": "^7.4.6" }, "engines": { - "node": ">=14.0.0" + "node": ">=16" } }, "node_modules/@ulixee/hero-interfaces": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/hero-interfaces/-/hero-interfaces-2.0.0-alpha.21.tgz", - "integrity": "sha512-BUkUMtdsE8DthgmvLGvbswq0QqcfF4oE/URTRl3mENmX86qasKkV+AtelplN1Q4NechfSTGZ1ITMIYObq/OM4w==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/hero-interfaces/-/hero-interfaces-2.0.0-alpha.23.tgz", + "integrity": "sha512-I1sgdGGptKuGqGJ7nD9s8H709qoeCG7D29MDP6ldD7ErH2F46zjkt8JmkScBedpz01yuAvTbKlf97aFq7kUPwA==", "dependencies": { "@ulixee/awaited-dom": "1.4.2", - "@ulixee/commons": "2.0.0-alpha.21", - "@ulixee/js-path": "2.0.0-alpha.21", - "@ulixee/unblocked-specification": "2.0.0-alpha.21", + "@ulixee/commons": "2.0.0-alpha.23", + "@ulixee/js-path": "2.0.0-alpha.23", + "@ulixee/unblocked-specification": "2.0.0-alpha.23", "devtools-protocol": "^0.0.981744" }, "engines": { - "node": ">=14.0.0" + "node": ">=16" } }, + "node_modules/@ulixee/hero-interfaces/node_modules/devtools-protocol": { + "version": "0.0.981744", + "resolved": "https://registry.npmjs.org/devtools-protocol/-/devtools-protocol-0.0.981744.tgz", + "integrity": "sha512-0cuGS8+jhR67Fy7qG3i3Pc7Aw494sb9yG9QgpG97SFVWwolgYjlhJg7n+UaHxOQT30d1TYu/EYe9k01ivLErIg==" + }, "node_modules/@ulixee/hero-plugin-utils": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/hero-plugin-utils/-/hero-plugin-utils-2.0.0-alpha.21.tgz", - "integrity": "sha512-K7wdMa3mutIiQFgRE+JFCRtLlf71K3112s6UIuboO0Ud383t3dyyXG1rv1Pv+czE46vLSHJFs2w9cDK/qzh0XA==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/hero-plugin-utils/-/hero-plugin-utils-2.0.0-alpha.23.tgz", + "integrity": "sha512-9goE27Un4VzNfIggziT6Dq1b2h0ZW2JkxxashcACwh9wXJuOWkaIWIT3P6fNU9+yZzsDvNjo6RRrCVQqGi2HmA==", "dependencies": { - "@ulixee/commons": "2.0.0-alpha.21", - "@ulixee/hero-interfaces": "2.0.0-alpha.21", - "@ulixee/unblocked-specification": "2.0.0-alpha.21" + "@ulixee/commons": "2.0.0-alpha.23", + "@ulixee/hero-interfaces": "2.0.0-alpha.23", + "@ulixee/unblocked-specification": "2.0.0-alpha.23" }, "engines": { - "node": ">=14.0.0" + "node": ">=16" } }, "node_modules/@ulixee/hero-timetravel": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/hero-timetravel/-/hero-timetravel-2.0.0-alpha.21.tgz", - "integrity": "sha512-T7+edgLVyMaG8hbkcbre47CxH5cbe9zw9vJHY2k0MYWc/wBy4U6uDszSTnw09tH3h7bG3MwQrO1j4ue+UdQPgw==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/hero-timetravel/-/hero-timetravel-2.0.0-alpha.23.tgz", + "integrity": "sha512-6NZ7A8o0f+JwcWKoNdv5T1ZKaGi4+5Y93LvZQRab6fXUCWDF3e5vC5gNM0jQtraRDo4BgNO4rAUcWsNzERdVnA==", "dependencies": { - "@ulixee/commons": "2.0.0-alpha.21", - "@ulixee/hero-core": "2.0.0-alpha.21", - "@ulixee/hero-interfaces": "2.0.0-alpha.21", - "@ulixee/unblocked-agent": "2.0.0-alpha.21", - "@ulixee/unblocked-specification": "2.0.0-alpha.21", - "nanoid": "^3.1.30" + "@ulixee/commons": "2.0.0-alpha.23", + "@ulixee/hero-core": "2.0.0-alpha.23", + "@ulixee/hero-interfaces": "2.0.0-alpha.23", + "@ulixee/unblocked-agent": "2.0.0-alpha.23", + "@ulixee/unblocked-specification": "2.0.0-alpha.23", + "nanoid": "^3.3.6" }, "engines": { - "node": ">=14.0.0" + "node": ">=16" } }, "node_modules/@ulixee/js-path": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/js-path/-/js-path-2.0.0-alpha.21.tgz", - "integrity": "sha512-ZJXGt/y2oMEKFSHYhbibFSpzj3C1MJGb3iairHF+MlVG7nVe2kNzbFhkSxRvl5+xYQgV7b/Rn5d8pMluXp1azg==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/js-path/-/js-path-2.0.0-alpha.23.tgz", + "integrity": "sha512-2MXqYpI5UILaj0SRHg0qiKs9Y7uR1/WIHZc2GpapsY2dfnD4izUNvmOxqoQP+pmTsEgZFxL2TdyCZZfaTSBvvQ==", "engines": { - "node": ">=14.18.0" + "node": ">=16" } }, "node_modules/@ulixee/net": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/net/-/net-2.0.0-alpha.21.tgz", - "integrity": "sha512-iyOUKgpYGNlNCnfGxycdI6R2ceTctcQws7J+LMSRRSeyZFGberwi6FTtdq/jYU2Rcv1SSHjDKnC2VpubmbHxmw==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/net/-/net-2.0.0-alpha.23.tgz", + "integrity": "sha512-Eyr+klqsCf6RA49ruxoCVSHRNzzI4+AXyCJWCfiCdwvTfcczKY8QP/UHWefSGZiiMePgH8EPC8aqHZx/A/QYjQ==", "dependencies": { - "@ulixee/commons": "2.0.0-alpha.21", + "@ulixee/commons": "2.0.0-alpha.23", "ws": "^7.4.6" }, "engines": { - "node": ">=14.0.0" + "node": ">=16.0.0" } }, "node_modules/@ulixee/real-user-agents": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/real-user-agents/-/real-user-agents-2.0.0-alpha.21.tgz", - "integrity": "sha512-2J3FmZM7LjkoyYtVz4VKHN0UA/zhc/9+5Ilk79+jX9MH7JOtF/JTHNerGhBml1b0VmOs3h5XA7GjmBBTrLNMuA==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/real-user-agents/-/real-user-agents-2.0.0-alpha.23.tgz", + "integrity": "sha512-Cy6OBf6iFnVh+zaGYoBtRFEjHkGKfpMbGeR1KHbDgYc7Jiaw7honOTsL5Tnp0o5h6WbVZKKGl+Mbh88sWTUUtA==", "dependencies": { - "@ulixee/commons": "2.0.0-alpha.21", - "@ulixee/unblocked-specification": "2.0.0-alpha.21", + "@ulixee/commons": "2.0.0-alpha.23", + "@ulixee/unblocked-specification": "2.0.0-alpha.23", "compare-versions": "^3.6.0", "ua-parser-js": "^0.7.24" }, "engines": { - "node": ">=14.18.0" + "node": ">=16" } }, "node_modules/@ulixee/unblocked-agent": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/unblocked-agent/-/unblocked-agent-2.0.0-alpha.21.tgz", - "integrity": "sha512-RWEYdhRErsuAti6YdvpCRf0Nx7u/9FdNU86UQPITOU1c997VoyKQSL+atn6QXgaUoLnVtSj6LK4v2qG8jXXO9A==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/unblocked-agent/-/unblocked-agent-2.0.0-alpha.23.tgz", + "integrity": "sha512-GjSZxrEUWyMDjyYPCrvrgIaw2DNbo5/QAMkSN63tl+4s0n7A8ksT/g3vYwVPoJQCwfF5PvaMuNLkhDoW5e9epQ==", "dependencies": { - "@ulixee/chrome-112-0": "^5615.121.7", + "@ulixee/chrome-114-0": "^5735.91.8", "@ulixee/chrome-app": "^1.0.3", - "@ulixee/commons": "2.0.0-alpha.21", - "@ulixee/js-path": "2.0.0-alpha.21", - "@ulixee/unblocked-agent-mitm": "2.0.0-alpha.21", - "@ulixee/unblocked-specification": "2.0.0-alpha.21", + "@ulixee/commons": "2.0.0-alpha.23", + "@ulixee/js-path": "2.0.0-alpha.23", + "@ulixee/unblocked-agent-mitm": "2.0.0-alpha.23", + "@ulixee/unblocked-specification": "2.0.0-alpha.23", "devtools-protocol": "^0.0.981744", - "nanoid": "^3.3.3", + "nanoid": "^3.3.6", "tough-cookie": "^4.0.0" }, "engines": { - "node": ">=14.18.0" + "node": ">=16" } }, "node_modules/@ulixee/unblocked-agent-mitm": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/unblocked-agent-mitm/-/unblocked-agent-mitm-2.0.0-alpha.21.tgz", - "integrity": "sha512-UvREfbEXTXPY/GGUz0T+o9lPAIopGdpoieYefRxb2BkHWXIgdd1Yt3XSJDlg2AmS70gCPCjo9sSY8z2PmdPX9A==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/unblocked-agent-mitm/-/unblocked-agent-mitm-2.0.0-alpha.23.tgz", + "integrity": "sha512-UbR4MiwC5ltCLtMfeKj1BOjpOhEeUgz+v4aMhn5e7j5K4MvFaAPOFL4xgkgxEy7GU+Y+5HNcqFZoamzenYsyvA==", "dependencies": { - "@ulixee/commons": "2.0.0-alpha.21", - "@ulixee/unblocked-agent-mitm-socket": "2.0.0-alpha.21", - "@ulixee/unblocked-specification": "2.0.0-alpha.21", + "@ulixee/commons": "2.0.0-alpha.23", + "@ulixee/unblocked-agent-mitm-socket": "2.0.0-alpha.23", + "@ulixee/unblocked-specification": "2.0.0-alpha.23", "dns-packet": "^5.2.4", "moment": "^2.29.4" }, "engines": { - "node": ">=14.18.0" + "node": ">=16" } }, "node_modules/@ulixee/unblocked-agent-mitm-socket": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/unblocked-agent-mitm-socket/-/unblocked-agent-mitm-socket-2.0.0-alpha.21.tgz", - "integrity": "sha512-Yx5ec7BAp4umBap399HofZzNbt378fWrWinv+eVnq5H+ZYQ2dmJqsYB7z4PhRV3ki/j0RBAHBH+B6UhSSZE68A==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/unblocked-agent-mitm-socket/-/unblocked-agent-mitm-socket-2.0.0-alpha.23.tgz", + "integrity": "sha512-HBVwSupSZBP970+HHjS3gGnVsjrEyLQ7aFI4hjF0N/aNzUp76Np/2QA1lbQGXS1/KhcElIlQqwhv4HrUpB2F6w==", "hasInstallScript": true, "dependencies": { - "@ulixee/commons": "2.0.0-alpha.21", - "@ulixee/unblocked-specification": "2.0.0-alpha.21", - "nanoid": "^3.1.30" + "@ulixee/commons": "2.0.0-alpha.23", + "@ulixee/unblocked-specification": "2.0.0-alpha.23", + "nanoid": "^3.3.6" }, "engines": { - "node": ">=14.18.0" + "node": ">=16" } }, + "node_modules/@ulixee/unblocked-agent/node_modules/devtools-protocol": { + "version": "0.0.981744", + "resolved": "https://registry.npmjs.org/devtools-protocol/-/devtools-protocol-0.0.981744.tgz", + "integrity": "sha512-0cuGS8+jhR67Fy7qG3i3Pc7Aw494sb9yG9QgpG97SFVWwolgYjlhJg7n+UaHxOQT30d1TYu/EYe9k01ivLErIg==" + }, "node_modules/@ulixee/unblocked-specification": { - "version": "2.0.0-alpha.21", - "resolved": "https://registry.npmjs.org/@ulixee/unblocked-specification/-/unblocked-specification-2.0.0-alpha.21.tgz", - "integrity": "sha512-6YhjswMTuXS6IkPBRMFX2FwCC9aXdgFDSDlz4PSMuIK36lendMwl9S7reOpuQ64Lbkdn7P+9Y7XN+Fgcadiu3Q==", + "version": "2.0.0-alpha.23", + "resolved": "https://registry.npmjs.org/@ulixee/unblocked-specification/-/unblocked-specification-2.0.0-alpha.23.tgz", + "integrity": "sha512-nYcPHm/zDk+DyDOjtikusyPVvOtDBBM7ybcq9kuxo60MYGmYLS9Zft2vKUJqGUTQo7k1X8WhCZMkeHygLFRf5A==", "dependencies": { - "@ulixee/js-path": "2.0.0-alpha.21", + "@ulixee/js-path": "2.0.0-alpha.23", "devtools-protocol": "^0.0.981744" }, "engines": { - "node": ">=14.18.0" + "node": ">=16" } }, + "node_modules/@ulixee/unblocked-specification/node_modules/devtools-protocol": { + "version": "0.0.981744", + "resolved": "https://registry.npmjs.org/devtools-protocol/-/devtools-protocol-0.0.981744.tgz", + "integrity": "sha512-0cuGS8+jhR67Fy7qG3i3Pc7Aw494sb9yG9QgpG97SFVWwolgYjlhJg7n+UaHxOQT30d1TYu/EYe9k01ivLErIg==" + }, "node_modules/@yarnpkg/lockfile": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/@yarnpkg/lockfile/-/lockfile-1.1.0.tgz", @@ -479,9 +531,9 @@ } }, "node_modules/acorn": { - "version": "8.8.2", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz", - "integrity": "sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw==", + "version": "8.10.0", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.10.0.tgz", + "integrity": "sha512-F0SAmZ8iUtS//m8DmCTA0jlh6TDKkHQyK6xc6V4KDTyZKA9dnvX9/3sRTVQrWm79glUAZbnmmNcdYwUIHWVybw==", "dev": true, "bin": { "acorn": "bin/acorn" @@ -570,9 +622,9 @@ } }, "node_modules/axios": { - "version": "1.3.6", - "resolved": "https://registry.npmjs.org/axios/-/axios-1.3.6.tgz", - "integrity": "sha512-PEcdkk7JcdPiMDkvM4K6ZBRYq9keuVJsToxm2zQIM70Qqo2WHTdJZMXcG9X+RmRp2VPNUQC8W1RAGbgt6b1yMg==", + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.4.0.tgz", + "integrity": "sha512-S4XCWMEmzvo64T9GfvQDOXgYRDJ/wsSZc7Jvdgx5u1sd0JwsuPLqb3SYmusag+edF6ziyMensPVqLTSc1PiSEA==", "dependencies": { "follow-redirects": "^1.15.0", "form-data": "^4.0.0", @@ -609,9 +661,9 @@ "integrity": "sha512-LcknSilhIGatDAsY1ak2I8VtGaHNhgMSYVxFrGLXv+xLHytaKZKcaUJJUE7qmBr7h33o5YQwP55pMI0xmkpJwg==" }, "node_modules/better-sqlite3": { - "version": "8.3.0", - "resolved": "https://registry.npmjs.org/better-sqlite3/-/better-sqlite3-8.3.0.tgz", - "integrity": "sha512-JTmvBZL/JLTc+3Msbvq6gK6elbU9/wVMqiudplHrVJpr7sVMR9KJrNhZAbW+RhXKlpMcuEhYkdcHa3TXKNXQ1w==", + "version": "8.5.0", + "resolved": "https://registry.npmjs.org/better-sqlite3/-/better-sqlite3-8.5.0.tgz", + "integrity": "sha512-vbPcv/Hx5WYdyNg/NbcfyaBZyv9s/NVbxb7yCeC5Bq1pVocNxeL2tZmSu3Rlm4IEOTjYdGyzWQgyx0OSdORBzw==", "hasInstallScript": true, "dependencies": { "bindings": "^1.5.0", @@ -858,9 +910,9 @@ } }, "node_modules/cross-spawn/node_modules/semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", + "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", "bin": { "semver": "bin/semver" } @@ -952,17 +1004,17 @@ } }, "node_modules/detect-libc": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.0.1.tgz", - "integrity": "sha512-463v3ZeIrcWtdgIg6vI6XUncguvr2TnGl4SzDXinkt9mSLpBJKXT3mW6xT3VQdDN11+WVs29pgvivTc4Lp8v+w==", + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.0.2.tgz", + "integrity": "sha512-UX6sGumvvqSaXgdKGUsgZWqcUyIXZ/vZTrlRT/iobiKhGL0zL4d3osHj3uqllWJK+i+sixDS/3COVEOFbupFyw==", "engines": { "node": ">=8" } }, "node_modules/devtools-protocol": { - "version": "0.0.981744", - "resolved": "https://registry.npmjs.org/devtools-protocol/-/devtools-protocol-0.0.981744.tgz", - "integrity": "sha512-0cuGS8+jhR67Fy7qG3i3Pc7Aw494sb9yG9QgpG97SFVWwolgYjlhJg7n+UaHxOQT30d1TYu/EYe9k01ivLErIg==" + "version": "0.0.1137505", + "resolved": "https://registry.npmjs.org/devtools-protocol/-/devtools-protocol-0.0.1137505.tgz", + "integrity": "sha512-etlSdcQy8DiTCw5oV/AaQiEqEDMCHTGRcMpsqzlKUQQdC/AKadVNbN7GTVAwFOKtMo4i907DczhNkXebiZe85g==" }, "node_modules/diff": { "version": "4.0.2", @@ -1023,13 +1075,13 @@ } }, "node_modules/domutils": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/domutils/-/domutils-3.0.1.tgz", - "integrity": "sha512-z08c1l761iKhDFtfXO04C7kTdPBLi41zwOZl00WS8b5eiaebNpY00HKbztwBq+e3vyqWNwWF3mP9YLUeqIrF+Q==", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-3.1.0.tgz", + "integrity": "sha512-H78uMmQtI2AhgDJjWeQmHwJJ2bLPD3GMmO7Zja/ZZh84wkm+4ut+IUnUdRa8uCGX88DiVx1j6FRe1XfxEgjEZA==", "dependencies": { "dom-serializer": "^2.0.0", "domelementtype": "^2.3.0", - "domhandler": "^5.0.1" + "domhandler": "^5.0.3" }, "funding": { "url": "https://github.com/fb55/domutils?sponsor=1" @@ -1275,12 +1327,13 @@ "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" }, "node_modules/get-intrinsic": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.0.tgz", - "integrity": "sha512-L049y6nFOuom5wGyRc3/gdTLO94dySVKRACj1RmJZBQXlbTMhtNIgkWkUHq+jYmZvKf14EW1EoJnnjbmoHij0Q==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz", + "integrity": "sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw==", "dependencies": { "function-bind": "^1.1.1", "has": "^1.0.3", + "has-proto": "^1.0.1", "has-symbols": "^1.0.3" }, "funding": { @@ -1335,6 +1388,17 @@ "node": ">=8" } }, + "node_modules/has-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", + "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/has-symbols": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", @@ -1551,9 +1615,9 @@ } }, "node_modules/linkedom": { - "version": "0.14.25", - "resolved": "https://registry.npmjs.org/linkedom/-/linkedom-0.14.25.tgz", - "integrity": "sha512-Q5BvQVFzMveMxHvZ9L3E60duxSVPIWQRzY2HJKpCV4pRzY3jS/r/a1upLeo/Nup9mDRJ5MS0FX2hRR+wRo+Hiw==", + "version": "0.14.26", + "resolved": "https://registry.npmjs.org/linkedom/-/linkedom-0.14.26.tgz", + "integrity": "sha512-mK6TrydfFA7phrnp+1j57ycBwFI5bGSW6YXlw9acHoqF+mP/y+FooEYYyniOt5Ot57FSKB3iwmnuQ1UUyNLm5A==", "dependencies": { "css-select": "^5.1.0", "cssom": "^0.5.0", @@ -1673,9 +1737,9 @@ } }, "node_modules/minipass": { - "version": "4.2.8", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-4.2.8.tgz", - "integrity": "sha512-fNzuVyifolSLFL4NzpF+wEF4qrgqaaKX0haXPQEdQ7NKAN+WecoKMHV09YcuL/DHxrUsYQOK3MiuDf7Ip2OXfQ==", + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-5.0.0.tgz", + "integrity": "sha512-3FnjYuehv9k6ovOEbyOswadCDPX1piCfhV8ncmYtHOjuPwylVWsghTLo7rabjC3Rx5xD4HDx8Wm1xnMF7S5qFQ==", "engines": { "node": ">=8" } @@ -1768,9 +1832,9 @@ "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==" }, "node_modules/node-abi": { - "version": "3.40.0", - "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-3.40.0.tgz", - "integrity": "sha512-zNy02qivjjRosswoYmPi8hIKJRr8MpQyeKT6qlcq/OnOgA3Rhoae+IYOqsM9V5+JnHWmxKnWOT2GxvtqdtOCXA==", + "version": "3.45.0", + "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-3.45.0.tgz", + "integrity": "sha512-iwXuFrMAcFVi/ZoZiqq8BzAdsLw9kxDfTC0HMyjXfSL/6CSDAGD5UmR7azrAgWV1zKYq7dUUMj4owusBWKLsiQ==", "dependencies": { "semver": "^7.3.5" }, @@ -1900,9 +1964,9 @@ } }, "node_modules/patch-package/node_modules/semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.2.tgz", + "integrity": "sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==", "bin": { "semver": "bin/semver" } @@ -2133,9 +2197,9 @@ "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" }, "node_modules/semver": { - "version": "7.5.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.0.tgz", - "integrity": "sha512-+XC0AD/R7Q2mPSRuy2Id0+CGTZ98+8f+KvwirxOKIEyid+XSx6HbC63p+O4IndTHuX5Z+JxQ0TghCkO5Cg/2HA==", + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", "dependencies": { "lru-cache": "^6.0.0" }, @@ -2276,14 +2340,6 @@ "node": ">=6" } }, - "node_modules/source-map-js": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.0.2.tgz", - "integrity": "sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw==", - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", @@ -2320,13 +2376,13 @@ } }, "node_modules/tar": { - "version": "6.1.13", - "resolved": "https://registry.npmjs.org/tar/-/tar-6.1.13.tgz", - "integrity": "sha512-jdIBIN6LTIe2jqzay/2vtYLlBHa3JF42ot3h1dW8Q0PaAG4v8rm0cvpVePtau5C6OKXGGcgO9q2AMNSWxiLqKw==", + "version": "6.1.15", + "resolved": "https://registry.npmjs.org/tar/-/tar-6.1.15.tgz", + "integrity": "sha512-/zKt9UyngnxIT/EAGYuxaMYgOIJiP81ab9ZfkILq4oNLPFX50qyYmu7jRj9qeXoxmJHjGlbH0+cm2uy1WCs10A==", "dependencies": { "chownr": "^2.0.0", "fs-minipass": "^2.0.0", - "minipass": "^4.0.0", + "minipass": "^5.0.0", "minizlib": "^2.1.1", "mkdirp": "^1.0.3", "yallist": "^4.0.0" @@ -2397,9 +2453,9 @@ } }, "node_modules/tough-cookie": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-4.1.2.tgz", - "integrity": "sha512-G9fqXWoYFZgTc2z8Q5zaHy/vJMjm+WV0AkAeHxVCQiEB1b+dGvWzFW6QV07cY5jQ5gRkeid2qIkzkxUnmoQZUQ==", + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-4.1.3.tgz", + "integrity": "sha512-aX/y5pVRkfRnfmuX+OdbSdXvPe6ieKX/G2s7e98f4poJHnqH3281gDPm/metm6E/WRamfx7WC4HUqkWHfQHprw==", "dependencies": { "psl": "^1.1.33", "punycode": "^2.1.1", diff --git a/package.json b/package.json index 37ea7bc..b43af3c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "headless-task-server", - "version": "1.4.2", + "version": "1.4.3", "description": "A headless browser task manager based on Hero", "main": "dist/index.js", "engines": { @@ -57,8 +57,9 @@ "typescript": "^4.5.2" }, "dependencies": { - "@ulixee/hero": "^2.0.0-alpha.21", - "@ulixee/hero-core": "^2.0.0-alpha.21", + "@ulixee/hero": "^2.0.0-alpha.23", + "@ulixee/hero-core": "^2.0.0-alpha.23", + "@ulixee/execute-js-plugin": "^2.0.0-alpha.23", "axios": "^1.3.4", "cors": "^2.8.5", "express": "^4.17.1", diff --git a/src/clases/TasksPoolHandler.ts b/src/clases/TasksPoolHandler.ts index 4402ae5..8d5951d 100644 --- a/src/clases/TasksPoolHandler.ts +++ b/src/clases/TasksPoolHandler.ts @@ -1,7 +1,7 @@ import {TaskStatus} from "../enums/TaskStatus"; import Hero, {BlockedResourceType, ConnectionToHeroCore} from '@ulixee/hero'; -import Core from '@ulixee/hero-core'; +import HeroCore from '@ulixee/hero-core'; import {TransportBridge} from '@ulixee/net'; import Task from "./Task"; @@ -13,6 +13,8 @@ import TimeoutError from "@ulixee/commons/interfaces/TimeoutError"; import Logger from "./Logger"; import {clearTimeout} from "timers"; +import ExecuteJsPlugin from '@ulixee/execute-js-plugin'; + export default class TasksPoolHandler { private readonly maxConcurrency: number; private readonly queueTimeout: number; @@ -20,8 +22,9 @@ export default class TasksPoolHandler { private readonly sessionTimeout: number; private readonly upstreamProxyUrl: string|null; private readonly blockedResourceTypes: BlockedResourceType[]; + private readonly core: HeroCore; private isRunning: boolean = false; - private readonly timer?: NodeJS.Timer; + private timer?: NodeJS.Timer; private readonly connectionToCore: ConnectionToHeroCore; private pool: Task[] = []; private queue: Task[] = []; @@ -53,18 +56,16 @@ export default class TasksPoolHandler { this.upstreamProxyUrl = envString('UPSTREAM_PROXY_URL') ?? upstreamProxyUrl; this.blockedResourceTypes = blockedResourceTypes; + this.core = new HeroCore(); + const bridge = new TransportBridge(); this.connectionToCore = new ConnectionToHeroCore(bridge.transportToCore, { instanceTimeoutMillis: this.sessionTimeout, maxConcurrency: this.maxConcurrency * 4 }); - this.connectionToCore.on('disconnected', () => this.onDisconnected()) - Core.onShutdown = () => this.onDisconnected(); - - Core.addConnection(bridge.transportToClient); - - this.isRunning = true; - this.timer = setInterval(() => this.tick(), 10); + this.connectionToCore.on('disconnected', () => this.onDisconnected()); + this.core.addConnection(bridge.transportToClient); + this.core.use(ExecuteJsPlugin); } public push(task: Task): void { @@ -84,7 +85,7 @@ export default class TasksPoolHandler { this.queue.push(task); } - private execute(task: Task): void { + private async execute(task: Task): Promise { task.status = TaskStatus.RUNNING; //INIT_TIMEOUT Watchdog @@ -95,78 +96,79 @@ export default class TasksPoolHandler { clearTimeout(task.timer!); }, this.initTimeout); - const instance = new Hero({ - blockedResourceTypes: this.blockedResourceTypes, - upstreamProxyUrl: this.upstreamProxyUrl ?? undefined, - upstreamProxyIpMask: { - ipLookupService: IpLookupServices.aws, - }, - ...task.options, - showChrome: envBool('SHOW_CHROME'), - userProfile: task.profile, - connectionToCore: this.connectionToCore - }); + let instance: Hero | null = null; + try { + instance = new Hero({ + blockedResourceTypes: this.blockedResourceTypes, + upstreamProxyUrl: this.upstreamProxyUrl ?? undefined, + upstreamProxyIpMask: { + ipLookupService: IpLookupServices.aws, + }, + ...task.options, + showChrome: envBool('SHOW_CHROME'), + userProfile: task.profile, + connectionToCore: this.connectionToCore + }); + instance.use(ExecuteJsPlugin); - instance - .then(async (agent) => { - clearTimeout(task.timer!); - if (task.getIsFulfilled()) { - await agent.close(); - return; - } + clearTimeout(task.timer!); + if (task.getIsFulfilled()) { + await instance.close(); + return; + } - //SESSION_TIMEOUT Watchdog - task.timer = setTimeout(async () => { - this.counter.session_timeout++; - task.fulfill(TaskStatus.SESSION_TIMEOUT, null, 'Task: Script: Session Timeout'); - clearTimeout(task.timer!); - }, this.sessionTimeout); - - //@ts-ignore we have Omit, but to reduce complexity we represent as Hero - task.promise(agent) - .then(async () => { - this.counter.resolve++; - }) - .catch(async (error) => { - if (!task.getIsFulfilled()) { - (error instanceof Error && error.name === 'TaskOuterCatch') ? this.counter.throw++ : this.counter.reject++; - } - }) - .finally(async () => { - clearTimeout(task.timer!); - await agent.close(); - }); - }) - .catch(async (error) => { + //SESSION_TIMEOUT Watchdog + task.timer = setTimeout(async () => { + this.counter.session_timeout++; + task.fulfill(TaskStatus.SESSION_TIMEOUT, null, 'Task: Script: Session Timeout'); clearTimeout(task.timer!); + }, this.sessionTimeout); + + //@ts-ignore we have Omit, but to reduce complexity we represent as Hero + task.promise(instance) + .then(async () => { + this.counter.resolve++; + }) + .catch(async (error) => { + if (!task.getIsFulfilled()) { + (error instanceof Error && error.name === 'TaskOuterCatch') ? this.counter.throw++ : this.counter.reject++; + } + }) + .finally(async () => { + clearTimeout(task.timer!); + await instance?.close(); + }); + } + catch (error: any) { + clearTimeout(task.timer!); - //TimeoutError while connecting IpLookupServices for proxy check - //Possible error in proxy or target is down - if (error instanceof TimeoutError && error.message.includes('Timeout connecting to')) { - task.fulfill(TaskStatus.INIT_ERROR, null, `TaskPool: Agent: Proxy: ${error.name}: ${error.message}`); - await instance.close(); - } + //TimeoutError while connecting IpLookupServices for proxy check + //Possible error in proxy or target is down + if (error instanceof TimeoutError && error.message.includes('Timeout connecting to')) { + task.fulfill(TaskStatus.INIT_ERROR, null, `TaskPool: Agent: Proxy: ${error.name}: ${error.message}`); + await instance?.close(); + } //HttpProxyConnectError: Http Proxy Connect Error connection refused (404) - //form "@ulixee/unblocked-agent-mitm-socket" not exported - else if (error instanceof Error && error.name == 'HttpProxyConnectError') { - task.fulfill(TaskStatus.INIT_ERROR, null, `TaskPool: Agent: Proxy: ${error.name}: ${error.message}`); - await instance.close(); - } - //Socks5ProxyConnectError, same as HttpProxyConnectError above - else if (error instanceof Error && error.name == 'Socks5ProxyConnectError') { - task.fulfill(TaskStatus.INIT_ERROR, null, `TaskPool: Agent: Proxy: ${error.name}: ${error.message}`); - await instance.close(); - } - //handle fatal error, recommend to close all agents and restart app - else { - console.error(`TaskPool: Hero Core Init Error: ${error.name}: ${error.message}`); - task.fulfill(TaskStatus.INIT_ERROR, null, `TaskPool: Agent: ${error.name}: ${error.message}`); - this.close(); - await instance.close(); - console.warn('TaskPool: Hero Core Shutdown, waiting for pool to finish'); - this.onDisconnected() - } - }); + //form "@ulixee/unblocked-agent-mitm-socket" not exported + else if (error instanceof Error && error.name == 'HttpProxyConnectError') { + task.fulfill(TaskStatus.INIT_ERROR, null, `TaskPool: Agent: Proxy: ${error.name}: ${error.message}`); + await instance?.close(); + } + //Socks5ProxyConnectError, same as HttpProxyConnectError above + else if (error instanceof Error && error.name == 'Socks5ProxyConnectError') { + task.fulfill(TaskStatus.INIT_ERROR, null, `TaskPool: Agent: Proxy: ${error.name}: ${error.message}`); + await instance?.close(); + } + //handle fatal error, recommend to close all agents and restart app + else { + console.error(`TaskPool: Hero Core Init Error: ${error.name}: ${error.message}`); + task.fulfill(TaskStatus.INIT_ERROR, null, `TaskPool: Agent: ${error.name}: ${error.message}`); + this.close(); + await instance?.close(); + console.warn('TaskPool: Hero Core Shutdown, waiting for pool to finish'); + this.onDisconnected() + } + } } private tick(): void { @@ -187,8 +189,15 @@ export default class TasksPoolHandler { } } - public close(): void { + public async start(): Promise { + await this.core.start(); + this.isRunning = true; + this.timer = setInterval(() => this.tick(), 10); + } + + public async close(): Promise { clearInterval(this.timer); + await this.core.close(); this.isRunning = false; console.warn('TaskPool: Queue: Stopped'); diff --git a/src/index.ts b/src/index.ts index e3af356..95dbbf9 100644 --- a/src/index.ts +++ b/src/index.ts @@ -23,7 +23,7 @@ const webServer = new WebServer(config.SERVER_PORT); webServer.setAuthKey(config.AUTH_KEY); webServer.start() - .on('listening', () => { + .on('listening', async () => { const tasksHandler = new TasksPoolHandler( config.DEFAULT_MAX_CONCURRENCY, @@ -33,6 +33,7 @@ webServer.start() config.DEFAULT_UPSTREAM_PROXY_URL, config.DEFAULT_BLOCKED_RESOURCE_TYPES ); + await tasksHandler.start(); console.log('Browser Handler runned'); const buildTimeStamp: string | null = readFileSync('./dist/buildtimestamp', 'utf8').trim() ?? null; @@ -83,8 +84,8 @@ webServer.start() response.json(Logger.getRows()); }) - webServer.get('/restart', (request, response) => { - tasksHandler.close(); + webServer.get('/restart', async (request, response) => { + await tasksHandler.close(); response.json('restarting...'); tasksHandler.onDisconnected(); } @@ -125,6 +126,7 @@ webServer.start() } } else { + tasksHandler.incrementCounterBadArgs(); response .status(500) .json({ @@ -138,7 +140,7 @@ webServer.start() } }); }) - .on('error', () => { + .on('error',() => { console.error('Process stopped, port is busy.'); process.exit(1); }) diff --git a/tests/.gitkeep b/tests/.gitkeep deleted file mode 100644 index e69de29..0000000