computer-use-ootb-internal 0.0.194__tar.gz → 0.0.195__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/PKG-INFO +1 -1
  2. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/pyproject.toml +1 -1
  3. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/app_teachmode.py +34 -21
  4. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/.gitignore +0 -0
  5. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/README.md +0 -0
  6. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/__init__.py +0 -0
  7. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/animation/click_animation.py +0 -0
  8. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/animation/icons8-select-cursor-transparent-96.gif +0 -0
  9. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/animation/test_animation.py +0 -0
  10. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/executor/teachmode_executor.py +0 -0
  11. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/gui_agent/gui_parser/simple_parser/__init__.py +0 -0
  12. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/gui_agent/gui_parser/simple_parser/gui_capture.py +0 -0
  13. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/gui_agent/gui_parser/simple_parser/utils.py +0 -0
  14. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/gui_agent/gui_parser/uia_tools/__init__.py +0 -0
  15. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/gui_agent/gui_parser/uia_tools/screenshot_cli.py +0 -0
  16. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/gui_agent/gui_parser/uia_tools/screenshot_service.py +0 -0
  17. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/gui_agent/llm_utils/llm_utils.py +0 -0
  18. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/gui_agent/llm_utils/oai.py +0 -0
  19. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/gui_agent/llm_utils/run_litellm.py +0 -0
  20. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/gui_agent/llm_utils/run_llm.py +0 -0
  21. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/tools/__init__.py +0 -0
  22. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/tools/aws_request.py +0 -0
  23. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/tools/base.py +0 -0
  24. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/tools/bash.py +0 -0
  25. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/tools/collection.py +0 -0
  26. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/tools/colorful_text.py +0 -0
  27. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/tools/computer.py +0 -0
  28. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/tools/computer_marbot.py +0 -0
  29. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/tools/edit.py +0 -0
  30. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/tools/run.py +0 -0
  31. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/computer_use_demo/tools/screen_capture.py +0 -0
  32. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/dependency_check.py +0 -0
  33. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/guard_service.py +0 -0
  34. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/preparation/__init__.py +0 -0
  35. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/preparation/excel_prepare.py +0 -0
  36. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/preparation/powerpoint_prepare.py +0 -0
  37. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/preparation/pr_prepare.py +0 -0
  38. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/preparation/star_rail_prepare.py +0 -0
  39. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/preparation/word_prepare.py +0 -0
  40. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/requirements-lite.txt +0 -0
  41. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/run_teachmode_ootb_args.py +0 -0
  42. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/service_manager.py +0 -0
  43. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/signal_connection.py +0 -0
  44. {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/test_autogui.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: computer-use-ootb-internal
3
- Version: 0.0.194
3
+ Version: 0.0.195
4
4
  Summary: Computer Use OOTB
5
5
  Author-email: Siyuan Hu <siyuan.hu.sg@gmail.com>
6
6
  Requires-Python: >=3.11
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "computer-use-ootb-internal"
7
- version = "0.0.194"
7
+ version = "0.0.195"
8
8
  description = "Computer Use OOTB"
9
9
  authors = [{ name = "Siyuan Hu", email = "siyuan.hu.sg@gmail.com" }]
10
10
  requires-python = ">=3.11"
@@ -26,48 +26,61 @@ import asyncio
26
26
 
27
27
  # --- App Logging Setup ---
28
28
  try:
29
- # Log to user's AppData directory for better accessibility
30
- log_dir_base = os.environ.get('APPDATA', os.path.expanduser('~'))
31
- log_dir = os.path.join(log_dir_base, 'OOTBAppLogs')
32
- os.makedirs(log_dir, exist_ok=True)
29
+ # NEW: Log to a subdirectory under ProgramData/OOTBGuardService, specific to the current user
30
+ program_data_dir = os.environ.get('PROGRAMDATA', 'C:/ProgramData') # Use C:/ProgramData as a fallback
31
+ guard_service_log_base_dir = os.path.join(program_data_dir, 'OOTBGuardService')
32
+
33
+ current_username = os.getenv('USERNAME', 'unknown_user_app') # Get current username, fallback
34
+ app_logs_subfolder = "UserSessionLogs" # Subfolder for these app logs
35
+
36
+ log_dir = os.path.join(guard_service_log_base_dir, app_logs_subfolder, current_username)
37
+
38
+ os.makedirs(log_dir, exist_ok=True) # Create user-specific log directory
33
39
  log_file = os.path.join(log_dir, 'ootb_app.log')
34
40
 
35
41
  log_format = '%(asctime)s - %(levelname)s - %(process)d - %(threadName)s - %(message)s'
36
42
  log_level = logging.INFO # Or logging.DEBUG for more detail
37
43
 
38
- # Use rotating file handler
39
- handler = RotatingFileHandler(log_file, maxBytes=5*1024*1024, backupCount=2, encoding='utf-8')
40
- handler.setFormatter(logging.Formatter(log_format))
44
+ # Setup the rotating file handler
45
+ rotating_file_handler = RotatingFileHandler(log_file, maxBytes=5*1024*1024, backupCount=2, encoding='utf-8')
46
+ rotating_file_handler.setFormatter(logging.Formatter(log_format))
41
47
 
42
- # Configure root logger
43
- logging.basicConfig(level=log_level, handlers=[handler])
44
-
45
- # Add stream handler to see logs if running interactively (optional)
46
- # logging.getLogger().addHandler(logging.StreamHandler(sys.stdout))
48
+ # Setup the console handler
49
+ console_handler_for_basic_config = logging.StreamHandler(sys.stdout)
50
+ console_handler_for_basic_config.setFormatter(logging.Formatter(log_format))
47
51
 
52
+ # Configure root logger with both file and console handlers
53
+ # This replaces the old basicConfig and the subsequent addHandler calls for file and console
54
+ logging.basicConfig(level=log_level, handlers=[rotating_file_handler, console_handler_for_basic_config])
55
+
48
56
  logging.info("="*20 + " OOTB App Starting " + "="*20)
57
+ logging.info(f"Logging to file: {log_file}") # Explicitly log the path
49
58
  logging.info(f"Running with args: {sys.argv}")
50
59
  logging.info(f"Python Executable: {sys.executable}")
51
60
  logging.info(f"Working Directory: {os.getcwd()}")
52
- logging.info(f"User: {os.getenv('USERNAME')}")
61
+ logging.info(f"User: {current_username}") # Log the username being used for the path
53
62
 
54
63
  except Exception as log_setup_e:
55
64
  print(f"FATAL: Failed to set up logging: {log_setup_e}")
56
- # Fallback logging might be needed here if file logging fails
65
+ traceback.print_exc() # Print traceback for debugging log setup failure
57
66
 
58
67
  # --- Get the root logger ---
68
+ # The root logger is now fully configured by basicConfig above.
69
+ # The following sections for re-adding file handler and console handler are no longer needed.
59
70
  root_logger = logging.getLogger()
60
- root_logger.setLevel(log_level) # Ensure root logger level is set
71
+ # root_logger.setLevel(log_level) # This was redundant as basicConfig sets the level.
61
72
 
62
73
  # --- File Handler (as before) ---
63
- file_handler = RotatingFileHandler(log_file, maxBytes=5*1024*1024, backupCount=2, encoding='utf-8')
64
- file_handler.setFormatter(logging.Formatter(log_format))
65
- root_logger.addHandler(file_handler)
74
+ # REMOVED - This was redundant as rotating_file_handler is now passed to basicConfig.
75
+ # file_handler = RotatingFileHandler(log_file, maxBytes=5*1024*1024, backupCount=2, encoding='utf-8')
76
+ # file_handler.setFormatter(logging.Formatter(log_format))
77
+ # root_logger.addHandler(file_handler)
66
78
 
67
79
  # --- Console Handler (New) ---
68
- console_handler = logging.StreamHandler(sys.stdout) # Log to standard output
69
- console_handler.setFormatter(logging.Formatter(log_format))
70
- root_logger.addHandler(console_handler)
80
+ # REMOVED - This was redundant as console_handler_for_basic_config is now passed to basicConfig.
81
+ # console_handler = logging.StreamHandler(sys.stdout) # Log to standard output
82
+ # console_handler.setFormatter(logging.Formatter(log_format))
83
+ # root_logger.addHandler(console_handler)
71
84
 
72
85
  # --- End App Logging Setup ---
73
86