Skip to content

Commit 8e39bd4

Browse files
committed
Link the replayed run in the run details pane
1 parent 3d9850f commit 8e39bd4

File tree

2 files changed

+17
-0
lines changed
  • apps/webapp/app

2 files changed

+17
-0
lines changed

apps/webapp/app/presenters/v3/SpanPresenter.server.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -218,6 +218,7 @@ export class SpanPresenter extends BasePresenter {
218218
friendlyId: true,
219219
},
220220
},
221+
replayedFromTaskRunFriendlyId: true,
221222
},
222223
where: span.originalRun
223224
? {
@@ -331,6 +332,7 @@ export class SpanPresenter extends BasePresenter {
331332
runtime: run.lockedToVersion?.runtime,
332333
runtimeVersion: run.lockedToVersion?.runtimeVersion,
333334
isTest: run.isTest,
335+
replayedFromTaskRunFriendlyId: run.replayedFromTaskRunFriendlyId,
334336
environmentId: run.runtimeEnvironment.id,
335337
idempotencyKey: run.idempotencyKey,
336338
idempotencyKeyExpiresAt: run.idempotencyKeyExpiresAt,

apps/webapp/app/routes/resources.orgs.$organizationSlug.projects.$projectParam.env.$envParam.runs.$runParam.spans.$spanParam/route.tsx

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ import {
6363
v3DeploymentVersionPath,
6464
v3RunDownloadLogsPath,
6565
v3RunPath,
66+
v3RunRedirectPath,
6667
v3RunSpanPath,
6768
v3RunsPath,
6869
v3SchedulePath,
@@ -592,6 +593,20 @@ function RunBody({
592593
{run.isTest ? <CheckIcon className="size-4 text-text-dimmed" /> : "–"}
593594
</Property.Value>
594595
</Property.Item>
596+
{run.replayedFromTaskRunFriendlyId && (
597+
<Property.Item>
598+
<Property.Label>Replayed from</Property.Label>
599+
<Property.Value>
600+
<TextLink
601+
to={v3RunRedirectPath(organization, project, {
602+
friendlyId: run.replayedFromTaskRunFriendlyId,
603+
})}
604+
>
605+
{run.replayedFromTaskRunFriendlyId}
606+
</TextLink>
607+
</Property.Value>
608+
</Property.Item>
609+
)}
595610
{environment && (
596611
<Property.Item>
597612
<Property.Label>Environment</Property.Label>

0 commit comments

Comments
 (0)