The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
test(desktop): session reads no longer expect the foreground dial tag
teknium1ec14e8dfa2ff
diff --git a/apps/desktop/src/api/session-transcript-paging.test.ts b/apps/desktop/src/api/session-transcript-paging.test.tsindex e505d638c0f..4dbe26976e3 100644--- a/apps/desktop/src/api/session-transcript-paging.test.ts+++ b/apps/desktop/src/api/session-transcript-paging.test.ts@@ -73,12 +73,9 @@ describe('session transcript pagination ownership', () => {).toBe(true)// Resolve the owner for lookup, but replay the exact ambient read route.- // A backfill is a user's "Show earlier" click on an explicit route, so- // it carries the foreground dial tag (#111651).expect(api).toHaveBeenLastCalledWith({...(connectionId ? { connectionId } : {}),- path: `/api/sessions/stored-session/messages?limit=${LATEST_SESSION_MESSAGES_LIMIT}&offset=${tail.length}&order=latest&include_compacted=true`,- priority: 'foreground'+ path: `/api/sessions/stored-session/messages?limit=${LATEST_SESSION_MESSAGES_LIMIT}&offset=${tail.length}&order=latest&include_compacted=true`})expect(messages.map(message => message.rowId)).toEqual([...older, ...tail].map(message => message.id))expect(transcriptBackfillAvailable('stored-session', owner)).toBe(false)@@ -114,8 +111,7 @@ describe('session transcript pagination ownership', () => {// An explicit local pin would bypass Electron's per-profile remote override.expect.soft(api).toHaveBeenLastCalledWith({profile,- path: `/api/sessions/stored-session/messages?profile=${profile}&limit=${LATEST_SESSION_MESSAGES_LIMIT}&order=latest&include_compacted=true`,- priority: 'foreground'+ path: `/api/sessions/stored-session/messages?profile=${profile}&limit=${LATEST_SESSION_MESSAGES_LIMIT}&order=latest&include_compacted=true`})expect(transcriptBackfillAvailable('stored-session', owner)).toBe(true)@@ -132,8 +128,7 @@ describe('session transcript pagination ownership', () => {expect(api).toHaveBeenLastCalledWith({profile,- path: `/api/sessions/stored-session/messages?profile=${profile}&limit=${LATEST_SESSION_MESSAGES_LIMIT}&offset=${tail.length}&order=latest&include_compacted=true`,- priority: 'foreground'+ path: `/api/sessions/stored-session/messages?profile=${profile}&limit=${LATEST_SESSION_MESSAGES_LIMIT}&offset=${tail.length}&order=latest&include_compacted=true`})expect(applyOlderPage).toHaveBeenCalledWith(toChatMessages([row(1)]))expect(transcriptTailState('stored-session', owner)).toMatchObject({@@ -191,8 +186,7 @@ describe('session transcript pagination ownership', () => {// Serving-profile metadata selects the cache entry, not the request route.expect(api).toHaveBeenLastCalledWith({connectionId: 'source-a',- path: `/api/sessions/stored-session/messages?limit=${LATEST_SESSION_MESSAGES_LIMIT}&offset=${tail.messages.length}&order=latest&include_compacted=true`,- priority: 'foreground'+ path: `/api/sessions/stored-session/messages?limit=${LATEST_SESSION_MESSAGES_LIMIT}&offset=${tail.messages.length}&order=latest&include_compacted=true`})expect(applyOlderPage).toHaveBeenCalledWith(toChatMessages([row(0)]))expect(transcriptTailState('stored-session', ownerA)).toEqual({diff --git a/apps/desktop/src/hermes.test.ts b/apps/desktop/src/hermes.test.tsindex c0794c585a6..30c70e8e123 100644--- a/apps/desktop/src/hermes.test.ts+++ b/apps/desktop/src/hermes.test.ts@@ -509,9 +509,8 @@ describe('Hermes REST helpers', () => {expect(call.timeoutMs).toBeUndefined()})- // An explicit profile/connection scope is a user action (opening another- // profile's session, deleting a profile), so the request also carries the- // foreground dial tag (#111651).+ // Explicit profile/connection writes (deleting a profile) carry the foreground+ // dial tag; session reads stay on the ambient default (#111651).it('tags cross-profile message reads for Electron routing and backend lookup', async () => {api.mockResolvedValue({ messages: [], session_id: 'session-1' })@@ -519,7 +518,6 @@ describe('Hermes REST helpers', () => {expect(api).toHaveBeenCalledWith({path: '/api/sessions/session-1/messages?profile=xiaoxuxu',- priority: 'foreground',profile: 'xiaoxuxu'})})@@ -534,13 +532,11 @@ describe('Hermes REST helpers', () => {expect(api).toHaveBeenNthCalledWith(1, {connectionId: 'source-a',path: '/api/sessions/session-1?profile=backend-default',- priority: 'foreground',profile: 'backend-default'})expect(api).toHaveBeenNthCalledWith(2, {connectionId: 'source-a',path: '/api/sessions/session-1/messages?profile=backend-default',- priority: 'foreground',profile: 'backend-default'})})@@ -575,7 +571,6 @@ describe('Hermes REST helpers', () => {expect(LATEST_SESSION_MESSAGES_LIMIT).toBe(120)expect(api).toHaveBeenCalledWith({path: '/api/sessions/session-1/messages?profile=xiaoxuxu&limit=120&order=latest&include_compacted=true',- priority: 'foreground',profile: 'xiaoxuxu'})})@@ -601,7 +596,6 @@ describe('Hermes REST helpers', () => {expect(api).toHaveBeenCalledWith({path: '/api/sessions/session-1/messages?profile=xiaoxuxu&limit=120&offset=240&order=latest&include_compacted=true',- priority: 'foreground',profile: 'xiaoxuxu'})})@@ -617,7 +611,6 @@ describe('Hermes REST helpers', () => {expect(api).toHaveBeenCalledWith({path: '/api/sessions/session-1/messages?profile=xiaoxuxu&limit=500&offset=1000&order=latest',- priority: 'foreground',profile: 'xiaoxuxu'})})@@ -640,12 +633,10 @@ describe('Hermes REST helpers', () => {expect(result.messages).toEqual([{ id: 1 }, { id: 2 }, { id: 3 }])expect(api).toHaveBeenNthCalledWith(1, {path: '/api/sessions/session-1/messages?profile=xiaoxuxu&limit=500&offset=0&order=oldest&include_compacted=true',- priority: 'foreground',profile: 'xiaoxuxu'})expect(api).toHaveBeenNthCalledWith(2, {path: '/api/sessions/session-1/messages?profile=xiaoxuxu&limit=500&offset=2&order=oldest&include_compacted=true',- priority: 'foreground',profile: 'xiaoxuxu'})})