- Introduced new logging modules for action tracking, error logging, and performance tracking to improve observability. - Added functions for retrieving debug and error log paths in `path_config.py`. - Updated various components to utilize the new logging system, enhancing error handling and performance diagnostics. - Implemented a GUI component for viewing error logs, improving user experience in monitoring application issues. - Cleaned up unnecessary blank lines and improved code readability across multiple files.
47 lines
964 B
Python
47 lines
964 B
Python
"""底层操作模块
|
|
|
|
本目录包含从 Underlying_Operations.py 模块化后的操作模块。
|
|
"""
|
|
|
|
# 从子模块导入
|
|
from .ocr_operations import (
|
|
analyse_pic_word,
|
|
analyse_pic_digits,
|
|
extract_ocr_content,
|
|
_ensure_ocr,
|
|
)
|
|
from .screenshot_operations import (
|
|
get_screenshot,
|
|
_find_pic_path,
|
|
cut_pic,
|
|
save_reward_pic,
|
|
)
|
|
|
|
# 从原文件导入以保持向后兼容
|
|
# TODO: 逐步迁移后改为从子模块导入
|
|
from Underlying_Operations import (
|
|
_safe_replace_file,
|
|
_ensure_parent_dir,
|
|
_mirror_screenshot_to_external,
|
|
underlying_operations,
|
|
)
|
|
|
|
__all__ = [
|
|
# OCR相关
|
|
"analyse_pic_word",
|
|
"analyse_pic_digits",
|
|
"extract_ocr_content",
|
|
"_ensure_ocr",
|
|
# 截图相关
|
|
"get_screenshot",
|
|
"_find_pic_path",
|
|
"cut_pic",
|
|
"save_reward_pic",
|
|
# 其他操作
|
|
"_safe_replace_file",
|
|
"_ensure_parent_dir",
|
|
"_mirror_screenshot_to_external",
|
|
"underlying_operations",
|
|
]
|
|
|