Skip to content

🎥 Make videos programmatically with React

wrapped hotfix

Jonny Burgerd68bdd2420c5
diff --git a/packages/lambda/remotionlambda.zip b/packages/lambda/remotionlambda.zip
index f49d1ebd04..386a8e03f0 100644
Binary files a/packages/lambda/remotionlambda.zip and b/packages/lambda/remotionlambda.zip differ
diff --git a/packages/lambda/src/functions/helpers/calculate-price-from-bucket.ts b/packages/lambda/src/functions/helpers/calculate-price-from-bucket.ts
index d0718bd4ac..e55d9a9357 100644
--- a/packages/lambda/src/functions/helpers/calculate-price-from-bucket.ts
+++ b/packages/lambda/src/functions/helpers/calculate-price-from-bucket.ts
@@ -53,15 +53,28 @@ export const estimatePriceFromBucket = ({
.map(() => elapsedTime)
.reduce((a, b) => a + b, 0);
+ console.log(
+ `chunk times`,
+ calculateChunkTimes({
+ contents,
+ renderId: renderMetadata.renderId,
+ type: 'combined-time-for-cost-calculation',
+ }),
+ `unfinished`,
+ timeElapsedOfUnfinished
+ );
+
const accruedSoFar = Number(
estimatePrice({
region: getCurrentRegionInFunction(),
- durationInMiliseconds:
+ durationInMiliseconds: Math.max(
+ 0,
calculateChunkTimes({
contents,
renderId: renderMetadata.renderId,
type: 'combined-time-for-cost-calculation',
- }) + timeElapsedOfUnfinished,
+ }) + timeElapsedOfUnfinished
+ ),
memorySizeInMb,
}).toPrecision(5)
);
diff --git a/packages/lambda/src/shared/constants.ts b/packages/lambda/src/shared/constants.ts
index bbb3f06fac..fe333ee8aa 100644
--- a/packages/lambda/src/shared/constants.ts
+++ b/packages/lambda/src/shared/constants.ts
@@ -266,6 +266,7 @@ export type RenderMetadata = {
};
export type LambdaVersions =
+ | '2021-12-13'
| '2021-12-11'
| '2021-12-10'
| '2021-12-04'
@@ -295,7 +296,7 @@ export type LambdaVersions =
| '2021-06-23'
| 'n/a';
-export const CURRENT_VERSION: LambdaVersions = '2021-12-10';
+export const CURRENT_VERSION: LambdaVersions = '2021-12-13';
export type PostRenderData = {
cost: {