From 9abb8f1b4cd4fdd68d1e7e67fb44142cbd9317c2 Mon Sep 17 00:00:00 2001 From: minnakt <47064971+minnakt@users.noreply.github.com> Date: Thu, 12 Sep 2024 11:35:11 -0400 Subject: [PATCH] Revert "DEVPROD-7660: Add link to image page in task metadata" (#379) --- .../cypress/integration/image/navigation.ts | 11 ----- apps/spruce/src/gql/generated/types.ts | 1 - apps/spruce/src/gql/mocks/taskData.ts | 1 - apps/spruce/src/gql/queries/task.graphql | 1 - .../Metadata_ContainerizedTask.storyshot | 1 - .../__snapshots__/Metadata_Default.storyshot | 36 ++++----------- .../Metadata_OOMTracker.storyshot | 36 ++++----------- .../Metadata_WithAbortMessage.storyshot | 36 ++++----------- .../Metadata_WithDependencies.storyshot | 36 ++++----------- apps/spruce/src/pages/task/metadata/index.tsx | 44 +++++-------------- 10 files changed, 44 insertions(+), 159 deletions(-) diff --git a/apps/spruce/cypress/integration/image/navigation.ts b/apps/spruce/cypress/integration/image/navigation.ts index 0e4463abc..559851f04 100644 --- a/apps/spruce/cypress/integration/image/navigation.ts +++ b/apps/spruce/cypress/integration/image/navigation.ts @@ -22,15 +22,4 @@ describe("/image/imageId/random redirect route", () => { }); }); }); - - it("navigates to the image page from the task page", () => { - cy.visit( - "/task/evergreen_ubuntu1604_test_annotations_b_5e4ff3abe3c3317e352062e4_20_02_21_15_13_48", - ); - cy.dataCy("task-image-link") - .should("have.attr", "href") - .and("eq", "/image/ubuntu1604/build-information"); - cy.dataCy("task-image-link").click(); - cy.location("pathname").should("eq", "/image/ubuntu1604/build-information"); - }); }); diff --git a/apps/spruce/src/gql/generated/types.ts b/apps/spruce/src/gql/generated/types.ts index 581286f8b..f5ebe1481 100644 --- a/apps/spruce/src/gql/generated/types.ts +++ b/apps/spruce/src/gql/generated/types.ts @@ -8841,7 +8841,6 @@ export type TaskQuery = { generatedBy?: string | null; generatedByName?: string | null; hostId?: string | null; - imageId: string; ingestTime?: Date | null; isPerfPluginEnabled: boolean; latestExecution: number; diff --git a/apps/spruce/src/gql/mocks/taskData.ts b/apps/spruce/src/gql/mocks/taskData.ts index 5f4218957..0a420c204 100644 --- a/apps/spruce/src/gql/mocks/taskData.ts +++ b/apps/spruce/src/gql/mocks/taskData.ts @@ -58,7 +58,6 @@ export const taskQuery: TaskQueryType = { canUnschedule: false, dependsOn: [], displayName: "e2e_test", - imageId: "ubuntu1604", distroId: "ubuntu1604-small", estimatedStart: 1000, pod: null, diff --git a/apps/spruce/src/gql/queries/task.graphql b/apps/spruce/src/gql/queries/task.graphql index 455a64be9..094711042 100644 --- a/apps/spruce/src/gql/queries/task.graphql +++ b/apps/spruce/src/gql/queries/task.graphql @@ -84,7 +84,6 @@ query Task($taskId: String!, $execution: Int) { generatedBy generatedByName hostId - imageId ingestTime isPerfPluginEnabled latestExecution diff --git a/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_ContainerizedTask.storyshot b/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_ContainerizedTask.storyshot index 027b6fd15..fa2666bce 100644 --- a/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_ContainerizedTask.storyshot +++ b/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_ContainerizedTask.storyshot @@ -139,7 +139,6 @@ class="css-qqg5h5-Divider eb6szep0" /> -
diff --git a/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_Default.storyshot b/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_Default.storyshot index ca4d6b59a..32aad269f 100644 --- a/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_Default.storyshot +++ b/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_Default.storyshot @@ -139,26 +139,17 @@ class="css-qqg5h5-Divider eb6szep0" /> -
- ID: + AMI: - - - i-0e0e62799806e037d - - + ami-0c83bb0a9f48c15bf
- Image: + ID: - ubuntu1604 + i-0e0e62799806e037d
-- - AMI: - - - ami-0c83bb0a9f48c15bf -
diff --git a/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_OOMTracker.storyshot b/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_OOMTracker.storyshot index b2645aba8..0d3da46c4 100644 --- a/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_OOMTracker.storyshot +++ b/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_OOMTracker.storyshot @@ -135,26 +135,17 @@ class="css-qqg5h5-Divider eb6szep0" /> -
- ID: + AMI: - - - i-0e0e62799806e037d - - + ami-0c83bb0a9f48c15bf
- Image: + ID: - ubuntu1604 + i-0e0e62799806e037d
-- - AMI: - - - ami-0c83bb0a9f48c15bf -
diff --git a/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_WithAbortMessage.storyshot b/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_WithAbortMessage.storyshot index ca4d6b59a..32aad269f 100644 --- a/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_WithAbortMessage.storyshot +++ b/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_WithAbortMessage.storyshot @@ -139,26 +139,17 @@ class="css-qqg5h5-Divider eb6szep0" /> -
- ID: + AMI: - - - i-0e0e62799806e037d - - + ami-0c83bb0a9f48c15bf
- Image: + ID: - ubuntu1604 + i-0e0e62799806e037d
-- - AMI: - - - ami-0c83bb0a9f48c15bf -
diff --git a/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_WithDependencies.storyshot b/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_WithDependencies.storyshot index 114fd2035..dc0d59063 100644 --- a/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_WithDependencies.storyshot +++ b/apps/spruce/src/pages/task/metadata/__snapshots__/Metadata_WithDependencies.storyshot @@ -139,26 +139,17 @@ class="css-qqg5h5-Divider eb6szep0" /> -
- ID: + AMI: - - - i-0e0e62799806e037d - - + ami-0c83bb0a9f48c15bf
- Image: + ID: - ubuntu1604 + i-0e0e62799806e037d
-- - AMI: - - - ami-0c83bb0a9f48c15bf -
diff --git a/apps/spruce/src/pages/task/metadata/index.tsx b/apps/spruce/src/pages/task/metadata/index.tsx
index 90ecdf15a..d534b22fc 100644
--- a/apps/spruce/src/pages/task/metadata/index.tsx
+++ b/apps/spruce/src/pages/task/metadata/index.tsx
@@ -17,7 +17,6 @@ import {
getHoneycombTraceUrl,
getHoneycombSystemMetricsUrl,
} from "constants/externalResources";
-import { showImageVisibilityPage } from "constants/featureFlags";
import {
getDistroSettingsRoute,
getTaskQueueRoute,
@@ -27,7 +26,6 @@ import {
getVersionRoute,
getProjectPatchesRoute,
getPodRoute,
- getImageRoute,
} from "constants/routes";
import { zIndex } from "constants/tokens";
import { TaskQuery } from "gql/generated/types";
@@ -72,7 +70,6 @@ export const Metadata: React.FC