@remotion/renderer 4.0.174 → 4.0.175
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/browser/BrowserRunner.js +12 -13
- package/dist/browser/util.d.ts +2 -11
- package/dist/browser/util.js +2 -2
- package/package.json +10 -10
|
@@ -53,7 +53,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
53
53
|
exports.BrowserRunner = void 0;
|
|
54
54
|
const childProcess = __importStar(require("node:child_process"));
|
|
55
55
|
const fs = __importStar(require("node:fs"));
|
|
56
|
-
const readline = __importStar(require("readline"));
|
|
57
56
|
const delete_directory_1 = require("../delete-directory");
|
|
58
57
|
const logger_1 = require("../logger");
|
|
59
58
|
const truthy_1 = require("../truthy");
|
|
@@ -233,15 +232,15 @@ class BrowserRunner {
|
|
|
233
232
|
exports.BrowserRunner = BrowserRunner;
|
|
234
233
|
_BrowserRunner_executablePath = new WeakMap(), _BrowserRunner_processArguments = new WeakMap(), _BrowserRunner_userDataDir = new WeakMap(), _BrowserRunner_closed = new WeakMap(), _BrowserRunner_listeners = new WeakMap(), _BrowserRunner_processClosing = new WeakMap();
|
|
235
234
|
function waitForWSEndpoint(browserProcess, timeout) {
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
let
|
|
235
|
+
const browserStderr = browserProcess.stderr;
|
|
236
|
+
(0, assert_1.assert)(browserStderr, '`browserProcess` does not have stderr.');
|
|
237
|
+
let stderrString = '';
|
|
239
238
|
return new Promise((resolve, reject) => {
|
|
239
|
+
browserStderr.addListener('data', onData);
|
|
240
|
+
browserProcess.addListener('close', onClose);
|
|
240
241
|
const listeners = [
|
|
241
|
-
(
|
|
242
|
-
(
|
|
243
|
-
return onClose();
|
|
244
|
-
}),
|
|
242
|
+
() => browserStderr.removeListener('data', onData),
|
|
243
|
+
() => browserStderr.removeListener('close', onClose),
|
|
245
244
|
(0, util_1.addEventListener)(browserProcess, 'exit', () => {
|
|
246
245
|
return onClose();
|
|
247
246
|
}),
|
|
@@ -255,7 +254,7 @@ function waitForWSEndpoint(browserProcess, timeout) {
|
|
|
255
254
|
reject(new Error([
|
|
256
255
|
'Failed to launch the browser process!',
|
|
257
256
|
error ? error.message : null,
|
|
258
|
-
|
|
257
|
+
stderrString,
|
|
259
258
|
'Troubleshooting: https://remotion.dev/docs/troubleshooting/browser-launch',
|
|
260
259
|
]
|
|
261
260
|
.filter(truthy_1.truthy)
|
|
@@ -263,11 +262,11 @@ function waitForWSEndpoint(browserProcess, timeout) {
|
|
|
263
262
|
}
|
|
264
263
|
function onTimeout() {
|
|
265
264
|
cleanup();
|
|
266
|
-
reject(new Errors_1.TimeoutError(`Timed out after ${timeout} ms while trying to connect to the browser! Chrome logged the following: ${
|
|
265
|
+
reject(new Errors_1.TimeoutError(`Timed out after ${timeout} ms while trying to connect to the browser! Chrome logged the following: ${stderrString}`));
|
|
267
266
|
}
|
|
268
|
-
function
|
|
269
|
-
|
|
270
|
-
const match =
|
|
267
|
+
function onData(data) {
|
|
268
|
+
stderrString += data.toString('utf8');
|
|
269
|
+
const match = stderrString.match(/DevTools listening on (ws:\/\/.*)/);
|
|
271
270
|
if (!match) {
|
|
272
271
|
return;
|
|
273
272
|
}
|
package/dist/browser/util.d.ts
CHANGED
|
@@ -21,17 +21,8 @@ import type { CommonEventEmitter } from './EventEmitter';
|
|
|
21
21
|
export declare function getExceptionMessage(exceptionDetails: ExceptionDetails): string;
|
|
22
22
|
export declare function valueFromRemoteObject(remoteObject: DevtoolsRemoteObject): any;
|
|
23
23
|
export declare function releaseObject(client: CDPSession, remoteObject: DevtoolsRemoteObject): Promise<void>;
|
|
24
|
-
export
|
|
25
|
-
|
|
26
|
-
eventName: string | symbol;
|
|
27
|
-
handler: (...args: any[]) => void;
|
|
28
|
-
}
|
|
29
|
-
export declare function addEventListener(emitter: CommonEventEmitter, eventName: string | symbol, handler: (...args: any[]) => void): PuppeteerEventListener;
|
|
30
|
-
export declare function removeEventListeners(listeners: Array<{
|
|
31
|
-
emitter: CommonEventEmitter;
|
|
32
|
-
eventName: string | symbol;
|
|
33
|
-
handler: (...args: any[]) => void;
|
|
34
|
-
}>): void;
|
|
24
|
+
export declare function addEventListener(emitter: CommonEventEmitter, eventName: string | symbol, handler: (...args: any[]) => void): () => CommonEventEmitter;
|
|
25
|
+
export declare function removeEventListeners(listeners: Array<() => void>): void;
|
|
35
26
|
export declare const isString: (obj: unknown) => obj is string;
|
|
36
27
|
export declare function evaluationString(fun: Function | string, ...args: unknown[]): string;
|
|
37
28
|
export declare function pageBindingDeliverResultString(name: string, seq: number, result: unknown): string;
|
package/dist/browser/util.js
CHANGED
|
@@ -74,12 +74,12 @@ async function releaseObject(client, remoteObject) {
|
|
|
74
74
|
exports.releaseObject = releaseObject;
|
|
75
75
|
function addEventListener(emitter, eventName, handler) {
|
|
76
76
|
emitter.on(eventName, handler);
|
|
77
|
-
return
|
|
77
|
+
return () => emitter.off(eventName, handler);
|
|
78
78
|
}
|
|
79
79
|
exports.addEventListener = addEventListener;
|
|
80
80
|
function removeEventListeners(listeners) {
|
|
81
81
|
for (const listener of listeners) {
|
|
82
|
-
listener
|
|
82
|
+
listener();
|
|
83
83
|
}
|
|
84
84
|
listeners.length = 0;
|
|
85
85
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@remotion/renderer",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.175",
|
|
4
4
|
"description": "Renderer for Remotion",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"extract-zip": "2.0.1",
|
|
19
19
|
"source-map": "^0.8.0-beta.0",
|
|
20
20
|
"ws": "8.7.0",
|
|
21
|
-
"remotion": "4.0.
|
|
21
|
+
"remotion": "4.0.175"
|
|
22
22
|
},
|
|
23
23
|
"peerDependencies": {
|
|
24
24
|
"react": ">=16.8.0",
|
|
@@ -41,16 +41,16 @@
|
|
|
41
41
|
"react-dom": "18.3.1",
|
|
42
42
|
"vitest": "0.31.1",
|
|
43
43
|
"@types/ws": "8.5.10",
|
|
44
|
-
"@remotion/streaming": "4.0.
|
|
44
|
+
"@remotion/streaming": "4.0.175"
|
|
45
45
|
},
|
|
46
46
|
"optionalDependencies": {
|
|
47
|
-
"@remotion/compositor-
|
|
48
|
-
"@remotion/compositor-
|
|
49
|
-
"@remotion/compositor-
|
|
50
|
-
"@remotion/compositor-
|
|
51
|
-
"@remotion/compositor-linux-x64-
|
|
52
|
-
"@remotion/compositor-
|
|
53
|
-
"@remotion/compositor-
|
|
47
|
+
"@remotion/compositor-linux-arm64-gnu": "4.0.175",
|
|
48
|
+
"@remotion/compositor-darwin-arm64": "4.0.175",
|
|
49
|
+
"@remotion/compositor-linux-x64-gnu": "4.0.175",
|
|
50
|
+
"@remotion/compositor-darwin-x64": "4.0.175",
|
|
51
|
+
"@remotion/compositor-linux-x64-musl": "4.0.175",
|
|
52
|
+
"@remotion/compositor-win32-x64-msvc": "4.0.175",
|
|
53
|
+
"@remotion/compositor-linux-arm64-musl": "4.0.175"
|
|
54
54
|
},
|
|
55
55
|
"keywords": [
|
|
56
56
|
"remotion",
|