[FIX] Python-Interpreter fuer Export robust ermitteln + Sprachtexte

Unter Windows 11 traf ein blankes "python" den WindowsApps-Platzhalter
(kein echter Interpreter, Exitcode 49). Der Export schrieb die JSON, aber
nie eine CSV - ohne jede Fehlermeldung, da "fire and forget" per startapp.

- export:python-exe: Aufloesungsreihenfolge cfg/export.cfg [python]
  interpreter= -> DXFM_PYTHON -> Projekt-venv -> %SystemRoot%/py.exe ->
  "python"; WindowsApps-Platzhalter werden verworfen
- export:run-python: synchroner Aufruf per WScript.Shell.Run, stdout/stderr
  nach DXFM_LOG/export_python.log, Exitcode-Auswertung
- export:log-ausgeben: erste Logzeilen in die BricsCAD-Kommandozeile
- setenv.bat setzt DXFM_PYTHON (venv oder py-Launcher)
- cfg/export.cfg: neue Sektion [python]
- lang/de_DE.json, lang/en_GB.json: neue Meldungstexte (exp-python-exe,
  exp-export-done, exp-python-error, exp-python-store-hint, exp-csv-missing,
  exp-python-call-failed)

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-07-29 12:05:54 +02:00
parent f2b72df6e0
commit 88fc00a5c0
5 changed files with 180 additions and 7 deletions
+6
View File
@@ -500,6 +500,12 @@
"exp-calling-python": "\n[%1] Calling Python...",
"exp-export-started": "\n[%1] Export started: %2",
"exp-python-not-found": "\n[%1] ERROR: Python script not found: %2",
"exp-python-exe": "\n[%1] Interpreter: %2",
"exp-export-done": "\n[%1] Export finished: %2",
"exp-python-call-failed": "\n[%1] ERROR: Could not start Python (WScript.Shell unavailable).",
"exp-python-error": "\n[%1] ERROR: Python exited with code %2. Log: %3",
"exp-python-store-hint": "\n NOTE: No real Python interpreter was found (on Windows 11 'python' points\n to the WindowsApps placeholder). Fix: run bin/install_py.bat (creates .venv)\n and restart BricsCAD via bin/start_briscad.bat, or set the full path to\n python.exe in cfg/export.cfg under [python] interpreter=.",
"exp-csv-missing": "\n[%1] ERROR: Python reported success but the CSV is missing: %2. Log: %3",
"exp-omni-no-inserts": "\n[OMNI_UPDATE] No INSERT blocks in the drawing.",
"exp-omni-updated": "\n[OMNI_UPDATE] %1 elements updated (HEIGHT, ROTATION).",
"id-new-assigned": "\n[ID] New ID assigned: %1",