Skip to content

Commit 03a9ac4

Browse files
authored
Merge branch 'main' into samejr/modal-close-button-audit
2 parents 2895e4f + f6f3b75 commit 03a9ac4

17 files changed

Lines changed: 738 additions & 947 deletions

File tree

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
area: webapp
3+
type: improvement
4+
---
5+
6+
Out-of-date upgrade prompts no longer appear in the dashboard: the "V4" badges and the notices saying preview branches and the queues table need V4 have been removed. The side menu still warns you when a project is on v3, with updated wording and a link to the v4 upgrade guide.
-185 KB
Binary file not shown.

apps/webapp/app/components/BlankStatePanels.tsx

Lines changed: 2 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ import {
77
PlusIcon,
88
QuestionMarkCircleIcon,
99
RectangleGroupIcon,
10-
RectangleStackIcon,
1110
SparklesIcon,
1211
Squares2X2Icon,
1312
} from "@heroicons/react/20/solid";
@@ -63,7 +62,6 @@ import {
6362
TriggerDevStepV3,
6463
} from "./SetupCommands";
6564
import { StepContentContainer } from "./StepContentContainer";
66-
import { V4Badge } from "./V4Badge";
6765

6866
/**
6967
* What the agent is asked when it's opened from a deployment setup panel. The panel is the docs
@@ -475,36 +473,6 @@ export function AlertsNoneDeployed() {
475473
);
476474
}
477475

478-
export function QueuesHasNoTasks() {
479-
const organization = useOrganization();
480-
const project = useProject();
481-
const environment = useEnvironment();
482-
483-
return (
484-
<InfoPanel
485-
title="You don't have any queues"
486-
icon={RectangleStackIcon}
487-
iconClassName="text-queues"
488-
panelClassName="max-w-md"
489-
accessory={
490-
<LinkButton
491-
to={v3EnvironmentPath(organization, project, environment)}
492-
variant="primary/small"
493-
>
494-
Create a task
495-
</LinkButton>
496-
}
497-
>
498-
<Paragraph spacing variant="small">
499-
Queues will appear here when you have created a task in this environment. Follow the
500-
instructions on the{" "}
501-
<TextLink to={v3EnvironmentPath(organization, project, environment)}>Tasks page</TextLink>{" "}
502-
to create a task, then return here to see its queue.
503-
</Paragraph>
504-
</InfoPanel>
505-
);
506-
}
507-
508476
export function NoWaitpointTokens() {
509477
return (
510478
<InfoPanel
@@ -567,14 +535,10 @@ export function BranchesNoBranchableEnvironment({ showSelfServe }: { showSelfSer
567535
)
568536
}
569537
>
570-
<Paragraph spacing variant="small">
538+
<Paragraph variant="small">
571539
Preview branches in Trigger.dev create isolated environments for testing new features before
572540
production.
573541
</Paragraph>
574-
<Paragraph variant="small">
575-
You must be on <V4Badge inline /> to access preview branches. Read our{" "}
576-
<TextLink to={docsPath("upgrade-to-v4")}>upgrade to v4 guide</TextLink> to learn more.
577-
</Paragraph>
578542
</InfoPanel>
579543
);
580544
}
@@ -648,14 +612,10 @@ export function BranchesNoBranches({
648612
/>
649613
}
650614
>
651-
<Paragraph spacing variant="small">
615+
<Paragraph variant="small">
652616
Branches are a way to test new features in isolation before merging them into the main
653617
environment.
654618
</Paragraph>
655-
<Paragraph spacing variant="small">
656-
Branches are only available when using <V4Badge inline /> or above. Read our{" "}
657-
<TextLink to={docsPath("upgrade-to-v4")}>v4 upgrade guide</TextLink> to learn more.
658-
</Paragraph>
659619
</InfoPanel>
660620
);
661621
}

apps/webapp/app/components/V4Badge.tsx

Lines changed: 0 additions & 26 deletions
This file was deleted.

apps/webapp/app/components/navigation/EnvironmentSelector.tsx

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import { useFeatures } from "~/hooks/useFeatures";
1111
import { useOrganization, type MatchedOrganization } from "~/hooks/useOrganizations";
1212
import { useProject } from "~/hooks/useProject";
1313
import { cn } from "~/utils/cn";
14-
import { branchesPath, branchesDevPath, docsPath, v3BillingPath } from "~/utils/pathBuilder";
14+
import { branchesPath, branchesDevPath, v3BillingPath } from "~/utils/pathBuilder";
1515
import {
1616
EnvironmentCombo,
1717
EnvironmentIcon,
@@ -29,9 +29,7 @@ import {
2929
PopoverSectionHeader,
3030
PopoverTrigger,
3131
} from "../primitives/Popover";
32-
import { TextLink } from "../primitives/TextLink";
3332
import { SimpleTooltip } from "../primitives/Tooltip";
34-
import { V4Badge } from "../V4Badge";
3533
import { type SideMenuEnvironment, type SideMenuProject } from "./SideMenu";
3634
import { Badge } from "../primitives/Badge";
3735

@@ -411,14 +409,10 @@ export function BranchesPopoverContent({
411409
<BranchEnvironmentIconSmall className={cn("size-4", envTextClassName)} />
412410
<Header2>Create your first branch</Header2>
413411
</div>
414-
<Paragraph spacing variant="small">
412+
<Paragraph variant="small">
415413
Branches are a way to test new features in isolation before merging them into the main
416414
environment.
417415
</Paragraph>
418-
<Paragraph variant="small">
419-
Branches are only available when using <V4Badge inline /> or above. Read our{" "}
420-
<TextLink to={docsPath("upgrade-to-v4")}>v4 upgrade guide</TextLink> to learn more.
421-
</Paragraph>
422416
</div>
423417
) : (
424418
<div className="flex max-w-sm flex-col gap-1 p-2">

apps/webapp/app/components/navigation/SideMenu.tsx

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,7 @@ import {
9696
adminPath,
9797
branchesPath,
9898
concurrencyPath,
99+
docsPath,
99100
limitsPath,
100101
logoutPath,
101102
newOrganizationPath,
@@ -1111,7 +1112,7 @@ export function SideMenu({
11111112
isDragging={isDragging}
11121113
className="min-w-0 flex-1"
11131114
/>
1114-
{environment.type === "DEVELOPMENT" && project.engine === "V2" && (
1115+
{environment.type === "DEVELOPMENT" && (
11151116
<CollapsibleElement isDragging={isDragging} className="shrink-0">
11161117
<Dialog>
11171118
<TooltipProvider disableHoverableContent={true}>
@@ -1604,7 +1605,7 @@ function V3DeprecationPanel({
16041605
<ExclamationTriangleIcon className="size-5 text-amber-400" />
16051606
</PopoverTrigger>
16061607
}
1607-
content="V3 deprecation warning"
1608+
content="v3 is now deprecated"
16081609
side="right"
16091610
sideOffset={8}
16101611
disableHoverableContent
@@ -1625,23 +1626,23 @@ function V3DeprecationContent() {
16251626
<div className="flex items-center gap-1 border-b border-amber-500/30 pb-1">
16261627
<ExclamationTriangleIcon className="size-4 text-amber-400" />
16271628
<Paragraph variant="small/bright" className="text-amber-300">
1628-
V3 deprecation warning
1629+
v3 is now deprecated
16291630
</Paragraph>
16301631
</div>
16311632
<Paragraph variant="extra-small/bright" className="text-amber-300">
1632-
This is a v3 project. V3 deploys will stop working on 1 April 2026. Full shutdown is 1 July
1633-
2026 where all v3 runs will stop executing. Migrate to v4 to avoid downtime.
1633+
This is a v3 project which is now deprecated so no runs are executing. Upgrade to v4 to
1634+
resume executing runs in this project.
16341635
</Paragraph>
16351636
<LinkButton
16361637
variant="secondary/small"
1637-
to="https://trigger.dev/docs/migrating-from-v3"
1638+
to={docsPath("/upgrade-to-v4")}
16381639
target="_blank"
16391640
fullWidth
16401641
TrailingIcon={ArrowTopRightOnSquareIcon}
16411642
trailingIconClassName="text-amber-300"
16421643
className="border-amber-500/30 bg-amber-500/15 hover:border-amber-500/50! hover:bg-amber-500/25!"
16431644
>
1644-
<span className="text-amber-300">View migration guide</span>
1645+
<span className="text-amber-300">Upgrade to v4</span>
16451646
</LinkButton>
16461647
</div>
16471648
);

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

Lines changed: 6 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import { type PrismaClientOrTransaction } from "~/db.server";
55
import { type AuthenticatedEnvironment } from "~/services/apiAuth.server";
66
import { clickhouseFactory } from "~/services/clickhouse/clickhouseFactoryInstance.server";
77
import { logger } from "~/services/logger.server";
8-
import { determineEngineVersion } from "~/v3/engineVersion.server";
98
import { engine } from "~/v3/runEngine.server";
109
import { BasePresenter } from "./basePresenter.server";
1110
import { toQueueItem } from "./QueueRetrievePresenter.server";
@@ -51,25 +50,12 @@ type QueueListPagination =
5150
| { mode: "filtered"; currentPage: number; hasMore: boolean }
5251
| { mode: "unfiltered"; currentPage: number; totalPages: number; count: number };
5352

54-
// The `?: undefined` markers keep every key reachable across the union, so consumers
55-
// can destructure before narrowing on `success`.
56-
export type QueueListResult =
57-
| {
58-
success: false;
59-
code: string;
60-
totalQueues: number;
61-
hasFilters: boolean;
62-
queues?: undefined;
63-
pagination?: undefined;
64-
}
65-
| {
66-
success: true;
67-
queues: QueueListItem[];
68-
pagination: QueueListPagination;
69-
totalQueues?: number;
70-
hasFilters: boolean;
71-
code?: undefined;
72-
};
53+
export type QueueListResult = {
54+
queues: QueueListItem[];
55+
pagination: QueueListPagination;
56+
totalQueues?: number;
57+
hasFilters: boolean;
58+
};
7359

7460
function formatClickhouseDateTime(date: Date): string {
7561
return date.toISOString().slice(0, 19).replace("T", " ");
@@ -126,37 +112,6 @@ export class QueueListPresenter extends BasePresenter {
126112
}): Promise<QueueListResult> {
127113
const hasFilters = Boolean(query?.trim()) || type !== undefined;
128114

129-
const engineVersion = await determineEngineVersion({ environment });
130-
if (engineVersion === "V1") {
131-
const totalQueues = await this._replica.taskQueue.count({
132-
where: buildQueueListWhere(environment.id, query, type),
133-
});
134-
135-
if (totalQueues === 0) {
136-
const oldQueue = await this._replica.taskQueue.findFirst({
137-
where: {
138-
runtimeEnvironmentId: environment.id,
139-
version: "V1",
140-
},
141-
});
142-
if (oldQueue) {
143-
return {
144-
success: false as const,
145-
code: "engine-version",
146-
totalQueues: 1,
147-
hasFilters,
148-
};
149-
}
150-
}
151-
152-
return {
153-
success: false as const,
154-
code: "engine-version",
155-
totalQueues,
156-
hasFilters,
157-
};
158-
}
159-
160115
if (sort !== "name") {
161116
// Ranking is additive: any failure or unsupported input falls back to name order.
162117
try {
@@ -173,7 +128,6 @@ export class QueueListPresenter extends BasePresenter {
173128
const { queues, hasMore } = await this.getFilteredQueues(environment, query, page, type);
174129

175130
return {
176-
success: true as const,
177131
queues,
178132
pagination: {
179133
mode: "filtered" as const,
@@ -189,7 +143,6 @@ export class QueueListPresenter extends BasePresenter {
189143
});
190144

191145
return {
192-
success: true as const,
193146
queues: await this.getUnfilteredQueues(environment, page, type),
194147
pagination: {
195148
mode: "unfiltered" as const,
@@ -300,7 +253,6 @@ export class QueueListPresenter extends BasePresenter {
300253
}
301254

302255
return {
303-
success: true as const,
304256
queues: await this.enrichQueues(environment, [...rankedPageQueues, ...tailQueues]),
305257
pagination: {
306258
mode: "unfiltered" as const,

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

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ import {
77
type TaskQueueType,
88
} from "@trigger.dev/database";
99
import { type AuthenticatedEnvironment } from "~/services/apiAuth.server";
10-
import { determineEngineVersion } from "~/v3/engineVersion.server";
1110
import { engine } from "~/v3/runEngine.server";
1211
import { BasePresenter } from "./basePresenter.server";
1312

@@ -80,16 +79,6 @@ export class QueueRetrievePresenter extends BasePresenter {
8079
environment: AuthenticatedEnvironment;
8180
queueInput: RetrieveQueueParam;
8281
}) {
83-
//check the engine is the correct version
84-
const engineVersion = await determineEngineVersion({ environment });
85-
86-
if (engineVersion === "V1") {
87-
return {
88-
success: false as const,
89-
code: "engine-version",
90-
};
91-
}
92-
9382
const queue = await getQueue(this._replica, environment, queueInput);
9483
if (!queue) {
9584
return {

apps/webapp/app/routes/_app.orgs.$organizationSlug.projects.$projectParam.env.$envParam.branches/route.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ import { BranchEnvironmentIconSmall } from "~/assets/icons/EnvironmentIcons";
1414
import { BranchesNoBranchableEnvironment, BranchesNoBranches } from "~/components/BlankStatePanels";
1515
import { Feedback } from "~/components/Feedback";
1616
import { GitMetadata } from "~/components/GitMetadata";
17-
import { V4Title } from "~/components/V4Badge";
1817
import { AdminDebugTooltip } from "~/components/admin/debugTooltip";
1918
import { MainCenteredContainer, PageBody, PageContainer } from "~/components/layout/AppLayout";
2019
import { Badge } from "~/components/primitives/Badge";
@@ -231,7 +230,7 @@ export default function Page() {
231230
return (
232231
<PageContainer>
233232
<NavBar>
234-
<PageTitle title={<V4Title>Preview branches</V4Title>} />
233+
<PageTitle title="Preview branches" />
235234
</NavBar>
236235
<PageBody>
237236
<MainCenteredContainer className="max-w-md">
@@ -245,7 +244,7 @@ export default function Page() {
245244
return (
246245
<PageContainer>
247246
<NavBar>
248-
<PageTitle title={<V4Title>Preview branches</V4Title>} />
247+
<PageTitle title="Preview branches" />
249248
<PageAccessories>
250249
<AdminDebugTooltip>
251250
<Property.Table>

apps/webapp/app/routes/_app.orgs.$organizationSlug.projects.$projectParam.env.$envParam.dev-branches/route.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ import { useCallback } from "react";
66
import { SearchInput } from "~/components/primitives/SearchInput";
77
import { typedjson, useTypedLoaderData } from "remix-typedjson";
88
import { BranchEnvironmentIconSmall } from "~/assets/icons/EnvironmentIcons";
9-
import { V4Title } from "~/components/V4Badge";
109
import { AdminDebugTooltip } from "~/components/admin/debugTooltip";
1110
import { PageBody, PageContainer } from "~/components/layout/AppLayout";
1211
import { Badge } from "~/components/primitives/Badge";
@@ -98,7 +97,7 @@ export default function Page() {
9897
return (
9998
<PageContainer>
10099
<NavBar>
101-
<PageTitle title={<V4Title>Dev branches</V4Title>} />
100+
<PageTitle title="Dev branches" />
102101
<PageAccessories>
103102
<AdminDebugTooltip>
104103
<Property.Table>

0 commit comments

Comments
 (0)