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.
- {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/PKG-INFO +1 -1
- {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/pyproject.toml +1 -1
- {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/app_teachmode.py +34 -21
- {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/.gitignore +0 -0
- {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/README.md +0 -0
- {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/__init__.py +0 -0
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {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
- {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/dependency_check.py +0 -0
- {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/guard_service.py +0 -0
- {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/preparation/__init__.py +0 -0
- {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
- {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
- {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
- {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
- {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
- {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/requirements-lite.txt +0 -0
- {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
- {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/service_manager.py +0 -0
- {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/signal_connection.py +0 -0
- {computer_use_ootb_internal-0.0.194 → computer_use_ootb_internal-0.0.195}/src/computer_use_ootb_internal/test_autogui.py +0 -0
@@ -26,48 +26,61 @@ import asyncio
|
|
26
26
|
|
27
27
|
# --- App Logging Setup ---
|
28
28
|
try:
|
29
|
-
# Log to
|
30
|
-
|
31
|
-
|
32
|
-
|
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
|
-
#
|
39
|
-
|
40
|
-
|
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
|
-
#
|
43
|
-
logging.
|
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: {
|
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
|
-
#
|
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) #
|
71
|
+
# root_logger.setLevel(log_level) # This was redundant as basicConfig sets the level.
|
61
72
|
|
62
73
|
# --- File Handler (as before) ---
|
63
|
-
|
64
|
-
file_handler
|
65
|
-
|
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
|
-
|
69
|
-
console_handler.
|
70
|
-
|
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
|
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|