🎥 Make videos programmatically with React
remove stuff not needed
Jonny Burgeraf1379d85a29
diff --git a/packages/lambda/src/api/deploy-function.ts b/packages/lambda/src/api/deploy-function.tsindex bcce517d99..f7eda38b94 100644--- a/packages/lambda/src/api/deploy-function.ts+++ b/packages/lambda/src/api/deploy-function.ts@@ -109,9 +109,7 @@ export const internalDeployFunction = async (};};-export const errorHandled = NoReactAPIs.wrapWithErrorHandling(- internalDeployFunction,-);+const errorHandled = NoReactAPIs.wrapWithErrorHandling(internalDeployFunction);/*** @description Creates an AWS Lambda function in your account that will be able to render a video in the cloud.diff --git a/packages/lambda/src/functions/chunk-optimization/types.ts b/packages/lambda/src/functions/chunk-optimization/types.tsindex 8e796dd33c..a15e797d39 100644--- a/packages/lambda/src/functions/chunk-optimization/types.ts+++ b/packages/lambda/src/functions/chunk-optimization/types.ts@@ -6,7 +6,3 @@ export type ObjectChunkTimingData = {[key: number]: number;};};--export type ChunkTimingData = Omit<ObjectChunkTimingData, 'timings'> & {- timings: number[];-};diff --git a/packages/lambda/src/functions/helpers/clean-tmpdir.ts b/packages/lambda/src/functions/helpers/clean-tmpdir.tsindex e39e9ded74..45494ac73e 100644--- a/packages/lambda/src/functions/helpers/clean-tmpdir.ts+++ b/packages/lambda/src/functions/helpers/clean-tmpdir.ts@@ -1,9 +1,6 @@import fs from 'node:fs';import {join} from 'node:path';-export let deletedFiles: string[] = [];-export let deletedFilesSize = 0;-const deleteAllFilesInAFolderRecursively = (path: string) => {const files = fs.readdirSync(path);files.forEach((file) => {@@ -14,14 +11,11 @@ const deleteAllFilesInAFolderRecursively = (path: string) => {deleteAllFilesInAFolderRecursively(filePath);} else {fs.unlinkSync(filePath);- deletedFilesSize += stat.size;}} catch (err) {// Can fail if file was already deleted by cleanup. In that case// let's ignore it}-- deletedFiles.push(filePath);});if (path !== '/tmp') {fs.rmSync(path, {recursive: true, force: true});@@ -29,8 +23,6 @@ const deleteAllFilesInAFolderRecursively = (path: string) => {};export const deleteTmpDir = () => {- deletedFiles = [];- deletedFilesSize = 0;if (!process.env.VITEST) {deleteAllFilesInAFolderRecursively('/tmp');}diff --git a/packages/lambda/src/functions/helpers/get-encoding-progress-step-size.ts b/packages/lambda/src/functions/helpers/get-encoding-progress-step-size.tsdeleted file mode 100644index 7394eb9fa9..0000000000--- a/packages/lambda/src/functions/helpers/get-encoding-progress-step-size.ts+++ /dev/null@@ -1,3 +0,0 @@-export const getEncodingProgressStepSize = (totalFrames: number) => {- return Math.min(100, Math.max(5, totalFrames / 10));-};diff --git a/packages/lambda/src/functions/helpers/get-folder-size.ts b/packages/lambda/src/functions/helpers/get-folder-size.tsdeleted file mode 100644index ee366118b1..0000000000--- a/packages/lambda/src/functions/helpers/get-folder-size.ts+++ /dev/null@@ -1,5 +0,0 @@-import {getFolderFiles} from './get-files-in-folder';--export function getFolderSizeRecursively(folder: string) {- return getFolderFiles(folder).reduce((a, b) => a + b.size, 0);-}diff --git a/packages/lambda/src/functions/helpers/get-lambdas-invoked-stats.ts b/packages/lambda/src/functions/helpers/get-lambdas-invoked-stats.tsdeleted file mode 100644index 2e15fc105f..0000000000--- a/packages/lambda/src/functions/helpers/get-lambdas-invoked-stats.ts+++ /dev/null@@ -1,3 +0,0 @@-export type LambdaInvokeStats = {- lambdasInvoked: number;-};diff --git a/packages/lambda/src/functions/helpers/io.ts b/packages/lambda/src/functions/helpers/io.tsindex 82cd87c660..09efc03e7a 100644--- a/packages/lambda/src/functions/helpers/io.ts+++ b/packages/lambda/src/functions/helpers/io.ts@@ -107,7 +107,7 @@ type LambdaWriteFileInput = {customCredentials: CustomCredentials | null;};-export const tryLambdaWriteFile = async ({+const tryLambdaWriteFile = async ({bucketName,key,body,diff --git a/packages/lambda/src/functions/helpers/lifecycle.ts b/packages/lambda/src/functions/helpers/lifecycle.tsindex 13dab7e5a9..2a17d667c3 100644--- a/packages/lambda/src/functions/helpers/lifecycle.ts+++ b/packages/lambda/src/functions/helpers/lifecycle.ts@@ -12,7 +12,7 @@ const expiryDays = {export type DeleteAfter = keyof typeof expiryDays;-export const getEnabledLifeCycleRule = ({+const getEnabledLifeCycleRule = ({key,value,}: {diff --git a/packages/lambda/src/functions/helpers/streamify-response.ts b/packages/lambda/src/functions/helpers/streamify-response.tsindex 5e3b13187c..a8d4d183e6 100644--- a/packages/lambda/src/functions/helpers/streamify-response.ts+++ b/packages/lambda/src/functions/helpers/streamify-response.ts@@ -41,11 +41,6 @@ function patchArgs(argList: unknown[]): ResponseStream {return argList[1] as ResponseStream;}-export const HANDLER_STREAMING = Symbol.for(- 'aws.lambda.runtime.handler.streaming',-);-export const STREAM_RESPONSE = 'response';-export function streamifyResponse(handler: Function): Function {// Check if we are inside Lambdaif (diff --git a/packages/lambda/src/functions/renderer.ts b/packages/lambda/src/functions/renderer.tsindex 9cdc3cd67e..49082fb300 100644--- a/packages/lambda/src/functions/renderer.ts+++ b/packages/lambda/src/functions/renderer.ts@@ -345,7 +345,7 @@ const renderHandler = async ({return {};};-export const ENABLE_SLOW_LEAK_DETECTION = false;+const ENABLE_SLOW_LEAK_DETECTION = false;export const rendererHandler = async (params: LambdaPayload,diff --git a/packages/lambda/src/functions/streaming/streaming.ts b/packages/lambda/src/functions/streaming/streaming.tsindex 2c960a6393..5f90f50307 100644--- a/packages/lambda/src/functions/streaming/streaming.ts+++ b/packages/lambda/src/functions/streaming/streaming.ts@@ -95,9 +95,7 @@ export const messageTypeIdToMessageType = (return types.type;};-export const messageTypeToMessageId = (- messageType: MessageType,-): MessageTypeId => {+const messageTypeToMessageId = (messageType: MessageType): MessageTypeId => {const id = (Object.keys(messageTypes) as unknown as MessageTypeId[]).find((key) => messageTypes[key].type === messageType,) as MessageTypeId;diff --git a/packages/lambda/src/shared/content-disposition-header.ts b/packages/lambda/src/shared/content-disposition-header.tsindex 6d653d532e..fa570f379b 100644--- a/packages/lambda/src/shared/content-disposition-header.ts+++ b/packages/lambda/src/shared/content-disposition-header.ts@@ -31,7 +31,7 @@ const problematicCharacters = {'%3B': ';',};-export type HexInfo = {+type HexInfo = {containsHex: boolean;};diff --git a/packages/lambda/src/test/integration/simulate-lambda-render.ts b/packages/lambda/src/test/integration/simulate-lambda-render.tsindex 565e17d463..6a9ecfae16 100644--- a/packages/lambda/src/test/integration/simulate-lambda-render.ts+++ b/packages/lambda/src/test/integration/simulate-lambda-render.ts@@ -10,7 +10,7 @@ import {callLambda} from '../../shared/call-lambda';const functionName = 'remotion-dev-render';-export const waitUntilDone = async (bucketName: string, renderId: string) => {+const waitUntilDone = async (bucketName: string, renderId: string) => {// eslint-disable-next-line no-constant-conditionwhile (true) {const progress = await callLambda({