fix: preserve unknown assets and retained export-copy ownership
This commit is contained in:
1 parent
55a82fdc5f
commit
f21781f170
8 files changed
+312
-10
No files matched your search
@@ -15,11 +15,14 @@ from uuid import uuid4
|
||||
def assert_native_idle():
|
||||
import win32com.client
|
||||
from .native_management import _retained_workers
|
||||
from .native_export_guard import assert_retained_exports_idle
|
||||
from .native_engineering_identity import _OWNER_NAMES
|
||||
assert_retained_exports_idle()
|
||||
if any(worker.poll() is None for worker in _retained_workers):
|
||||
raise ValueError('MAINTENANCE_OWNER_ACTIVE: 管理工作进程尚未返回')
|
||||
names = ('ExpeditionPCB.exe', 'LibraryManager.exe', 'viewdraw.exe', 'iCDBProjectBackup.exe',
|
||||
'ReuseBlockImporter.exe', 'CleanWGLib.exe', 'cscript.exe', 'wscript.exe',
|
||||
'python.exe', 'pythonw.exe', 'CbbRefreshVerify.exe')
|
||||
'python.exe', 'pythonw.exe', 'CbbRefreshVerify.exe', *sorted(_OWNER_NAMES))
|
||||
service = win32com.client.GetObject('winmgmts:')
|
||||
query = 'SELECT ProcessId, Name, CommandLine FROM Win32_Process WHERE ' + ' OR '.join(
|
||||
f"Name='{name}'" for name in names)
|
||||
|
||||
Reference in new issue
Block a user