From c628a4e0e8ee7fd1a6615a339c8cbbffa5a5b8f3 Mon Sep 17 00:00:00 2001 From: tsuky_chen <91684733+chenjix@users.noreply.github.com> Date: Wed, 13 Dec 2023 00:05:43 +0800 Subject: [PATCH] debug dragTo --- desktop_env/controllers/python.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/desktop_env/controllers/python.py b/desktop_env/controllers/python.py index d422003..2b0dfb7 100644 --- a/desktop_env/controllers/python.py +++ b/desktop_env/controllers/python.py @@ -143,7 +143,7 @@ class PythonController: if "x" in parameters and "y" in parameters: x = parameters["x"] y = parameters["y"] - self.execute_python_command(f"pyautogui.dragTo({x}, {y}, button='left')") + self.execute_python_command(f"pyautogui.dragTo({x}, {y}, duration=1.0, button='left', mouseDownUp=True)") elif action_type == "SCROLL": # todo: check if it is related to the operating system, as https://github.com/TheDuckAI/DuckTrack/blob/main/ducktrack/playback.py pointed out