amazon-q-developer-cli icon indicating copy to clipboard operation
amazon-q-developer-cli copied to clipboard

Chat session hangs at welcome message without displaying input prompt

Open mabuchs opened this issue 1 year ago • 3 comments

Checks

Operating system

macOS 15.3.2 (24D81)

Expected behaviour

When running 'q chat' command, the Amazon Q Developer CLI should display the complete welcome message and then show an input prompt where the user can type their questions or commands to interact with the chat interface.

Actual behaviour

After running 'q chat' command, the CLI displays only a partial welcome message showing the Amazon Q ASCII art logo and the "Did you know?" tip. The process then hangs indefinitely without displaying the input prompt, making it impossible to interact with the chat interface. The terminal cursor remains blinking after the incomplete welcome message with no way to proceed further.

Image

Steps to reproduce

  • Installing Q following the doc
  • update automatically to 1.9.0
  • execute q chat in zsh session

What I tried to resolve but failed

  • OS reboot
  • Clearing ~/.aws/amazonq contents
  • Clearing ~/.zshrc contents
  • q logout and q login
  • q restart
  • Uninstallation & reinstallation

Environment

<This will be visible to anyone. Do not include personal or sensitive information>

[q-details]
version = "1.9.0"
hash = "4cb1fcebf0111a468c0670d0f138d96ab9756f7d"
date = "2025-04-29T00:47:54.103838Z (5h ago)"
variant = "full"

[system-info]
os = "macOS 15.3.2 (24D81)"
chip = "Apple M1 Pro"
total-cores = 8
memory = "16.00 GB"

[environment]
cwd = "/Users/USER/"
cli-path = "/Users/USER/"
os = "Mac"
shell-path = "/bin/zsh"
shell-version = "5.9"
terminal = "VSCode"
install-method = "unknown"

[env-vars]
PATH = "/opt/homebrew/opt/libpq/bin:/opt/homebrew/opt/libpq/bin:/Users/USER/bin:/Users/USER/.pyenv/shims:/Users/USER/.pyenv/bin:/Users/USER/.n/bin:/Users/USER/bin:/Users/USER/.pyenv/bin:/Users/USER/.n/bin:/opt/homebrew/bin:/opt/homebrew/sbin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/opt/homebrew/opt/libpq/bin:/Users/USER/bin:/Users/USER/.pyenv/bin:/Users/USER/.n/bin:/Users/USER/.local/bin"
QTERM_SESSION_ID = "4a8125be285643ea95d81aece778bb2a"
Q_SET_PARENT_CHECK = "1"
Q_TERM = "1.9.0"
SHELL = "/bin/zsh"
TERM = "xterm-256color"
ZDOTDIR = "/Users/USER"
__CFBundleIdentifier = "com.microsoft.VSCode"

mabuchs avatar Apr 29 '25 06:04 mabuchs

Additional information:

I found a temporary workaround by deleting the ~/Library/Application Support/amazon-q directory, which allowed the CLI to start properly. However, this is not a permanent solution. After launching the q chat command several times, the hanging issue eventually reoccurs.

mabuchs avatar Apr 29 '25 06:04 mabuchs

I also reproduced the same issue after upgrading to v1.9.0. (macOS 15.3.2 - M2 Mac) It seems like a memory leak is occurring, resulting in zsh killed.

raihaku@Mac ~ % q chat
To learn more about MCP safety, see https://docs.aws.amazon.com/amazonq/latest/qdeveloper-ug/command-line-mcp-security.html

Welcome to 

 █████╗ ███╗   ███╗ █████╗ ███████╗ ██████╗ ███╗   ██╗     ██████╗ 
██╔══██╗████╗ ████║██╔══██╗╚══███╔╝██╔═══██╗████╗  ██║    ██╔═══██╗
███████║██╔████╔██║███████║  ███╔╝ ██║   ██║██╔██╗ ██║    ██║   ██║
██╔══██║██║╚██╔╝██║██╔══██║ ███╔╝  ██║   ██║██║╚██╗██║    ██║▄▄ ██║
██║  ██║██║ ╚═╝ ██║██║  ██║███████╗╚██████╔╝██║ ╚████║    ╚██████╔╝
╚═╝  ╚═╝╚═╝     ╚═╝╚═╝  ╚═╝╚══════╝ ╚═════╝ ╚═╝  ╚═══╝     ╚══▀▀═╝ 
                                                        


╭───────────────────────── Did you know? ─────────────────────────╮
│                                                                 │
│      You can enable custom tools with MCP servers. Place a      │
│            mcp config in ~/.aws/amazonq/mcp.json or             │
│    /your/current/workspace/.amazonq/mcp.json. Learn more at     │
zsh: killed     q chat
raihaku@Mac ~ % 
raihaku@Mac ~ % top -l 0 -s 2 -o mem | grep -i " q "              
PID    COMMAND          %CPU TIME     #TH   #WQ #PORTS MEM   PURG CMPRS PGRP  PPID  STATE    BOOSTS      %CPU_ME %CPU_OTHRS UID FAULTS  COW  MSGSENT  MSGRECV  SYSBSD   SYSMACH  CSW      PAGEINS IDLEW   POWER INSTRS CYCLES JETPRI USER               #MREGS RPRVT VPRVT VSIZE KPRVT KSHRD
15330  q                0.0  00:00.01 10    0    31     6306K 0B   0B    15329 15329 sleeping *0[1]      0.00000 0.00000    501 1063    232  44       17       460      177      37       0       0       0.0   0      0      180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                0.0  00:01.61 11/1  3    61+    1631M+ 0B     408M+  15346 14462 running  *0[1+]      0.00000 0.00000    501 148151+  246+  264+      34+       2397+     641+      4954+     453+    0        0.0   0          0          180+   raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                94.3 00:03.54 11/1  3    61     3445M+ 0B     1747M+ 15346 14462 running  *0[1]       0.00000 0.00000    501 329368+  246   264       34        2402+     641       6224+     453     0        94.3  26993682641 6526233719 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                88.0 00:05.33 11/1  3    61     5534M+ 0B     3800M+ 15346 14462 running  *0[1]       0.00000 0.00000    501 553735+  246   269+      35+       2421+     648+      7712+     453     0        88.0  23572705439 5971463591 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                94.2 00:07.28 11/1  3    61     7000M+ 0B     5228M+ 15346 14462 running  *0[1]       0.00000 0.00000    501 687980+  246   269       35        2421      648       8125+     453     0        94.2  28028783152 6569813316 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                99.9 00:09.31 11/1  3    61     7935M+ 0B     6222M+ 15346 14462 running  *0[1]       0.00000 0.00000    501 747818+  246   269       35        2421      648       8134+     453     0        99.9  30744690145 6922511071 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                69.0 00:10.74 8/1   1    52-    11G+   0B     9799M+ 15346 14462 running  *0[1]       0.00000 0.00000    501 1202755+ 246   271+      35        2435+     655+      11753+    453     0        69.0  12721326982 4450045262 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                91.4 00:12.63 8/1   1    52     13G+   0B     11G+   15346 14462 running  *0[1]       0.00000 0.00000    501 1341357+ 246   271       35        2435      655       12557+    453     0        91.4  26978120917 6345649317 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                99.9 00:14.66 8/1   1    52     14G+   0B     12G+   15346 14462 running  *0[1]       0.00000 0.00000    501 1400827+ 246   271       35        2435      655       12568+    453     0        99.9  30555567974 6913255982 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                99.9 00:16.69 8/1   1    52     15G+   0B     13G+   15346 14462 running  *0[1]       0.00000 0.00000    501 1460179+ 246   271       35        2435      655       12579+    453     0        99.9  30495189761 6904095061 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                100.0 00:18.73 8/1   1    52     16G+   0B     14G+   15346 14462 running  *0[1]       0.00000 0.00000    501 1519649+ 246   271       35        2435      655       12590+    453     0        100.0 30556406173 6921499244 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                80.2  00:20.37 8/1   1    52     18G+   0B     16G+   15346 14462 running  *0[1]       0.00000 0.00000    501 1822057+ 246   271       35        2440+     655       14764+    453     0        80.2  18968189376 5311394424 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                53.9  00:21.48 8/1   1    52     22G+   0B     20G+   15346 14462 running  *0[1]       0.00000 0.00000    501 2361150+ 246   271       35        2440      655       18850+    453     0        53.9  4314680088  3164240383 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                78.9  00:23.11 8/1   1    52     25G+   0B     23G+   15346 14462 running  *0[1]       0.00000 0.00000    501 2634159+ 246   272+      35        2440      655       20589+    453     0        78.9  19063398934 5251057329 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                99.8  00:25.15 8/1    1    52     25G+   0B     24G+   15346 14462 running  *0[1]       0.00000 0.00000    501 2694365+ 246   272       35        2440      655       20633+    453     0        99.8  30934569034 6902005108 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                99.6  00:27.18 8/1    1    52     26G+   0B     25G+   15346 14462 running  *0[1]       0.00000 0.00000    501 2754707+ 246   272       35        2450+     655       20817+    453     0        99.6  30990368918 6854813502 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                100.0 00:29.23 8/1    1    52     27G+   0B     26G+   15346 14462 running  *0[1]       0.00000 0.00000    501 2816027+ 246   272       35        2450      655       20822+    453     0        100.0 31507766063 6970027296 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                100.3 00:31.27 8/1    1    52     28G+   0B     27G+   15346 14462 running  *0[1]       0.00000 0.00000    501 2875897+ 246   272       35        2450      655       20931+    453     0        100.3 30763390226 6880491333 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                99.8  00:33.31 8/1    1    52     29G+   0B     28G+   15346 14462 running  *0[1]       0.00000 0.00000    501 2936154+ 246   272       35        2450      655       20998+    453     0        99.8  30961452483 6895782490 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                99.8  00:35.35 8/1    1    52     30G+   0B     29G+   15346 14462 running  *0[1]       0.00000 0.00000    501 2995894+ 246   272       35        2450      655       21041+    453     0        99.8  30696208623 6893628495 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                98.8  00:37.35 8/1    1    52     31G+   0B     30G+   15346 14462 running  *0[1]       0.00000 0.00000    501 3054820+ 246   272       35        2450      655       21917+    453      1+       98.8  30286492489 6711168179 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                99.3  00:39.39 8/1    1    52     32G+   0B     31G+   15346 14462 running  *0[1]       0.00000 0.00000    501 3114833+ 246   272       35        2450      655       22140+    453      1        99.3  30839107837 6779701811 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                70.9  00:40.83 8/1    1    52     36G+   0B     34G+   15346 14462 running  *0[1]       0.00000 0.00000    501 3623508+ 246   272       35        2451+     655       31029+    453      1        70.9  9348326993  3952995312 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  
15346  q                59.0  00:42.08 8/1    1    52     39G+   0B     37G+   15346 14462 running  *0[1]       0.00000 0.00000    501 4006461+ 246   272       35        2451      655       36155+    453      1        59.0  3089351316  1879565537 180    raihaku            N/A    N/A   N/A   N/A   N/A   N/A  

raihaku avatar Apr 29 '25 07:04 raihaku

This was resolved in 1.9.1 . Please update the latest version.

channy avatar Apr 29 '25 08:04 channy