Port 2V0 UI Python bindings and app module link surface
This commit is contained in:
@@ -502,3 +502,4 @@
|
||||
{"time": "2026-09-23T11:00:00Z", "event": "port_round", "unit": "PORT-PLAN 批次 2P step 4 (macOS): the 40250 script layer starts inside the Godot process", "ported": [], "adapted": ["UserInterface/UserInterface.cpp:RunMainScript -> extension/src/platform/ScriptLib/PythonBoot.cpp (Start/RunMainScript/RunLine/Stop; 40250 keeps CPythonLauncher on Main()'s stack, Godot owns this process so the launcher has to outlive the call that starts it)", "EterBase/Debug.cpp:LogBox, EterBase/Debug.cpp:LogBoxf -> extension/src/platform/EterBase/Debug.cpp (stderr plus LastLogBoxMessage(); ScriptLib Traceback() reports through LogBoxf after PyErr_Fetch has cleared the exception, so this is the only place a script traceback survives)"], "deleted": [], "divergent": ["RunMainScript RegisterCommandLine passes the command line through unchanged: the -cs/-ncs auto-login decoding needs EterBase/Utils.cpp SplitLine and EterLib/Util.cpp base64_decode, both declared but not ported (批次 2V1). Nothing in this host passes -cs today.", "RunMainScript drops '--pause-before-create-window' (system(\"pause\")) and the XTrap init check: no console and no XTrap on macOS/Android.", "Of the 37 module initializers RunMainScript calls, only initpack() is called — the other 36 are 2V slices."], "needs_live": [], "staging": {"native": "extension/src/platform/ScriptLib/PythonBoot.{h,cpp} (godot-free, placed under ScriptLib because that is the directory port_logic/port_platform drop when `mtpython` is absent; compiled with the UserInterface library's definitions so its `#ifdef _DISTRIBUTE` gives __DEBUG__ = 0). extension/src/platform/EterBase/LogBox.h. extension/src/python_host_node.{h,cpp} -> GDScript class Metin2PythonHost (start/is_running/run_main_script/run_line/stop; each returns \"\" or the reason, and a build without the interpreter answers with a distinguishable message instead of failing to register).", "gdscript": "project/python_host_check.gd in two halves — the interpreter + stdlib half needs no 40250 pack and runs on any platform, the system.py half needs the pack and is skipped without it. project/python_host_test.gd (--script) is the desktop entry; MT_TEST_MODE=python in project/client_main.gd is the on-device entry, since export templates do not accept --script.", "boot": "Metin2PythonHost.start(\"\") stages the stdlib through Metin2Python.stdlib_path(), which until now had no caller outside python_stdlib_test.gd."}, "status_note": "macOS only. Android/iOS in-process is untouched: the APK cross-build is blocked on the GBK iconv issue (see the PORT-PLAN known-issue section, deferred by the user 2026-09-23), and a device has no 40250 Client/pack, so on a phone only the interpreter + stdlib half of the check can run. prototype.RunApp() is 2V0: system.py still stops at its first import. The real boot path (AppFlow) does not start the interpreter.", "tests": ["godot --headless --path project --script python_host_test.gd -> PASS: interpreter starts in-process, is_running(), a second start() is a no-op, `import os, string, types, codecs`, u'\\xe4'.encode('cp1252'), sys.path non-empty, system.py stops at ImportError: No module named app (identical to ctest port.python_launcher), stop() tears it down", "MT_TEST_MODE=python godot --headless --path project -> same result through client_main.gd", "ctest --test-dir build -> 27/27 passed (14.51s)"], "not_done": "Android/iOS 进程内验证;正式启动路径起解释器(2V0);RunMainScript 的 -cs 命令行解码(2V1)", "commit": "2P-step4-macos"}
|
||||
{"time": "2026-09-23T11:40:00Z", "event": "port_round", "unit": "PORT-PLAN 批次 2V0-a: the EterPythonLib window-system headers enter the mirror", "ported": ["EterPythonLib/StdAfx.h", "EterPythonLib/PythonGraphic.h", "EterPythonLib/PythonWindow.h", "EterPythonLib/PythonWindowManager.h", "EterPythonLib/PythonSlotWindow.h", "EterPythonLib/PythonGridSlotWindow.h"], "adapted": [], "deleted": [], "divergent": [], "needs_live": [], "staging": {"scope": "headers only; no .cpp unit and therefore no port-map entry — declarations, nothing to call. The EterPythonLib .cpp units are 2V0-b.", "mechanical": "port_copy.py copy, 0 of 6 with manual edits: every one compiles as a mechanical CP949->UTF-8 / CRLF->LF / include-case copy.", "stdafx": "EterPythonLib/StdAfx.h had to come first: port_header_gate compiles each header behind its library's StdAfx.h, as 40250 does, and without it these five see neither <Python.h>, the STL, nor CSingleton.", "slice_list_correction": "audit/slices/2V0.json lists EterLib/Dimm.h as a missing header. It is not: 40250 vendors the MIDL output of the Windows SDK <dimm.h> as EterLib/Dimm.h, and extension/src/port/common/shim/win32/Dimm.h already shims it (a mirror copy shadows the shim for EterLib/IME.h's quoted include and breaks the build on 'rpc.h'). Copied, found, and removed again."}, "status_note": "2V0 entry state measured: of the slice's 212 headers 164 were already in the mirror, 48 were not (1 EterLib = the SDK shim above, 5 EterPythonLib = this round, 42 UserInterface = 2V0-d, all behind UserInterface/PythonApplication.h). Of the 10 units, 2 are ported (ScriptLib/PythonLauncher.cpp, UserInterface/PythonPackModule.cpp) and 8 are not.", "tests": ["cmake --build build --target port_header_gate -> the 6 new gate translation units compile (each header alone, twice, behind EterPythonLib/StdAfx.h)", "ctest --test-dir build -> 27/27 passed"], "not_done": "EterPythonLib/*.cpp(2V0-b);wndMgr/grp/grpImage/grpText 模块(2V0-c);42 个 UserInterface 头 + PythonApplicationModule.cpp(2V0-d)", "commit": "2V0-a"}
|
||||
{"time": "2026-09-23T02:17:52Z", "event": "port_round", "unit": "PORT-PLAN 批次 2V0-b: window tree completion and 64-bit LZO boundary repair", "ported": ["EterPythonLib/PythonWindow.cpp (211 functions)", "EterPythonLib/PythonWindowManager.cpp (76)", "EterPythonLib/PythonSlotWindow.cpp (80)", "EterPythonLib/PythonGridSlotWindow.cpp (14)", "EterLib/ReferenceObject.cpp (9)", "EterLib/Resource.cpp (18)", "EterLib/ResourceManager.cpp (25)"], "adapted": ["EterBase/lzo.cpp: CLZObject::Compress and CLZObject::Decompress use native-width lzo_uint at the liblzo API while retaining 32-bit pack-header lengths"], "divergent": [], "needs_live": [], "status_note": "The seven units in b4c9d6ce are exact mechanical copies of 40250 (0 manual edits); their 433 functions are recorded in port-map. The original port.window_tree test had four expectations contrary to 40250: DeactivateWindow restores the previous active window and SetTop changes update order; corrected the expectations. A fresh 64-bit build exposed stack corruption in the older LZO caller because Win32 UINT (4 bytes) was passed as native lzo_uint* (8 bytes); fixed the boundary. The normal app path still does not load the UI shell; module registration and rendering remain 2V0-c through 2V0-f.", "tests": ["port_copy.py diff on seven units: 0 manual edits", "ctest -R port.window_tree: pass", "ctest -R port.eterpack: pass, including added LZO compress/decompress round trip and full pack inventory", "ctest -R port.python_launcher: pass", "ctest --test-dir build --output-on-failure -j6: 28/28 pass", "port_map.py check: 0 errors"], "not_done": "2V0-c through 2V0-f; normal app startup and visible interactive Logo/Popup are the whole 2V0 acceptance gate, not the 2V0-b substep.", "commit": "2V0-b-completion"}
|
||||
{"time": "2026-09-23T02:57:22Z", "event": "port_round", "unit": "PORT-PLAN 2V0-c/d and beginning of 2V0-e", "ported": ["EterPythonLib/PythonWindowManagerModule.cpp", "EterPythonLib/PythonGraphicModule.cpp", "EterPythonLib/PythonGraphicImageModule.cpp", "EterPythonLib/PythonGraphicTextModule.cpp", "EterPythonLib/PythonGraphicThingModule.cpp", "UserInterface/PythonApplicationModule.cpp", "ScriptLib/PythonDebugModule.cpp", "42 UserInterface dependency headers"], "adapted": ["Python pointer handles via PyLong_FromVoidPtr/PyLong_AsVoidPtr (native pointer width)", "Win32 FindFirstFile/FindNextFile shim for app file enumeration", "Godot PythonBoot registers dbg, grp, grpImage, grpText, wndMgr and app and propagates dbg.LogBox failures"], "divergent": ["CPythonApplication platform lifecycle and graphics methods remain MT_PLATFORM_STUB; no visible Logo/Popup yet", "DevIL image and DirectShow logo backends remain MT_PLATFORM_STUB"], "tests": ["cmake --build build -> pass", "ctest --test-dir build --output-on-failure -j6 -> 29/29 passed, 1 skipped", "godot --headless --path project --script python_host_test.gd -> system.py reaches constInfo.py import net and reports ImportError through RunMainScript", "port_map.py check -> 0 errors"], "not_done": "2V0-e native gameplay module stubs and prototype.RunApp; 2V0-f Godot UI renderer/input/Logo/Popup runtime acceptance", "status_note": "The app binding imports, but its CPythonApplication adapter is only a link surface. The 2V0 acceptance gate is not yet met."}
|
||||
|
||||
Reference in New Issue
Block a user