🎥 Make videos programmatically with React
`@remotion/lambda` Fix lambda logLevel in CLI and prevent mistake
Jonny Burger870545266940
diff --git a/packages/cli/package.json b/packages/cli/package.jsonindex 41125ad5de..9e86c70b5e 100644--- a/packages/cli/package.json+++ b/packages/cli/package.json@@ -64,6 +64,7 @@"@types/semver": "^7.3.4","@remotion/zod-types": "workspace:*","@remotion/tailwind": "workspace:*",+ "@remotion/lambda": "workspace:*","eslint": "8.42.0","eslint-plugin-10x": "1.5.2","eslint-plugin-react": "7.32.2",diff --git a/packages/cli/src/index.tsx b/packages/cli/src/index.tsxindex d4a30c1c76..9a85a8482e 100644--- a/packages/cli/src/index.tsx+++ b/packages/cli/src/index.tsx@@ -83,7 +83,7 @@ export const cli = async () => {} else if (isStudio) {await studioCommand(remotionRoot, args, logLevel);} else if (command === 'lambda') {- await lambdaCommand(remotionRoot, args);+ await lambdaCommand(remotionRoot, args, logLevel);} else if (command === 'cloudrun') {await cloudrunCommand(remotionRoot, args, logLevel);} else if (command === 'render') {diff --git a/packages/cli/src/lambda-command.ts b/packages/cli/src/lambda-command.tsindex 92182e4f76..ebb405969f 100644--- a/packages/cli/src/lambda-command.ts+++ b/packages/cli/src/lambda-command.ts@@ -1,15 +1,22 @@+import type {LogLevel} from '@remotion/renderer';import {Log} from './log';import {getPackageManager} from './preview-server/get-package-manager';import {getRemotionVersion} from './preview-server/update-available';-export const lambdaCommand = async (remotionRoot: string, args: string[]) => {+export const lambdaCommand = async (+ remotionRoot: string,+ args: string[],+ logLevel: LogLevel,+) => {try {const path = require.resolve('@remotion/lambda', {paths: [remotionRoot],});- const {LambdaInternals} = require(path);+ const {LambdaInternals} =+ // eslint-disable-next-line @typescript-eslint/consistent-type-imports+ require(path) as typeof import('@remotion/lambda');- await LambdaInternals.executeCommand(args, remotionRoot);+ await LambdaInternals.executeCommand(args, remotionRoot, logLevel);process.exit(0);} catch (err) {const manager = getPackageManager(remotionRoot, undefined);diff --git a/pnpm-lock.yaml b/pnpm-lock.yamlindex 6ec78ba4c7..4df0c41c33 100644--- a/pnpm-lock.yaml+++ b/pnpm-lock.yaml@@ -218,6 +218,9 @@ importers:'@jonny/eslint-config':specifier: 3.0.276version: 3.0.276([email protected])([email protected])+ '@remotion/lambda':+ specifier: workspace:*+ version: link:../lambda'@remotion/tailwind':specifier: workspace:*version: link:../tailwind