Skip to content

🎥 Make videos programmatically with React

update

Jonny Burgerdf6f16b6a4cd
diff --git a/packages/example-videos/src/remote-videos.ts b/packages/example-videos/src/remote-videos.ts
index d77f80a2f8..acd46cf2f7 100644
--- a/packages/example-videos/src/remote-videos.ts
+++ b/packages/example-videos/src/remote-videos.ts
@@ -1,5 +1,4 @@
/* eslint-disable no-console */
-import {S3Client} from 'bun';
import dotenv from 'dotenv';
import fs from 'fs';
import path from 'path';
@@ -69,6 +68,9 @@ export const getPrivateExampleVideo = async (
region: 'eu-central-1',
useAccelerateEndpoint: true,
};
+
+ const {S3Client} = await import('bun');
+
const client = new S3Client(credentials);
const file = client.file(privateExampleVideos[videoName]);
diff --git a/packages/media-parser/src/test/dispersed-samples.test.ts b/packages/media-parser/src/test/dispersed-samples.test.ts
index 235f3ef1a5..d27f9853cd 100644
--- a/packages/media-parser/src/test/dispersed-samples.test.ts
+++ b/packages/media-parser/src/test/dispersed-samples.test.ts
@@ -14568,24 +14568,24 @@ test('calculate jump marks', () => {
const jumpMarks = calculateJumpMarks(flatSamples, 120989485);
expect(jumpMarks).toEqual([
{
- afterSampleWithOffset: 27655256,
- jumpToOffset: 118034714,
+ afterSampleWithOffset: 27_655_256,
+ jumpToOffset: 118_034_714,
},
{
- afterSampleWithOffset: 118290414,
- jumpToOffset: 27718418,
+ afterSampleWithOffset: 118_290_414,
+ jumpToOffset: 27_718_418,
},
{
- afterSampleWithOffset: 82288651,
- jumpToOffset: 118290729,
+ afterSampleWithOffset: 82_288_651,
+ jumpToOffset: 118_290_729,
},
{
- afterSampleWithOffset: 118545681,
- jumpToOffset: 82313219,
+ afterSampleWithOffset: 118_545_681,
+ jumpToOffset: 82_313_219,
},
{
- afterSampleWithOffset: 117978962,
- jumpToOffset: 118546040,
+ afterSampleWithOffset: 117_978_962,
+ jumpToOffset: 118_546_040,
},
]);
});
@@ -14602,7 +14602,7 @@ test('dispersed samples', async () => {
const minProgress = Math.min(...progressValues);
const maxProgress = Math.max(...progressValues);
const spread = maxProgress - minProgress;
- if (spread > 10.5) {
+ if (spread > 8.5) {
throw new Error('Progress spread is too high');
}
};