Skip to content

Scheduling infrastructure for absolutely everyone.

fix: use recordingId to check loading (#7524)

Udit Takkarc2668acd3375
diff --git a/apps/web/playwright/event-types.e2e.ts b/apps/web/playwright/event-types.e2e.ts
index 5acdd3febf3..4c652478fe3 100644
--- a/apps/web/playwright/event-types.e2e.ts
+++ b/apps/web/playwright/event-types.e2e.ts
@@ -139,6 +139,8 @@ test.describe("Event Types tests", () => {
const fillLocation = async (inputText: string) => {
await page.locator("#location-select").click();
await page.locator("text=In Person (Organizer Address)").click();
+ // eslint-disable-next-line playwright/no-wait-for-timeout
+ await page.waitForTimeout(250);
await page.locator('input[name="locationAddress"]').fill(inputText);
await page.locator("[data-testid=display-location]").check();
await page.locator("[data-testid=update-location]").click();
diff --git a/packages/features/ee/video/ViewRecordingsDialog.tsx b/packages/features/ee/video/ViewRecordingsDialog.tsx
index 641dd938d55..a39e0a8d1b6 100644
--- a/packages/features/ee/video/ViewRecordingsDialog.tsx
+++ b/packages/features/ee/video/ViewRecordingsDialog.tsx
@@ -94,12 +94,13 @@ const useRecordingDownload = () => {
// assume it is still fetching, do nothing.
},
isFetching,
+ recordingId,
};
};
const ViewRecordingsList = ({ roomName, hasPaidPlan }: { roomName: string; hasPaidPlan: boolean }) => {
const { t } = useLocale();
- const { setRecordingId, isFetching } = useRecordingDownload();
+ const { setRecordingId, isFetching, recordingId } = useRecordingDownload();
const { data: recordings } = trpc.viewer.getCalVideoRecordings.useQuery(
{ roomName },
@@ -134,7 +135,7 @@ const ViewRecordingsList = ({ roomName, hasPaidPlan }: { roomName: string; hasPa
<Button
StartIcon={FiDownload}
className="ml-4 lg:ml-0"
- loading={isFetching}
+ loading={isFetching && recordingId === recording.id}
onClick={() => handleDownloadClick(recording.id)}>
{t("download")}
</Button>
diff --git a/playwright.config.ts b/playwright.config.ts
index c3a5290a788..fb03d86ecc3 100644
--- a/playwright.config.ts
+++ b/playwright.config.ts
@@ -34,7 +34,7 @@ if (IS_EMBED_TEST) {
const config: PlaywrightTestConfig = {
forbidOnly: !!process.env.CI,
- retries: 0,
+ retries: 2,
workers: os.cpus().length,
timeout: 60_000,
maxFailures: headless ? 10 : undefined,