gplot readonly

Begonnen von fhemfrederik, 15 September 2022, 21:27:04

Vorheriges Thema - Nächstes Thema

fhemfrederik

Liebe alle,

wenn ich mit 

Define MyPlot SVG SQLLog:MyPlot:HISTORY

einen Plot erzeuge, ist er readonly.
Angeblich soll set MyPlot CopyGplotFile helfen.
Ich erhalte allerdings "this is already a unique gplot file".

Hat jemand ein Tipp?

Viele Grüße
Frederik


rudolfkoenig

Die Meldung besagt, dass in der /opt/fhem/www/gplot/MyPlot.gplot Datei eine Anweisung "set readonly" existiert.
Ich wuerde diese Zeile mit dem Editor oder ueber "FHEMWEB/Edit Files" entfernen.

fhemfrederik

Danke für die schnelle Antwort.
Allerdings wird bei mir keine Datei angelegt. (mehrfach geprüft).
Ältere Plots sind da und funktionieren auch problemlos.

rudolfkoenig

ZitatAllerdings wird bei mir keine Datei angelegt. (mehrfach geprüft).
Rechteproblem auf Betriebsystemebene?

fhemfrederik

Der Prozess läuft unter fhem und der User ist Owner auf dem Ordner.
Vorhandene Files kann ich über das Web-Frontend editieren.
Scheint mir was anderes zu sein, oder?

fhemfrederik

#5
ich habe die gplot-Datei durch Kopieren einer vorhandenen Datei erstellt. Jetzt kann ich wieder editieren.
Merkwürdig ist das Verhalten allerdings schon!

ergerd

Exakt das Verhalten habe ich auch.
Grüße
ergerd
FHEM auf RasPi 4, CUNO, ZigBee, 1Wire2WLAN, DS2423, C-Control II, Buderus KM200, LaCrosseGateway, PCA301, ConBee II, LuftdatenInfo, OneWireGW, Div. ESPs u. Shellys

betateilchen

ich schaffe es nicht, das beschriebene Verhalten mit dem hier eingangs beschriebenen Weg zu reproduzieren...
-----------------------
Formuliere die Aufgabe möglichst einfach und
setze die Lösung richtig um - dann wird es auch funktionieren.
-----------------------
Lesen gefährdet die Unwissenheit!

ryonchev

#8
Entschuldigung aber auf English:

The same problem here.
After few attempts, I finally deleted manually the .gplot file (ssh to server and delete). After new definition the situation is the same. I noticed in the new definition "Internals section" - CFGFN is empty. I don't have such Internals reading on previously defined plots and they are working perfect.
I also tried to copy one of existing plots (close to what I want) - the result is the same - Read only .gplot file and this Internal CFGFN appears. In original object I copied - no such Internal reading.

Edit 1: New attempt - defining new plot and not saving config. .gplot file is read only. set <name> copyGplotFile says, this is already unique gplot file, but it is still readonly... It seems there is something wrong with the module after last update.

rudolfkoenig

I think I undestand now the problem: you are creating the SVG by manually typing "define svg SVG ...", and not by creating the SVG from a FileLog or DbLog.
This is not a common case, this is why I missed the point.
I fixed this, can you please give me feedback, if it works.

ryonchev

#10
I'm creating the plot from existing Log device:

define HWElHeater SVG Log_HotWater_El:SVG_HWElHeater:CURRENT

I just made update and restart but the result is the same. Or maybe I should download the file from different location?

Edit: And this is the definition of Log device::

Internals:
   DEF        ./log/HotWater_El-%Y-%m-%d.log MQTT2_HotWater_El.*
   FD         27
   FUUID      61bdf9f9-f33f-2f42-0f35-1e070e53ffe56298
   NAME       Log_HotWater_El
   NOTIFYDEV  MQTT2_HotWater_El.*
   NR         211
   NTFY_ORDER 50-Log_HotWater_El
   REGEXP     MQTT2_HotWater_El.*
   STATE      active
   TYPE       FileLog
   currentlogfile ./log/HotWater_El-2022-09-18.log
   logfile    ./log/HotWater_El-%Y-%m-%d.log
   READINGS:
     2022-09-18 17:49:47   linesInTheFile  58
   pos:
Attributes:
   icon       icoLog
   logtype    text
   nrarchive  1
   room       Server->FHEM

rudolfkoenig

By creating it from a FileLog device I meant clicking on "Create SVG plot" on the FileLog details page.
The FHEM update is available (as always) on the next day shortly before 8AM.
Until then you have to get it from the SVN, e.g. via https://svn.fhem.de/trac/browser/trunk/fhem

ryonchev

#12
Yes you are correct. If I create the plot by opening the Log device and clicking on Create SVG plot - everything works perfect.
However I don't see any reason to do that if already have similar plot and just copy it under different name, change the plot file name, and change the field(s) I want to plot. Much more faster than making everything from scratch.
Will download the new module and will give you feedback.

Thank you for the fast reaction.

Just got the module from https://svn.fhem.de/trac/browser/trunk/fhem

The output is (after restart, but the same on reload...):

2022.09.18 18:27:06 3: MBrocker: port 1883 opened
2022.09.18 18:27:06 1: reload: Error:Modul 98_SVG deactivated:
syntax error at ./FHEM/98_SVG.pm line 8, near "<"
Unknown regexp modifier "/t" at ./FHEM/98_SVG.pm line 9, at end of line
Unknown regexp modifier "/t" at ./FHEM/98_SVG.pm line 9, at end of line
Unknown regexp modifier "/e" at ./FHEM/98_SVG.pm line 9, at end of line
syntax error at ./FHEM/98_SVG.pm line 15, near "-->"
syntax error at ./FHEM/98_SVG.pm line 33, near "$(".trac-autofocus""
syntax error at ./FHEM/98_SVG.pm line 34, near "$(".trac-target-new""
syntax error at ./FHEM/98_SVG.pm line 35, near ") {"
syntax error at ./FHEM/98_SVG.pm line 36, near "$(".trac-disable-on-submit""
syntax error at ./FHEM/98_SVG.pm line 39, near ""text/javascript" src"
./FHEM/98_SVG.pm has too many errors.


Edit: I reverted to the old version of the module, created the plot from Create SVG plot and finished what I wanted. However it is good to think for the above, since sometimes it is easier to copy or manually create the graphs. Thank you for the support. Will try of course the module after next update and will give you feedback.

rudolfkoenig

The output is (after restart, but the same on reload...):
Should not happen if you download the file via the "Original Format" link, to be found at the bottom of the page.

ryonchev

#14
ok. Thank you again for the support. Probably I didn't do it correct.

Edit: I can confirm now everything works correct and perfect - manual definition as well as copying existing plot.

Thank you for the support.

Edit 2: Danke, Danke schoen