@remotion/lambda 4.0.296 → 4.0.297

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.
@@ -6,7 +6,6 @@ const constants_1 = require("@remotion/lambda-client/constants");
6
6
  const error_handling_1 = require("@remotion/renderer/error-handling");
7
7
  const version_1 = require("remotion/version");
8
8
  const full_client_implementation_1 = require("../functions/full-client-implementation");
9
- const function_zip_path_1 = require("../shared/function-zip-path");
10
9
  const get_layers_1 = require("../shared/get-layers");
11
10
  const validate_custom_role_arn_1 = require("../shared/validate-custom-role-arn");
12
11
  const validate_retention_period_1 = require("../shared/validate-retention-period");
@@ -39,7 +38,12 @@ const internalDeployFunction = async (params) => {
39
38
  const created = await params.fullClientSpecifics.createFunction({
40
39
  createCloudWatchLogGroup: params.createCloudWatchLogGroup,
41
40
  region: params.region,
42
- zipFile: function_zip_path_1.FUNCTION_ZIP_ARM64,
41
+ // Very delicate!
42
+ // this will output to
43
+ // - dist/esm/index.mjs
44
+ // - dist/api/deploy-function.js
45
+ // It only works because both are two levels deep
46
+ zipFile: '../../remotionlambda-arm64.zip',
43
47
  functionName,
44
48
  accountId,
45
49
  memorySizeInMb: params.memorySizeInMb,
@@ -8604,7 +8604,7 @@ var require_package = __commonJS((exports, module) => {
8604
8604
  url: "https://github.com/remotion-dev/remotion/tree/main/packages/lambda"
8605
8605
  },
8606
8606
  name: "@remotion/lambda",
8607
- version: "4.0.296",
8607
+ version: "4.0.297",
8608
8608
  description: "Render Remotion videos on AWS Lambda",
8609
8609
  main: "dist/index.js",
8610
8610
  sideEffects: false,
@@ -9892,12 +9892,6 @@ var awsFullClientSpecifics = {
9892
9892
  createFunction
9893
9893
  };
9894
9894
 
9895
- // src/shared/function-zip-path.ts
9896
- import path4 from "node:path";
9897
- var b = "../";
9898
- var a = "remotionlambda-arm64.zip";
9899
- var FUNCTION_ZIP_ARM64 = path4.resolve(__require.resolve(`../` + b), "..", "..", a);
9900
-
9901
9895
  // src/shared/validate-custom-role-arn.ts
9902
9896
  var validateCustomRoleArn = (customRoleArn) => {
9903
9897
  if (typeof customRoleArn !== "undefined" && typeof customRoleArn !== "string") {
@@ -9977,7 +9971,7 @@ var internalDeployFunction = async (params) => {
9977
9971
  const created = await params.fullClientSpecifics.createFunction({
9978
9972
  createCloudWatchLogGroup: params.createCloudWatchLogGroup,
9979
9973
  region: params.region,
9980
- zipFile: FUNCTION_ZIP_ARM64,
9974
+ zipFile: "../../remotionlambda-arm64.zip",
9981
9975
  functionName,
9982
9976
  accountId,
9983
9977
  memorySizeInMb: params.memorySizeInMb,
@@ -10272,7 +10266,7 @@ import {
10272
10266
  getExpectedOutName,
10273
10267
  getOverallProgressFromStorage
10274
10268
  } from "@remotion/serverless";
10275
- import path5 from "node:path";
10269
+ import path4 from "node:path";
10276
10270
 
10277
10271
  // src/functions/helpers/read-with-progress.ts
10278
10272
  import { GetObjectCommand } from "@aws-sdk/client-s3";
@@ -10333,7 +10327,7 @@ var internalDownloadMedia = async (input) => {
10333
10327
  if (!overallProgress.renderMetadata) {
10334
10328
  throw new Error("Render did not finish yet");
10335
10329
  }
10336
- const outputPath = path5.resolve(process.cwd(), input.outPath);
10330
+ const outputPath = path4.resolve(process.cwd(), input.outPath);
10337
10331
  RenderInternals3.ensureOutputDirectory(outputPath);
10338
10332
  const { key, renderBucketName, customCredentials } = getExpectedOutName({
10339
10333
  renderMetadata: overallProgress.renderMetadata,
@@ -11327,7 +11321,7 @@ import { CliInternals as CliInternals14 } from "@remotion/cli";
11327
11321
  import { ConfigInternals } from "@remotion/cli/config";
11328
11322
  import { RenderInternals as RenderInternals5 } from "@remotion/renderer";
11329
11323
  import { BrowserSafeApis as BrowserSafeApis3 } from "@remotion/renderer/client";
11330
- import path7 from "path";
11324
+ import path6 from "path";
11331
11325
  import { NoReactInternals as NoReactInternals2 } from "remotion/no-react";
11332
11326
  import {
11333
11327
  getRenderProgress,
@@ -11373,14 +11367,14 @@ function validateMaxRetries(maxRetries) {
11373
11367
  import { BrowserSafeApis as BrowserSafeApis2 } from "@remotion/renderer/client";
11374
11368
  import fs5 from "node:fs";
11375
11369
  import os from "node:os";
11376
- import path6 from "node:path";
11370
+ import path5 from "node:path";
11377
11371
  var getWebhookCustomData = (logLevel) => {
11378
11372
  const flagName = BrowserSafeApis2.options.webhookCustomDataOption.cliFlag;
11379
11373
  const webhookFlag = parsedLambdaCli[flagName];
11380
11374
  if (!webhookFlag) {
11381
11375
  return null;
11382
11376
  }
11383
- const jsonFile = path6.resolve(process.cwd(), webhookFlag);
11377
+ const jsonFile = path5.resolve(process.cwd(), webhookFlag);
11384
11378
  try {
11385
11379
  if (fs5.existsSync(jsonFile)) {
11386
11380
  const rawJsonData = fs5.readFileSync(jsonFile, "utf-8");
@@ -11922,7 +11916,7 @@ var renderCommand = async ({
11922
11916
  url: newStatus.outputFile
11923
11917
  })), CliInternals14.chalk.gray(CliInternals14.formatBytes(newStatus.outputSizeInBytes)));
11924
11918
  if (downloadOrNothing) {
11925
- const relativeOutputPath = path7.relative(process.cwd(), downloadOrNothing.outputPath);
11919
+ const relativeOutputPath = path6.relative(process.cwd(), downloadOrNothing.outputPath);
11926
11920
  Log.info({ indent: false, logLevel }, CliInternals14.chalk.blue("↓".padEnd(CliInternals14.LABEL_WIDTH)), CliInternals14.chalk.blue(CliInternals14.makeHyperlink({
11927
11921
  url: `file://${downloadOrNothing.outputPath}`,
11928
11922
  text: relativeOutputPath,
@@ -12414,7 +12408,7 @@ import {
12414
12408
  import { RenderInternals as RenderInternals6 } from "@remotion/renderer";
12415
12409
  import { BrowserSafeApis as BrowserSafeApis5 } from "@remotion/renderer/client";
12416
12410
  import { validatePrivacy as validatePrivacy3 } from "@remotion/serverless";
12417
- import path8 from "path";
12411
+ import path7 from "path";
12418
12412
  import { NoReactInternals as NoReactInternals5 } from "remotion/no-react";
12419
12413
  var {
12420
12414
  offthreadVideoCacheSizeInBytesOption: offthreadVideoCacheSizeInBytesOption2,
@@ -12627,7 +12621,7 @@ var stillCommand = async ({
12627
12621
  providerSpecifics,
12628
12622
  forcePathStyle: parsedLambdaCli["force-path-style"]
12629
12623
  });
12630
- const relativePath = path8.relative(process.cwd(), outputPath);
12624
+ const relativePath = path7.relative(process.cwd(), outputPath);
12631
12625
  Log.info({ indent: false, logLevel }, chalk.blue("↓".padEnd(CliInternals21.LABEL_WIDTH)), chalk.blue(CliInternals21.makeHyperlink({
12632
12626
  url: "file://" + outputPath,
12633
12627
  text: relativePath,
@@ -1,11 +1,46 @@
1
1
  "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
5
35
  Object.defineProperty(exports, "__esModule", { value: true });
6
36
  exports.FUNCTION_ZIP_ARM64 = void 0;
7
- // Don't concatenate as we don't want Bun bundler to hardcode this
8
- const node_path_1 = __importDefault(require("node:path"));
9
- const b = '../';
37
+ const path_1 = __importStar(require("path"));
38
+ const url_1 = require("url");
39
+ const isESM = eval('typeof __filename') === 'undefined';
40
+ const currentdir = isESM
41
+ ? // @ts-expect-error
42
+ (0, path_1.dirname)((0, url_1.fileURLToPath)(import.meta.url))
43
+ : eval('__dirname');
10
44
  const a = 'remotionlambda-arm64.zip';
11
- exports.FUNCTION_ZIP_ARM64 = node_path_1.default.resolve(require.resolve(`../` + b), '..', '..', a);
45
+ exports.FUNCTION_ZIP_ARM64 = path_1.default.join(currentdir, '..', '..', a);
46
+ console.log(exports.FUNCTION_ZIP_ARM64);
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.296",
6
+ "version": "4.0.297",
7
7
  "description": "Render Remotion videos on AWS Lambda",
8
8
  "main": "dist/index.js",
9
9
  "sideEffects": false,
@@ -21,13 +21,13 @@
21
21
  "@aws-sdk/lib-storage": "3.787.0",
22
22
  "@smithy/abort-controller": "4.0.1",
23
23
  "zod": "3.22.3",
24
- "@remotion/bundler": "4.0.296",
25
- "@remotion/cli": "4.0.296",
26
- "@remotion/lambda-client": "4.0.296",
27
- "@remotion/serverless": "4.0.296",
28
- "@remotion/renderer": "4.0.296",
29
- "remotion": "4.0.296",
30
- "@remotion/streaming": "4.0.296"
24
+ "@remotion/bundler": "4.0.297",
25
+ "@remotion/lambda-client": "4.0.297",
26
+ "@remotion/cli": "4.0.297",
27
+ "@remotion/serverless": "4.0.297",
28
+ "@remotion/streaming": "4.0.297",
29
+ "remotion": "4.0.297",
30
+ "@remotion/renderer": "4.0.297"
31
31
  },
32
32
  "devDependencies": {
33
33
  "@types/express": "^5.0.0",
@@ -40,12 +40,12 @@
40
40
  "next": "15.2.4",
41
41
  "pureimage": "0.4.13",
42
42
  "zip-lib": "^0.7.2",
43
- "@remotion/bundler": "4.0.296",
44
- "@remotion/compositor-linux-arm64-gnu": "4.0.296",
45
- "@remotion/eslint-config-internal": "4.0.296"
43
+ "@remotion/bundler": "4.0.297",
44
+ "@remotion/compositor-linux-arm64-gnu": "4.0.297",
45
+ "@remotion/eslint-config-internal": "4.0.297"
46
46
  },
47
47
  "peerDependencies": {
48
- "@remotion/bundler": "4.0.296"
48
+ "@remotion/bundler": "4.0.297"
49
49
  },
50
50
  "publishConfig": {
51
51
  "access": "public"
Binary file