Projekt

Allgemein

Profil

300 Python-Fehler und Debug » Historie » Version 7

[S] Dominik G, 13.06.2019 09:26

1 1 [X] Daniel S
h1. Python-Fehler und Debug
2 2 [X] Daniel S
3 3 [E] Frank S
* Im Formdesigner-Menü oder im RTF-Dropdown das Debugging für Python aktivieren (als Admin oder in Develop-Systemen ist das Menü zu sehen)
4
* Die entstehende Python-Datei auf dem Desktop speichern (die Scripte und das Result sind auch im %TEMP%-Verzeichnis bis zum Programmende abgelegt)
5 2 [X] Daniel S
6
* Mit Editor die Python-Datei öffnen
7
* Auf der Konsole die Python Datei ausführen
8
9
> im folgenden Bsp habe ich die fehlerhafte Datei in Notepad bearbeitet und anschliessend wieder gestestet, mit positiviem Ergebnis > ich habe das Script wieder in PRODAT übertragen.
10 4 [X] Marcus F
{{collapse(Beispiel)
11 2 [X] Daniel S
<pre>
12
D:\>ProdatERP\CNC\Prodat\python\python.exe C:\Users\ProdatAdmin\Desktop\27.py
13
Traceback (most recent call last):
14
  File "C:\Users\ProdatAdmin\Desktop\27.py", line 31, in <module>
15
    Sql.sql_add(Sql.add_and('mpl_formonth', edyear+combomonth))
16
TypeError: cannot concatenate 'str' and 'int' objects
17
18
D:\>ProdatERP\CNC\Prodat\python\python.exe C:\Users\ProdatAdmin\Desktop\27.py
19
20
 WHERE
21
 (mpl_minr) LIKE ('60')
22
 AND
23
(mpl_formonth) LIKE ('201800')
24
ORDER BY mpl_minr, mpl_date, bd_anf
25
26
D:\>
27 1 [X] Daniel S
</pre>
28 4 [X] Marcus F
}}
29
30 7 [S] Dominik G
31 5 [X] Marcus F
h2. F2 Suchen sind random falsch
32
33 4 [X] Marcus F
* F2 für RTF-Felder sind absichtlich nicht eindeutig (siehe #12624)
34 6 [X] Marcus F
** heißt das Feld im RTF gleich, werden automatisch die F2-Suchen dazugeholt
35 7 [S] Dominik G
** Ermittlung von bereits vorhandenen F2-Feldnamen mit entspr. Suche: https://redmine.prodat-sql.de/projects/prodat-v-x/wiki/Weitere_SQL-Statements (Punkt _bestehende F2 für RunTimeForms suchen_)