Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
51e6c39
feat(mobile): add new session prefill helpers
iscekic Aug 1, 2026
4d5f18c
feat(mobile): prefill continued sessions
iscekic Aug 1, 2026
2de8142
feat(mobile): add continue session action
iscekic Aug 1, 2026
2ccd38b
fix(mobile): satisfy prefill lint rules
iscekic Aug 1, 2026
42456ba
test(mobile): type prefill cases
iscekic Aug 1, 2026
94eb664
fix(mobile): resolve prefill test lint
iscekic Aug 1, 2026
05af6e2
fix(mobile): restrict prefill repositories to GitHub
iscekic Aug 1, 2026
0001f68
refactor(mobile-e2e): simplified runbook, scripted stub setup, load-t…
iscekic Aug 1, 2026
50e208c
fix(mobile-e2e): address review findings on retry and stub rollback
iscekic Aug 2, 2026
d5778b7
fix(mobile-e2e): close concurrency races found in adversarial review
iscekic Aug 2, 2026
50be1ed
fix(mobile-e2e): adversarial-review round 2
iscekic Aug 2, 2026
69e21e7
fix(mobile-e2e): seed verifies the endpoint's success flag
iscekic Aug 2, 2026
7146391
fix(mobile-e2e): server stop verifies death before dropping state
iscekic Aug 2, 2026
5c6f274
fix(mobile-e2e): address stub-claim, re-seed, and lsof review findings
iscekic Aug 2, 2026
e26d0d0
fix(mobile-e2e): tighten adoption, signal exits, and legacy-seed hand…
iscekic Aug 2, 2026
48f61f5
fix(mobile-e2e): name both sources of an existing token row
iscekic Aug 2, 2026
e5a0494
fix(mobile-e2e): stub row verification, self-cleaning start, lsof fal…
iscekic Aug 2, 2026
c7835ac
fix(mobile-e2e): honest row probe, race-safe rollback, blind-lsof reuse
iscekic Aug 2, 2026
449c242
fix(mobile-e2e): close the last rollback and adoption windows
iscekic Aug 2, 2026
fec3e1f
fix(mobile-e2e): serialize the stub per worktree instead of guarding …
iscekic Aug 2, 2026
973fdf5
fix(mobile-e2e): row-probe failures skip the missing-user hint
iscekic Aug 2, 2026
4f759f0
fix(mobile-e2e): bound the lock's hold time and the survivor edge
iscekic Aug 2, 2026
616c33b
feat(mobile-e2e): copy a real GitHub integration onto an e2e account
iscekic Aug 2, 2026
1f1eaed
fix(mobile-e2e): copies never donate or collide with the stub
iscekic Aug 2, 2026
1a34adb
docs(mobile-e2e): STE pass over the runbook additions
iscekic Aug 2, 2026
ffd814c
fix(mobile-e2e): copies validate the donor live and can never refresh
iscekic Aug 2, 2026
4ed26ca
fix(mobile-e2e): guard the integration copy's blast radius
iscekic Aug 2, 2026
c398e75
fix(mobile-e2e): env failures in the copy tool name their own fix
iscekic Aug 2, 2026
66b7904
fix(mobile-e2e): make the copy's guards atomic and expiry-safe
iscekic Aug 2, 2026
36f3437
fix(mobile-e2e): state the copy's real lifetime and align the lock bu…
iscekic Aug 2, 2026
f752367
fix(mobile-e2e): re-assert the usable window after the live probes
iscekic Aug 2, 2026
df4aac2
docs(mobile-e2e): bound big outputs, never doctor --json
iscekic Aug 2, 2026
96200a3
docs(mobile-e2e): doctor is always a full JSON dump; never tail JSON
iscekic Aug 2, 2026
8f597c7
Merge remote-tracking branch 'origin/mobile-e2e-ste' into session-for…
iscekic Aug 2, 2026
8f432d4
chore: retrigger review
iscekic Aug 2, 2026
3e1548d
Merge origin/main and drop the harness files it now owns
iscekic Aug 3, 2026
31563e3
Merge origin/main and rebuild prefill on the new-session refactor
iscekic Aug 3, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion apps/mobile/src/app/(app)/agent-chat/new.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import {
useNewSessionModelState,
} from '@/components/agents/new-session-model-provider';
import { pickAgentAttachments } from '@/components/agents/attachment-picker';
import { useNewSessionPrefillTargets } from '@/components/agents/use-new-session-prefill';
import { ScreenHeader } from '@/components/screen-header';
import { AGENT_ATTACHMENT_MAX_FILES } from '@/lib/agent-attachments/constants';
import { useAgentAttachmentUpload } from '@/lib/agent-attachments/use-agent-attachment-upload';
Expand Down Expand Up @@ -44,7 +45,6 @@ function NewSessionScreenBody() {
}>();
const shareId: string | undefined = Array.isArray(shareIdParam) ? shareIdParam[0] : shareIdParam;

const [selectedRepo, setSelectedRepo] = useState('');
const [runOnInstance, setRunOnInstance] = useState<InstancePickerInstance | null>(null);
const [isCreating, setIsCreating] = useState(false);
const [isSubmitting, setIsSubmitting] = useState(false);
Expand Down Expand Up @@ -73,6 +73,13 @@ function NewSessionScreenBody() {
refreshReposForceFresh,
} = useNewSessionRepos({ organizationId });

const { selectedRepo, setSelectedRepo } = useNewSessionPrefillTargets({
repositories,
reposSettled: view === 'repos' && repositories.length > 0,
models,
modelsSettled: !isLoadingModels && !isModelsError && models.length > 0,
});

// Keep the inline selector and picker list in sync.
const {
data: instancesData,
Expand Down
12 changes: 8 additions & 4 deletions apps/mobile/src/components/agents/new-session-model-provider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ import {
} from 'react';

import { type AgentMode } from '@/components/agents/mode-selector';
import { resolvePrefillModel } from '@/components/agents/new-session-prefill';
import { useNewSessionPrefill } from '@/components/agents/use-new-session-prefill';
import { RemoteSpawnInheritanceProvider } from '@/components/agents/use-remote-spawn-dispatch';
import { useAvailableModels } from '@/lib/hooks/use-available-models';
import { useAutoSelectModel } from '@/lib/hooks/use-auto-select-model';
Expand Down Expand Up @@ -42,16 +44,18 @@ export function NewSessionModelProvider({
organizationId,
children,
}: Readonly<NewSessionModelProviderProps>) {
const [mode, setMode] = useState<AgentMode>('code');
const prefill = useNewSessionPrefill();
const [mode, setMode] = useState<AgentMode>(prefill.mode);
const [model, setModel] = useState('');
const [variant, setVariant] = useState('');
const { models } = useAvailableModels(organizationId);
const autoSelected = useAutoSelectModel(models, organizationId);
const hasAppliedAutoSelection = useRef(false);
if (!hasAppliedAutoSelection.current && autoSelected.model && !model) {
const initialSelection = resolvePrefillModel(models, prefill) ?? autoSelected;
if (!hasAppliedAutoSelection.current && initialSelection.model && !model) {
hasAppliedAutoSelection.current = true;
setModel(autoSelected.model);
setVariant(autoSelected.variant);
setModel(initialSelection.model);
setVariant(initialSelection.variant);
}
const state = useMemo(
() => ({ mode, setMode, model, setModel, variant, setVariant }),
Expand Down
Loading