talonvoice / talon

Issue Tracker for the main Talon app
85 stars 0 forks source link

[mac] talon debug menu or log viewer not movable via snap commands in some cases #598

Open knausj85 opened 1 year ago

knausj85 commented 1 year ago

Version: 0.3.1-529-g5f0a, Branch: rust, OS: macOS-13.2.1-x86_64-i386-64bit

  1. open talon log viewer or debug window
  2. open command history or other imgui
  3. close talon log viewer or debug window
  4. reopen talon log viewer or debug window
  5. attempt to move window via snap commands such as snap left; note error in log

2023-03-25 16:00:53 ERROR 6: talon/scripting/talon_script.py:604| 5: talon/scripting/talon_script.py:307| 4: talon/scripting/actions.py:88 | 3: user/knausj_talon/core/windows_and_tabs/window_snap.py:281| _snap_window_helper(ui.active_window().. 2: user/knausj_talon/core/windows_and_tabs/window_snap.py:191| screen = window.screen.visible_rect 1: talon/ui.py:184| talon.ui.UIErr: window not found

[The below error was raised while handling the above exception(s)] 2023-03-25 16:00:53 ERROR cb error topic="phrase" cb=SpeechSystem.engine_event 15: lib/python3.9/threading.py:937 # cron thread 14: lib/python3.9/threading.py:980 13: lib/python3.9/threading.py:917* 12: talon/cron.py:156| 11: talon/vad.py:21 | 10: talon/scripting/speech_system.py:363| 9: talon/engines/w2l.py:729| 8: talon/scripting/dispatch.py:134| # 'phrase' main:EngineProxy._redispatch() 7: talon/scripting/speech_system.py:65 | 6: ------------------------------------# [stack splice] 5: talon/scripting/dispatch.py:134| # 'phrase' main:SpeechSystem.engine_event() 4: talon/scripting/speech_system.py:436| 3: talon/scripting/executor.py:110| 2: talon/scripting/talon_script.py:705| 1: talon/scripting/talon_script.py:608| talon.scripting.talon_script.TalonScriptError: in script at /Users/knausj/.talon/user/knausj_talon/core/windows_and_tabs/window_management.talon:12:

user.snap_window(window_snap_position) UIErr: window not found

lunixbochs commented 1 year ago

does the titlebar show the window as focused or not? does clicking the window fix this state?

knausj85 commented 1 year ago

my bad, the title bar does show as focused.

clicking the window does not fix the state, but focusing another app and coming back does

knausj85 commented 1 year ago

things can also get a bit weird with both the log viewer and debug window open

  1. open debug menu
  2. open log viewer, which is focused according to the title bar
  3. attempt to move the log viewer via commands, and note it actually moves the debug menu which is not focused
lunixbochs commented 4 weeks ago

is this any better in 389?

knausj85 commented 4 weeks ago

It seems the original repro is less reliable, maybe -- but it still happens. I can't find the pattern.

However, the issue reliably repros with these steps: