Toggle navigation
Toggle navigation
This project
Loading...
Sign in
万朱浩
/
Venue-Ops
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
way
2025-12-10 14:19:23 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
3c0067abe69a26654c516fcfe32ca22ded9f5a7d
3c0067ab
1 parent
160d1e52
fix: 修复扫描GTK安装路径时,当硬盘不存在/加密时,程序会报错退出
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
3 deletions
ReportEngine/utils/dependency_check.py
ReportEngine/utils/dependency_check.py
View file @
3c0067a
...
...
@@ -145,9 +145,15 @@ def _ensure_windows_gtk_paths():
common_names
=
[
"GTK3-Runtime Win64"
,
"GTK3-Runtime Win32"
,
"GTK3-Runtime"
]
for
drive
in
common_drives
:
root
=
Path
(
f
"{drive}:/"
)
for
name
in
common_names
:
default_dirs
.
append
(
root
/
name
)
default_dirs
.
append
(
root
/
"DevelopSoftware"
/
name
)
# 检测路径是否存在并可访问
try
:
if
root
.
exists
():
for
name
in
common_names
:
default_dirs
.
append
(
root
/
name
)
default_dirs
.
append
(
root
/
"DevelopSoftware"
/
name
)
except
OSError
as
e
:
# print(f'盘{drive}不存在或被加密,已跳过')
pass
# 扫描 Program Files 下所有以 GTK 开头的目录,适配自定义安装目录名
for
root
in
(
program_files
,
program_files_x86
):
...
...
Please
register
or
login
to post a comment