Skip to content

Commit 8ea1424

Browse files
Merge remote-tracking branch 'origin/main' into fix/background-wait-plan-mode
2 parents 83da712 + 31eea88 commit 8ea1424

136 files changed

Lines changed: 3982 additions & 1251 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎apps/desktop/src/app/ClerkTokenStore.test.ts‎

Lines changed: 0 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,6 @@ import * as NodeFS from "node:fs";
33
import * as NodeOS from "node:os";
44
import * as NodePath from "node:path";
55
import { assert, describe, it } from "@effect/vitest";
6-
import { vi } from "vite-plus/test";
7-
8-
vi.mock("node:fs", { spy: true });
96

107
import { openClerkTokenStorage, type ClerkTokenStorage } from "./ClerkTokenStore.ts";
118

@@ -91,24 +88,6 @@ describePosix("ClerkTokenStore", () => {
9188
});
9289
});
9390

94-
it("removes the legacy token file when the private copy already exists", async () => {
95-
await withStateDir((stateDir) => {
96-
const directory = NodePath.join(stateDir, "clerk");
97-
const legacyPath = NodePath.join(stateDir, "clerk-tokens.json");
98-
const tokenPath = NodePath.join(directory, "clerk-tokens.json");
99-
NodeFS.mkdirSync(directory, { mode: 0o755 });
100-
writeLoose(legacyPath, "stale-credential");
101-
writeLoose(tokenPath, "kept-credential");
102-
103-
openClerkTokenStorage(stateDir, () => idleStorage());
104-
105-
assert.equal(NodeFS.existsSync(legacyPath), false);
106-
assert.equal(modeOf(directory), 0o700);
107-
assert.equal(modeOf(tokenPath), 0o600);
108-
assert.equal(NodeFS.readFileSync(tokenPath, "utf8"), "kept-credential");
109-
});
110-
});
111-
11291
it("resolves a relative state directory before opening storage", async () => {
11392
await withStateDir(async (stateDir) => {
11493
const relativeStateDir = NodePath.relative(process.cwd(), stateDir);
@@ -150,23 +129,6 @@ describePosix("ClerkTokenStore", () => {
150129
});
151130
});
152131

153-
it("migrates tokens when the legacy directory is on another filesystem", async () => {
154-
await withStateDir((stateDir) => {
155-
const legacyPath = NodePath.join(stateDir, "clerk-tokens.json");
156-
writeLoose(legacyPath, "existing-session");
157-
using _rename = vi.spyOn(NodeFS, "renameSync").mockImplementation(() => {
158-
throw Object.assign(new Error("cross-device link"), { code: "EXDEV" });
159-
});
160-
161-
openClerkTokenStorage(stateDir, idleStorage);
162-
163-
const tokenPath = NodePath.join(stateDir, "clerk", "clerk-tokens.json");
164-
assert.equal(NodeFS.readFileSync(tokenPath, "utf8"), "existing-session");
165-
assert.equal(modeOf(tokenPath), 0o600);
166-
assert.equal(NodeFS.existsSync(legacyPath), false);
167-
});
168-
});
169-
170132
it("does not follow a symlinked clerk directory or token file", async () => {
171133
await withStateDir(async (stateDir) => {
172134
const outsideDirectory = NodePath.join(stateDir, "outside-dir");

‎apps/desktop/src/snapShot/DesktopSnapShot.test.ts‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1048,7 +1048,6 @@ it.effect.each([
10481048
{ backend: "gnome", screenshot: "PNG" },
10491049
{ backend: "niri", screenshot: "PNG" },
10501050
{ backend: "kde", screenshot: "PNG" },
1051-
{ backend: "hyprland", screenshot: "PNG" },
10521051
{ backend: "gnome", screenshot: "invalid" },
10531052
] as const)(
10541053
"persists $backend accessibility text with a $screenshot screenshot",

‎apps/mobile/modules/t3-terminal/android/src/main/cpp/t3_terminal_jni.cpp‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@ namespace {
1212

1313
constexpr uint32_t kSnapshotMagic = 0x54563354; // "T3VT" in little endian.
1414
constexpr uint16_t kSnapshotVersion = 1;
15-
constexpr size_t kMaxScrollbackRows = 10000;
15+
// The pinned ABI measures max_scrollback in bytes despite its header saying lines.
16+
// Match Ghostty's default scrollback-limit.
17+
constexpr size_t kMaxScrollbackBytes = 10'000'000;
1618

1719
enum CellFlag : uint16_t {
1820
kBold = 1 << 0,
@@ -205,7 +207,7 @@ Java_expo_modules_t3terminal_GhosttyBridge_nativeCreate(
205207
GhosttyTerminalOptions options = {
206208
.cols = static_cast<uint16_t>(std::clamp(cols, 1, 65535)),
207209
.rows = static_cast<uint16_t>(std::clamp(rows, 1, 65535)),
208-
.max_scrollback = kMaxScrollbackRows,
210+
.max_scrollback = kMaxScrollbackBytes,
209211
};
210212
if (ghostty_terminal_new(nullptr, &session->terminal, options) != GHOSTTY_SUCCESS ||
211213
ghostty_render_state_new(nullptr, &session->render_state) != GHOSTTY_SUCCESS ||

‎apps/mobile/src/features/browser/BrowserPreviewRouteScreen.tsx‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ import { Platform, TextInput, View } from "react-native";
1010
import { useSafeAreaInsets } from "react-native-safe-area-context";
1111

1212
import { ControlPill } from "../../components/ui/ControlPill";
13+
import { useContentTopInset } from "../../components/ui/useBarInset";
1314
import { useAppForeground } from "../../lib/appState";
1415

1516
import { useThreadServerBrowserTabs } from "../../state/preview";
@@ -56,6 +57,7 @@ function BrowserPreviewScreen({
5657
readonly onClose: () => void;
5758
}) {
5859
const insets = useSafeAreaInsets();
60+
const contentTopInset = useContentTopInset();
5961
const { themeVariables } = useAppearancePreferences();
6062
const prepared = usePreparedConnection(environmentId);
6163
const httpBaseUrl = Option.isSome(prepared) ? prepared.value.httpBaseUrl : null;
@@ -90,7 +92,10 @@ function BrowserPreviewScreen({
9092
const live = (focused && foreground) || pictureInPicture.active;
9193

9294
return (
93-
<View className="flex-1 bg-sheet" style={{ paddingBottom: insets.bottom }}>
95+
<View
96+
className="flex-1 bg-sheet"
97+
style={{ paddingTop: contentTopInset, paddingBottom: insets.bottom }}
98+
>
9499
<SheetHeader
95100
title={tab ? browserTabTitle(tab) : "Browser"}
96101
onClose={onClose}

‎apps/mobile/src/features/diffs/nativeReviewDiffSource.test.ts‎

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,6 @@ it("evicts source text by aggregate size and returns an over-budget response unc
3939
expect(fetch).toHaveBeenCalledTimes(5);
4040
});
4141

42-
it("lets later viewport requests retry a failed source fetch", async () => {
43-
const fetch = vi.fn().mockRejectedValueOnce(new Error("Offline")).mockResolvedValueOnce(SOURCE);
44-
const load = createNativeReviewDiffSourceLoader(fetch);
45-
await expect(load("retry.ts")).rejects.toThrow("Offline");
46-
expect(await load("retry.ts")).toBe(SOURCE);
47-
});
48-
4942
const failureKeys = [
5043
["string", () => "retry.ts"],
5144
["number", () => 1],

‎apps/mobile/src/features/home/useThreadListActions.test.ts‎

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -532,13 +532,6 @@ describe("thread action undo", () => {
532532
await undo();
533533
expect(state.requests.map(({ action }) => action)).toEqual(["unpin"]);
534534
});
535-
536-
// regression: #21401 restore archive and thread action undo
537-
it("refreshes the archive after archiving on a settlement-capable server", async () => {
538-
await useThreadListActions().archiveThread(makeThread());
539-
expect(state.requests.map(({ action }) => action)).toEqual(["archive"]);
540-
expect(state.archivedRefreshes).toEqual([primaryEnvironmentId]);
541-
});
542535
});
543536

544537
describe("thread archive guard", () => {

‎apps/mobile/src/features/pull-requests/pullRequestDiffPages.test.ts‎

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -110,18 +110,6 @@ describe("paged mobile pull request diffs", () => {
110110
expect(cached.files[0]).toBe(parsed.files[0]);
111111
});
112112

113-
it("points a withheld merge request diff at the merge request", () => {
114-
const parsed = combinePullRequestDiffPages(
115-
[{ cursor: null, result: withheldDiff() }],
116-
new WeakMap(),
117-
"mr",
118-
sourceControlClients.get("gitlab").changeRequest,
119-
);
120-
expect(parsed.kind === "files" ? parsed.notice : null).toBe(
121-
"Some file contents are unavailable. Open the merge request on its provider to see the full changes.",
122-
);
123-
});
124-
125113
it("combines normal and withheld pages and refreshes counts with unchanged patch text", () => {
126114
const first = { ...diff("first.ts"), nextCursor: "second" };
127115
const withheld = withheldDiff();

‎apps/mobile/src/features/threads/ThreadFeed.tsx‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ import {
1010
withChipIcon,
1111
} from "../../native/useEnrichedLinkVariants";
1212
import {
13-
enrichedSkillDisplayName,
1413
enrichedSkillInstructionsPath,
1514
enrichedSkillReference,
1615
} from "../../lib/enrichedLinkPresentation";
16+
import { formatProviderSkillDisplayName } from "@t3tools/shared/inlineSkills";
1717
import { ThreadContextDivider } from "./thread-context-divider";
1818
import {
1919
ThreadHandoffDivider,
@@ -2992,7 +2992,7 @@ export const ThreadFeed = memo(function ThreadFeed(props: ThreadFeedProps) {
29922992
const skill = enrichedSkillReference(href, props.skills);
29932993
if (skill) {
29942994
return {
2995-
title: enrichedSkillDisplayName(skill),
2995+
title: formatProviderSkillDisplayName(skill),
29962996
actions: [
29972997
{
29982998
id: "open-skill",

‎apps/mobile/src/features/threads/threadListV2.test.ts‎

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ import {
4242
resolveThreadListV2SnoozePresets,
4343
resolveThreadListV2Status,
4444
resolveThreadListV2WokeAt,
45-
sortThreadsForListV2,
4645
threadListV2ListItemsAreEqual,
4746
threadHasUnseenCompletion,
4847
type ThreadListV2ListItem,
@@ -270,17 +269,6 @@ describe("search lists ranked matches", () => {
270269
});
271270
});
272271

273-
describe("sortThreadsForListV2", () => {
274-
it("honors a saved active order and leaves new threads above it", () => {
275-
const sorted = sortThreadsForListV2([
276-
{ id: "newer-arranged", createdAt: "2026-06-01T12:00:00.000Z", activeOrderKey: "t" },
277-
{ id: "older-arranged", createdAt: "2026-06-01T08:00:00.000Z", activeOrderKey: "f" },
278-
{ id: "new", createdAt: "2026-06-01T13:00:00.000Z" },
279-
]);
280-
expect(sorted.map((thread) => thread.id)).toEqual(["new", "older-arranged", "newer-arranged"]);
281-
});
282-
});
283-
284272
describe("getThreadListV2OrderedSection", () => {
285273
it("uses each saved order and excludes settled, snoozed, and archived rows", () => {
286274
const threads = [

‎apps/mobile/src/features/threads/threadListV2.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -301,7 +301,7 @@ function parseTimestampMs(isoDate: string): number {
301301
return Number.isNaN(parsed) ? 0 : parsed;
302302
}
303303

304-
export function sortThreadsForListV2<
304+
function sortThreadsForListV2<
305305
T extends {
306306
readonly id: string;
307307
readonly createdAt: string;

0 commit comments

Comments
 (0)