Document Windows support and the AutoBuyer components
focus.py now verifies on Windows rather than assuming activation worked. Windows declines to raise a window for a process that doesn't own the foreground — it flashes the taskbar and the call returns as if it succeeded — so the runner reads the foreground window's process back and reports a failure instead of clicking into a background window. Same gap that was fixed on macOS earlier. The runner also declares itself DPI-aware at startup. Without it Windows reports a virtualised screen size and rescales the coordinates it accepts, while the browser keeps reporting CSS pixels; on a display at 125% or 150% the two disagree and clicks drift further off the further they are from the top-left. Browser windows are matched on the owning process rather than the window title, so an editor with chrome.js open is no longer mistaken for the browser. Linux now says window management is unsupported there, rather than reporting no browser found — pygetwindow has no X11 backend, and "no browser window" reads like Chrome is shut. The main README gained a section on the AutoBuyer: what the three pieces are, how to load the extension, and that neither the extension nor the runner reloads itself when the source changes. That last point has been the cause of most of the confusing failures so far, so it is called out in Updating too. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5
parent
65a1103cda
commit
37adbf67fc
+6
-1
@@ -32,7 +32,7 @@ HEARTBEAT_SECONDS = 2.0
|
||||
# Bumped whenever the step vocabulary or the locate protocol changes. Reported in
|
||||
# the heartbeat so the dashboard can say "restart your runner" instead of letting
|
||||
# a stale process fail on a step type it has never heard of.
|
||||
VERSION = "0.11.0"
|
||||
VERSION = "0.12.0"
|
||||
|
||||
# Shared with the heartbeat thread: whether a run is currently executing.
|
||||
_busy = threading.Event()
|
||||
@@ -341,6 +341,11 @@ def main() -> int:
|
||||
print("error: pyautogui is not installed — run: pip install -r requirements.txt", file=sys.stderr)
|
||||
return 1
|
||||
|
||||
# Before anything asks the OS how big the screen is. No-op off Windows.
|
||||
dpi = focus.enable_dpi_awareness()
|
||||
if dpi:
|
||||
print(f" {dpi}")
|
||||
|
||||
dash = Dashboard(opts.api)
|
||||
print(f"Runner watching {opts.api}" + (" [DRY RUN — nothing will be pressed]" if opts.dry_run else ""))
|
||||
print("Waiting for a run. Press a button on the AutoBuyer page. Ctrl-C to stop.")
|
||||
|
||||
Reference in New Issue
Block a user