Skip to content

[containerapp] Container Apps logs in follow mode exit after not receiving new logs for a few minutes #9958

Description

Source: Azure/azure-cli#33487 (by Jan Martin (@catmanjan))
Affected extension: containerapp (src/containerapp/)


<<UNTRUSTED:issue-33487>>

Issue #33487 (by Jan Martin (@catmanjan))

Title

Container Apps logs in follow mode exit after not receiving new logs for a few minutes

Body

Describe the bug

Similar to Azure/azure-cli#28267

I am following container logs like so

az containerapp logs show --n cmlinux -g cmlinux --follow --tail 30

The container is intentionally quiet in logging, after approximately 3 minutes the log command just stops

Related command

az containerapp logs show --n cmlinux -g cmlinux --follow --tail 30

Errors

N/A

Issue script & Debug output

az containerapp logs show --n cmlinux -g cmlinux --follow --tail 30

{"TimeStamp": "2026-06-03T04:45:59.2214149+00:00", "Log": "F 013c:fixme:file:NtFsControlFile FSCTL_PIPE_IMPERSONATE: impersonating self"}
{"TimeStamp": "2026-06-03T04:48:25.34888", "Log": "No logs since last 60 seconds"}
{"TimeStamp": "2026-06-03T04:49:25.74618", "Log": "No logs since last 60 seconds"}
{"TimeStamp": "2026-06-03T04:50:26.18445", "Log": "No logs since last 60 seconds"}
{"TimeStamp": "2026-06-03T04:51:26.71221", "Log": "No logs since last 60 seconds"}
sysadmin@nuc:~$

Expected behavior

Should tail forever

Environment Summary

azure-cli 2.87.0

Can also reproduce it in browser

Additional context

No response

Comments

Comment by Yong Zhang (@yonzhan)

Thank you for opening this issue, we will look into it.
<<END:issue-33487>>

Activity

  1. azclibot commented on Jun 20, 2026

    @azclibot
    CollaboratorAuthor

    Hi Copilot! Please investigate and fix this bug in the containerapp extension.

    Issue summary: az containerapp logs show --follow exits after a few minutes of inactivity instead of tailing indefinitely.

    Failing command:

    az containerapp logs show --n cmlinux -g cmlinux --follow --tail 30
    

    Observed behavior: After ~3 minutes with no new log output, the command exits. The output shows repeated "No logs since last 60 seconds" messages until the command terminates.

    Expected behavior: The --follow flag should keep the log stream open indefinitely, regardless of inactivity periods.

    CLI version: azure-cli 2.87.0

    Notes:

    Please look at the containerapp extension's log follow implementation and fix the idle timeout / reconnection behavior so that --follow truly tails forever.


    Posted by agent-assist (autonomous bug-fix pipeline).

  2. yonzhan commented on Jun 20, 2026

    @yonzhan
    Collaborator

    Thank you for opening this issue, we will look into it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions