Tips zur Fehlersuche....

Antworten
hhoefling
Beiträge: 631
Registriert: So Jul 25, 2021 2:32 pm

Tips zur Fehlersuche....

Beitrag von hhoefling »

Alle Entwickler die mit einem Windows PC als Entwicklungsumgebung arbeitet und ein Linux System als Zielsystem haben kennen das Probelm meist schon.

Trotzdem stolpert man immer wieder darüber.
Aktuell bin ich bei der openWB Version: 1.9.258 (2022-03-17 09:37:55 +0100 [56a4c7ef] darüber gestopert.
Folgendes Kommand auf dem Pi ausgeführt sollte eigendlich kein Ergebniss erzeugen

Code: Alles auswählen

find /var/www/html/openWB -name "*.sh" -o -name "*.py"  -exec file  {} \; | grep CRLF
Aktuell bekomme ich

Code: Alles auswählen

/var/www/html/openWB/modules/et_awattarcap/factors.py: ASCII text, with very long lines, with CRLF line terminators
/var/www/html/openWB/modules/et_awattarcap/awattarcapgetprices.py: Python script, UTF-8 Unicode text executable, with CRLF line terminators
/var/www/html/openWB/modules/soc_kia/soc.py: Python script, ASCII text executable, with CRLF line terminators
/var/www/html/openWB/modules/soc_kia/soc_external.py: Python script, ASCII text executable, with CRLF line terminators
/var/www/html/openWB/modules/soc_kia/kiahttp.py: Python script, ASCII text executable, with CRLF line terminators
/var/www/html/openWB/modules/soc_kia/state.py: Python script, ASCII text executable, with CRLF line terminators
/var/www/html/openWB/modules/soc_kia/abrp.py: Python script, ASCII text executable, with CRLF line terminators
/var/www/html/openWB/modules/soc_kia/kiaif.py: Python script, ASCII text executable, with CRLF line terminators
/var/www/html/openWB/modules/soc_kia/kiaauth.py: Python script, ASCII text executable, with very long lines, with CRLF line terminators
/var/www/html/openWB/modules/soc_kia/trigger.py: Python script, ASCII text executable, with CRLF line terminators
/var/www/html/openWB/modules/soc_carnet/we_connect_client.py: Python script, ASCII text executable, with very long lines, with CRLF line terminators
/var/www/html/openWB/packages/testutils/mock.py: Python script, ASCII text executable, with CRLF line terminators
z.b. die Datei /var/www/html/openWB/modules/soc_carnet/we_connect_client.py
Sie sieht mit cat /var/www/html/openWB/modules/soc_carnet/we_connect_client.py noch normal aus.
Aber der Versuch sie auszuführen ergibt:

Code: Alles auswählen

/var/www/html/openWB/modules/soc_carnet# ./we_connect_client.py
-bash: ./we_connect_client.py: /usr/bin/python^M: Defekter Interpreter: Datei oder Verzeichnis nicht gefunden
Einmal im Editor mit Unix-Zeilenschaltung abspeichern bereinigt das Problem.
gruss
Heinz

6kWp PV+Akku von RCT Power,+Tibber,+Shelly's
Skoda Citigo e-iV, openWB series2 standart+
mit openWB_lite (auf Basis der openWB 1.9.244+ Okt.2021)
Github: https://github.com/hhoefling/openWB_lite
LutzB
Beiträge: 3513
Registriert: Di Feb 25, 2020 9:23 am

Re: Tips zur Fehlersuche....

Beitrag von LutzB »

Antworten