Stop phantom-notification hangs and drop noisy "0초" progress label
Agents ended turns with "I'll wait … I'll be notified" expecting a background-completion callback that this environment never delivers, so the turn hung and left the planning sentence stuck in the channel. Add a claude-platform rule that no such notification exists — finish within the turn (foreground/poll) or ask the user for a follow-up. Also suppress the elapsed-time suffix on progress messages until at least one 5s bucket has elapsed, so freshly-created progress no longer shows a meaningless "0초". Update the affected message-runtime expectations. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -4172,7 +4172,7 @@ describe('createMessageRuntime', () => {
|
||||
// First progress flushed when the second progress arrives
|
||||
expect(channel.sendAndTrack).toHaveBeenCalledWith(
|
||||
chatJid,
|
||||
P('CI 상태 확인 중입니다.\n\n0초'),
|
||||
P('CI 상태 확인 중입니다.'),
|
||||
);
|
||||
// Timer tick edits the tracked progress with updated elapsed time
|
||||
expect(channel.editMessage).toHaveBeenCalledWith(
|
||||
@@ -4272,11 +4272,11 @@ describe('createMessageRuntime', () => {
|
||||
// First progress flushed when second arrives — sendAndTrack throws, falls back to sendMessage
|
||||
expect(channel.sendAndTrack).toHaveBeenCalledWith(
|
||||
chatJid,
|
||||
P('진행 중입니다.\n\n0초'),
|
||||
P('진행 중입니다.'),
|
||||
);
|
||||
expect(channel.sendMessage).toHaveBeenCalledWith(
|
||||
chatJid,
|
||||
P('진행 중입니다.\n\n0초'),
|
||||
P('진행 중입니다.'),
|
||||
);
|
||||
});
|
||||
|
||||
@@ -4353,11 +4353,11 @@ describe('createMessageRuntime', () => {
|
||||
// First progress flushed when second arrives — sendAndTrack returns null, falls back to sendMessage
|
||||
expect(channel.sendAndTrack).toHaveBeenCalledWith(
|
||||
chatJid,
|
||||
P('진행 중입니다.\n\n0초'),
|
||||
P('진행 중입니다.'),
|
||||
);
|
||||
expect(channel.sendMessage).toHaveBeenCalledWith(
|
||||
chatJid,
|
||||
P('진행 중입니다.\n\n0초'),
|
||||
P('진행 중입니다.'),
|
||||
);
|
||||
});
|
||||
|
||||
@@ -4461,7 +4461,7 @@ describe('createMessageRuntime', () => {
|
||||
expect(channel.sendAndTrack).toHaveBeenCalledTimes(1);
|
||||
expect(channel.sendAndTrack).toHaveBeenCalledWith(
|
||||
chatJid,
|
||||
P('첫 번째 진행상황입니다.\n\n0초'),
|
||||
P('첫 번째 진행상황입니다.'),
|
||||
);
|
||||
// Timer tick updates tracked progress via edit
|
||||
expect(channel.editMessage).toHaveBeenCalledWith(
|
||||
@@ -4573,7 +4573,7 @@ describe('createMessageRuntime', () => {
|
||||
// First progress flushed when second arrives
|
||||
expect(channel.sendAndTrack).toHaveBeenCalledWith(
|
||||
chatJid,
|
||||
P('오래 걸리는 작업입니다.\n\n0초'),
|
||||
P('오래 걸리는 작업입니다.'),
|
||||
);
|
||||
// Timer ticks update the tracked progress with longer durations
|
||||
expect(channel.editMessage).toHaveBeenCalledWith(
|
||||
@@ -4679,7 +4679,7 @@ describe('createMessageRuntime', () => {
|
||||
// First progress flushed when second arrives
|
||||
expect(channel.sendAndTrack).toHaveBeenCalledWith(
|
||||
chatJid,
|
||||
P('테스트를 돌리는 중입니다.\n\n0초'),
|
||||
P('테스트를 돌리는 중입니다.'),
|
||||
);
|
||||
// Timer tick updates tracked progress
|
||||
expect(channel.editMessage).toHaveBeenCalledWith(
|
||||
@@ -5088,13 +5088,13 @@ describe('createMessageRuntime', () => {
|
||||
expect(channel.sendAndTrack).toHaveBeenNthCalledWith(
|
||||
1,
|
||||
chatJid,
|
||||
P('첫 번째 진행상황입니다.\n\n0초'),
|
||||
P('첫 번째 진행상황입니다.'),
|
||||
);
|
||||
// After empty final resets state, third progress flushed when fourth arrives (new message)
|
||||
expect(channel.sendAndTrack).toHaveBeenNthCalledWith(
|
||||
2,
|
||||
chatJid,
|
||||
P('두 번째 진행상황입니다.\n\n0초'),
|
||||
P('두 번째 진행상황입니다.'),
|
||||
);
|
||||
// Timer tick edits the first tracked progress
|
||||
expect(channel.editMessage).toHaveBeenCalledWith(
|
||||
@@ -5213,7 +5213,7 @@ describe('createMessageRuntime', () => {
|
||||
// First progress flushed when second arrives
|
||||
expect(channel.sendAndTrack).toHaveBeenCalledWith(
|
||||
chatJid,
|
||||
P('검증 중입니다.\n\n0초'),
|
||||
P('검증 중입니다.'),
|
||||
);
|
||||
// Once the tracked progress exists, later progress updates replace the visible heading directly.
|
||||
expect(channel.editMessage).toHaveBeenCalledWith(
|
||||
@@ -5329,7 +5329,7 @@ describe('createMessageRuntime', () => {
|
||||
// The first flushed progress is still tracked
|
||||
expect(channel.sendAndTrack).toHaveBeenCalledWith(
|
||||
chatJid,
|
||||
P('진행 중입니다.\n\n0초'),
|
||||
P('진행 중입니다.'),
|
||||
);
|
||||
// Edit is attempted on the tracked message (first fails, subsequent succeed)
|
||||
expect(channel.editMessage).toHaveBeenCalledWith(
|
||||
@@ -5568,7 +5568,7 @@ describe('createMessageRuntime', () => {
|
||||
// First progress flushed when second arrives
|
||||
expect(channel.sendAndTrack).toHaveBeenCalledWith(
|
||||
chatJid,
|
||||
P('중간 진행상황입니다.\n\n0초'),
|
||||
P('중간 진행상황입니다.'),
|
||||
);
|
||||
// Error replaces the tracked progress message with the failure final
|
||||
expect(channel.sendMessage).not.toHaveBeenCalled();
|
||||
|
||||
Reference in New Issue
Block a user