@remotion/lambda 4.0.37 → 4.0.39

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.
@@ -0,0 +1,4 @@
1
+ import { Internals } from 'remotion';
2
+ export declare const validateFps: typeof Internals.validateFps;
3
+ export declare const validateDimension: typeof Internals.validateDimension;
4
+ export declare const validateDurationInFrames: typeof Internals.validateDurationInFrames;
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.validateDurationInFrames = exports.validateDimension = exports.validateFps = void 0;
4
+ /* eslint-disable prefer-destructuring */
5
+ const remotion_1 = require("remotion");
6
+ exports.validateFps = remotion_1.Internals.validateFps;
7
+ exports.validateDimension = remotion_1.Internals.validateDimension;
8
+ exports.validateDurationInFrames = remotion_1.Internals.validateDurationInFrames;
@@ -3,8 +3,5 @@ export declare const planFrameRanges: ({ framesPerLambda, frameRange, everyNthFr
3
3
  frameRange: [number, number];
4
4
  everyNthFrame: number;
5
5
  }) => {
6
- chunks: [
7
- number,
8
- number
9
- ][];
6
+ chunks: [number, number][];
10
7
  };
@@ -231,8 +231,8 @@ const rendererHandler = async (params, options) => {
231
231
  // is a very rare error to occur
232
232
  const isRetryableError = (0, is_flaky_error_1.isFlakyError)(err);
233
233
  const shouldNotRetry = err.name === 'CancelledError';
234
- const isFatal = !isRetryableError;
235
234
  const willRetry = isRetryableError && params.retriesLeft > 0 && !shouldNotRetry;
235
+ const isFatal = !willRetry;
236
236
  console.log(`Error occurred (will retry = ${String(willRetry)})`);
237
237
  console.log(err);
238
238
  await (0, write_lambda_error_1.writeLambdaError)({
@@ -4,4 +4,9 @@ export declare const makeStreaming: (onMessage: OnMessage) => {
4
4
  addData: (data: Buffer) => void;
5
5
  };
6
6
  export declare const makePayloadMessage: (nonce: number, data: Buffer, status: 0 | 1) => Buffer;
7
+ export type StreamingPayload = {
8
+ type: 'frames-rendered';
9
+ frames: number;
10
+ };
11
+ export type OnStream = (payload: StreamingPayload) => void;
7
12
  export {};
@@ -78,6 +78,7 @@ const makeStreaming = (onMessage) => {
78
78
  unprocessedBuffers.unshift(outputBuffer);
79
79
  outputBuffer = Buffer.concat(unprocessedBuffers);
80
80
  unprocessedBuffers = [];
81
+ console.log('the unprocessed input is now', new TextDecoder('utf-8').decode(outputBuffer));
81
82
  processInput();
82
83
  },
83
84
  };
@@ -1,3 +1,5 @@
1
+ /// <reference types="node" />
2
+ /// <reference types="node" />
1
3
  import https from 'https';
2
4
  import http from 'node:http';
3
5
  import type { EnhancedErrorInfo } from '../functions/helpers/write-lambda-error';
@@ -39,7 +39,15 @@ const isFlakyError = (err) => {
39
39
  if (message.includes('RequestTimeout: Your socket connection to the server')) {
40
40
  return true;
41
41
  }
42
- if (message.includes('waiting for the page to render the React component failed')) {
42
+ if (message.includes('waiting for the page to render the React component')) {
43
+ return true;
44
+ }
45
+ // In puppeteer-evaluate.ts
46
+ if (message.includes('Timed out evaluating page function')) {
47
+ return true;
48
+ }
49
+ // Internet flakiness
50
+ if (message.includes('getaddrinfo') || message.includes('ECONNRESET')) {
43
51
  return true;
44
52
  }
45
53
  return false;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@remotion/lambda",
3
- "version": "4.0.37",
3
+ "version": "4.0.39",
4
4
  "description": "Distributed renderer for Remotion based on AWS Lambda",
5
5
  "main": "dist/index.js",
6
6
  "sideEffects": false,
@@ -26,10 +26,10 @@
26
26
  "aws-policies": "^1.0.1",
27
27
  "mime-types": "2.1.34",
28
28
  "zod": "3.21.4",
29
- "@remotion/bundler": "4.0.37",
30
- "@remotion/renderer": "4.0.37",
31
- "@remotion/cli": "4.0.37",
32
- "remotion": "4.0.37"
29
+ "@remotion/bundler": "4.0.39",
30
+ "@remotion/renderer": "4.0.39",
31
+ "remotion": "4.0.39",
32
+ "@remotion/cli": "4.0.39"
33
33
  },
34
34
  "devDependencies": {
35
35
  "@jonny/eslint-config": "3.0.266",
@@ -43,11 +43,11 @@
43
43
  "ts-node": "^10.8.0",
44
44
  "vitest": "0.31.1",
45
45
  "zip-lib": "^0.7.2",
46
- "@remotion/bundler": "4.0.37",
47
- "@remotion/compositor-linux-arm64-gnu": "4.0.37"
46
+ "@remotion/compositor-linux-arm64-gnu": "4.0.39",
47
+ "@remotion/bundler": "4.0.39"
48
48
  },
49
49
  "peerDependencies": {
50
- "@remotion/bundler": "4.0.37"
50
+ "@remotion/bundler": "4.0.39"
51
51
  },
52
52
  "publishConfig": {
53
53
  "access": "public"
Binary file