@remotion/lambda 4.0.225 → 4.0.227
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/api/create-function.js +1 -1
- package/dist/api/get-functions.js +1 -1
- package/dist/cli/log.d.ts +3 -3
- package/dist/functions/helpers/calculate-price-from-bucket.d.ts +4 -3
- package/dist/functions/helpers/calculate-price-from-bucket.js +2 -2
- package/dist/functions/helpers/can-concat-seamlessly.js +0 -1
- package/dist/functions/helpers/clean-tmpdir.js +1 -1
- package/dist/functions/helpers/get-progress.js +1 -1
- package/dist/shared/call-lambda.js +2 -2
- package/dist/shared/is-likely-to-have-aws-profile.js +1 -1
- package/dist/shared/read-dir.js +0 -1
- package/dist/shared/stackback.js +2 -2
- package/dist/shared/why-is-node-running.js +1 -1
- package/eslint.config.mjs +36 -0
- package/package.json +16 -14
- package/remotionlambda-arm64.zip +0 -0
|
@@ -129,7 +129,7 @@ const createFunction = async ({ createCloudWatchLogGroup, region, zipFile, funct
|
|
|
129
129
|
RuntimeVersionArn,
|
|
130
130
|
}));
|
|
131
131
|
}
|
|
132
|
-
catch (
|
|
132
|
+
catch (_b) {
|
|
133
133
|
console.warn('⚠️ Could not lock the runtime version. We recommend to update your policies to prevent your functions from breaking in the future in case the AWS runtime changes. See https://remotion.dev/docs/lambda/feb-2023-incident for an example on how to update your policy.');
|
|
134
134
|
}
|
|
135
135
|
renderer_1.RenderInternals.Log.verbose({ indent: false, logLevel }, `Function runtime is locked to ${RuntimeVersionArn}`);
|
package/dist/cli/log.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
export declare const Log: {
|
|
2
|
-
verbose: (options: import("@remotion/renderer
|
|
2
|
+
verbose: (options: import("@remotion/renderer").LogOptions & {
|
|
3
3
|
tag?: string;
|
|
4
4
|
}, ...args: Parameters<typeof console.log>) => void;
|
|
5
5
|
info: (options: import("@remotion/renderer").LogOptions, ...args: Parameters<typeof console.log>) => void;
|
|
6
|
-
warn: (options: import("@remotion/renderer
|
|
7
|
-
error: (options: import("@remotion/renderer
|
|
6
|
+
warn: (options: import("@remotion/renderer").LogOptions, ...args: Parameters<typeof console.log>) => void;
|
|
7
|
+
error: (options: import("@remotion/renderer").LogOptions & {
|
|
8
8
|
tag?: string;
|
|
9
9
|
}, ...args: Parameters<typeof console.log>) => void;
|
|
10
10
|
};
|
|
@@ -1,13 +1,14 @@
|
|
|
1
|
-
import type { CloudProvider
|
|
1
|
+
import type { CloudProvider } from '@remotion/serverless';
|
|
2
2
|
import type { RenderMetadata } from '@remotion/serverless/client';
|
|
3
|
+
import type { AwsRegion } from '../../regions';
|
|
3
4
|
import type { ParsedTiming } from '../../shared/parse-lambda-timings-key';
|
|
4
|
-
export declare const estimatePriceFromBucket: <Provider extends CloudProvider>({ renderMetadata, memorySizeInMb, diskSizeInMb, lambdasInvoked, timings,
|
|
5
|
+
export declare const estimatePriceFromBucket: <Provider extends CloudProvider>({ renderMetadata, memorySizeInMb, diskSizeInMb, lambdasInvoked, timings, region, }: {
|
|
5
6
|
renderMetadata: RenderMetadata<Provider> | null;
|
|
6
7
|
memorySizeInMb: number;
|
|
7
8
|
diskSizeInMb: number;
|
|
8
9
|
lambdasInvoked: number;
|
|
9
10
|
timings: ParsedTiming[];
|
|
10
|
-
|
|
11
|
+
region: AwsRegion;
|
|
11
12
|
}) => {
|
|
12
13
|
accruedSoFar: number;
|
|
13
14
|
estimatedBillingDurationInMilliseconds: number;
|
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.estimatePriceFromBucket = void 0;
|
|
4
4
|
const estimate_price_1 = require("../../api/estimate-price");
|
|
5
5
|
const calculate_chunk_times_1 = require("./calculate-chunk-times");
|
|
6
|
-
const estimatePriceFromBucket = ({ renderMetadata, memorySizeInMb, diskSizeInMb, lambdasInvoked, timings,
|
|
6
|
+
const estimatePriceFromBucket = ({ renderMetadata, memorySizeInMb, diskSizeInMb, lambdasInvoked, timings, region, }) => {
|
|
7
7
|
var _a, _b;
|
|
8
8
|
if (!renderMetadata) {
|
|
9
9
|
return null;
|
|
@@ -19,7 +19,7 @@ const estimatePriceFromBucket = ({ renderMetadata, memorySizeInMb, diskSizeInMb,
|
|
|
19
19
|
timings,
|
|
20
20
|
}) + timeElapsedOfUnfinished;
|
|
21
21
|
const accruedSoFar = Number((0, estimate_price_1.estimatePrice)({
|
|
22
|
-
region
|
|
22
|
+
region,
|
|
23
23
|
durationInMilliseconds: estimatedBillingDurationInMilliseconds,
|
|
24
24
|
memorySizeInMb,
|
|
25
25
|
diskSizeInMb,
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.canConcatVideoSeamlessly = exports.canConcatAudioSeamlessly = void 0;
|
|
4
4
|
// Cannot do WAV yet, because currently assumes AAC in+outpoint
|
|
5
|
-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
6
5
|
const canConcatAudioSeamlessly = (audioCodec, chunkDurationInFrames) => {
|
|
7
6
|
// Rendering a chunk that is too small generates too much overhead
|
|
8
7
|
// and is currently buggy
|
|
@@ -153,7 +153,7 @@ const getProgress = async ({ bucketName, renderId, expectedBucketOwner, region,
|
|
|
153
153
|
// overestimate the price, but will only have a miniscule effect (~0.2%)
|
|
154
154
|
diskSizeInMb: constants_1.MAX_EPHEMERAL_STORAGE_IN_MB,
|
|
155
155
|
timings: (_j = overallProgress.timings) !== null && _j !== void 0 ? _j : [],
|
|
156
|
-
|
|
156
|
+
region: region,
|
|
157
157
|
});
|
|
158
158
|
const chunkMultiplier = [hasAudio, hasVideo].filter(client_1.truthy).length;
|
|
159
159
|
if (renderMetadata.type === 'still') {
|
|
@@ -11,7 +11,7 @@ const parseJsonOrThrowSource = (data, type) => {
|
|
|
11
11
|
try {
|
|
12
12
|
return JSON.parse(asString);
|
|
13
13
|
}
|
|
14
|
-
catch (
|
|
14
|
+
catch (_a) {
|
|
15
15
|
throw new Error(`Invalid JSON (${type}): ${asString}`);
|
|
16
16
|
}
|
|
17
17
|
};
|
|
@@ -66,7 +66,7 @@ const callLambdaWithoutRetry = async ({ functionName, type, payload, region, tim
|
|
|
66
66
|
try {
|
|
67
67
|
return JSON.parse(decoded);
|
|
68
68
|
}
|
|
69
|
-
catch (
|
|
69
|
+
catch (_a) {
|
|
70
70
|
throw new Error(`Invalid JSON (${type}): ${JSON.stringify(decoded)}`);
|
|
71
71
|
}
|
|
72
72
|
};
|
package/dist/shared/read-dir.js
CHANGED
|
@@ -47,7 +47,6 @@ function readDirectory({ dir, etags, originalDir, onProgress, }) {
|
|
|
47
47
|
};
|
|
48
48
|
continue;
|
|
49
49
|
}
|
|
50
|
-
// eslint-disable-next-line no-lonely-if
|
|
51
50
|
if (fs.lstatSync(filePath).isSymbolicLink()) {
|
|
52
51
|
const realPath = fs.realpathSync(filePath);
|
|
53
52
|
etags[path.relative(originalDir, filePath)] = (0, get_etag_1.getEtagOfFile)(realPath, onProgress);
|
package/dist/shared/stackback.js
CHANGED
|
@@ -10,7 +10,7 @@ function FormatStackTrace(error, frames) {
|
|
|
10
10
|
try {
|
|
11
11
|
lines.push('<error: ' + e + '>');
|
|
12
12
|
}
|
|
13
|
-
catch (
|
|
13
|
+
catch (_a) {
|
|
14
14
|
lines.push('<error>');
|
|
15
15
|
}
|
|
16
16
|
}
|
|
@@ -24,7 +24,7 @@ function FormatStackTrace(error, frames) {
|
|
|
24
24
|
try {
|
|
25
25
|
line = '<error: ' + e + '>';
|
|
26
26
|
}
|
|
27
|
-
catch (
|
|
27
|
+
catch (_b) {
|
|
28
28
|
// Any code that reaches this point is seriously nasty!
|
|
29
29
|
line = '<error>';
|
|
30
30
|
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import {remotionFlatConfig} from '@remotion/eslint-config-internal';
|
|
2
|
+
|
|
3
|
+
const config = remotionFlatConfig({react: false});
|
|
4
|
+
|
|
5
|
+
export default [
|
|
6
|
+
{
|
|
7
|
+
...config,
|
|
8
|
+
ignores: ['src/cli/**'],
|
|
9
|
+
rules: {
|
|
10
|
+
...config.rules,
|
|
11
|
+
'no-console': 'off',
|
|
12
|
+
'arrow-body-style': 'off',
|
|
13
|
+
'no-restricted-imports': [
|
|
14
|
+
'error',
|
|
15
|
+
{
|
|
16
|
+
patterns: ['@remotion/cli', '@remotion/*/src/*', 'remotion/src/*'],
|
|
17
|
+
paths: ['remotion', 'react', 'react-dom'],
|
|
18
|
+
},
|
|
19
|
+
],
|
|
20
|
+
},
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
...config,
|
|
24
|
+
files: ['src/cli/**.ts'],
|
|
25
|
+
rules: {
|
|
26
|
+
'no-console': 'error',
|
|
27
|
+
'no-restricted-imports': [
|
|
28
|
+
'error',
|
|
29
|
+
{
|
|
30
|
+
patterns: ['@remotion/*/src/*', 'remotion/src/*'],
|
|
31
|
+
paths: ['remotion', 'react', 'react-dom'],
|
|
32
|
+
},
|
|
33
|
+
],
|
|
34
|
+
},
|
|
35
|
+
},
|
|
36
|
+
];
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"url": "https://github.com/remotion-dev/remotion/tree/main/packages/lambda"
|
|
4
4
|
},
|
|
5
5
|
"name": "@remotion/lambda",
|
|
6
|
-
"version": "4.0.
|
|
6
|
+
"version": "4.0.227",
|
|
7
7
|
"description": "Render Remotion videos on AWS Lambda",
|
|
8
8
|
"main": "dist/index.js",
|
|
9
9
|
"sideEffects": false,
|
|
@@ -22,13 +22,13 @@
|
|
|
22
22
|
"@aws-sdk/s3-request-presigner": "3.645.0",
|
|
23
23
|
"mime-types": "2.1.34",
|
|
24
24
|
"zod": "3.22.3",
|
|
25
|
-
"@remotion/bundler": "4.0.
|
|
26
|
-
"@remotion/renderer": "4.0.
|
|
27
|
-
"@remotion/
|
|
28
|
-
"remotion": "4.0.
|
|
29
|
-
"@remotion/
|
|
30
|
-
"@remotion/
|
|
31
|
-
"
|
|
25
|
+
"@remotion/bundler": "4.0.227",
|
|
26
|
+
"@remotion/renderer": "4.0.227",
|
|
27
|
+
"@remotion/cli": "4.0.227",
|
|
28
|
+
"@remotion/studio-server": "4.0.227",
|
|
29
|
+
"@remotion/serverless": "4.0.227",
|
|
30
|
+
"@remotion/streaming": "4.0.227",
|
|
31
|
+
"remotion": "4.0.227"
|
|
32
32
|
},
|
|
33
33
|
"devDependencies": {
|
|
34
34
|
"@types/mime-types": "2.1.1",
|
|
@@ -37,11 +37,13 @@
|
|
|
37
37
|
"pureimage": "0.4.13",
|
|
38
38
|
"vitest": "0.31.1",
|
|
39
39
|
"zip-lib": "^0.7.2",
|
|
40
|
-
"
|
|
41
|
-
"@remotion/
|
|
40
|
+
"eslint": "9.14.0",
|
|
41
|
+
"@remotion/eslint-config-internal": "4.0.227",
|
|
42
|
+
"@remotion/compositor-linux-arm64-gnu": "4.0.227",
|
|
43
|
+
"@remotion/bundler": "4.0.227"
|
|
42
44
|
},
|
|
43
45
|
"peerDependencies": {
|
|
44
|
-
"@remotion/bundler": "4.0.
|
|
46
|
+
"@remotion/bundler": "4.0.227"
|
|
45
47
|
},
|
|
46
48
|
"publishConfig": {
|
|
47
49
|
"access": "public"
|
|
@@ -74,9 +76,9 @@
|
|
|
74
76
|
"homepage": "https://www.remotion.dev/docs/lambda",
|
|
75
77
|
"scripts": {
|
|
76
78
|
"formatting": "prettier src --check",
|
|
77
|
-
"
|
|
78
|
-
"
|
|
79
|
+
"lint": "eslint src",
|
|
80
|
+
"testlambda": "vitest src/test/integration --run",
|
|
79
81
|
"test": "vitest src/test/unit --run",
|
|
80
|
-
"make": "bun build.ts"
|
|
82
|
+
"make": "tsc -d && bun build.ts"
|
|
81
83
|
}
|
|
82
84
|
}
|
package/remotionlambda-arm64.zip
CHANGED
|
Binary file
|