Closed St007 closed 6 years ago
I currently test only on octopi so some paths might be different there.
After install I can't open klipper config (it is just empty)
You can change the path the plugin is looking for the "printer.cfg" in the settings.
all settings in plugin empty
That I can't explain atm. The emergency macro exists but the "GCODE" field is empty? Can you create new macros and are they persistent if you save the settings?
However Performance Graph is empty too (no files in dropdown file selector)
The plugin looks for logfiles in /tmp/ namped klippy.log* are they also located there for your install?
In any case it would help if you could post an octoprint.log. On a standard octopi installation this is located at "/home/pi/.octoprint/logs/octoprint.log"
In a standard install, the klippy.log ist found here: /tmp/klippy.log I also don't get no filechoice for the perfgraph! Cheers Armin
more details:
In a standard install, the klippy.log ist found here: /tmp/klippy.log I also don't get no filechoice for the perfgraph!
That is interesting. Could you verify that you have logs in /tmp/ at the moment. If so reload you octoprint in the browser as the listing is only done once when loading the page at the moment
As I can see from logs '/home/pi/printer.cfg' is hardcoded ? and it causes crash on loading settings routine ?
@St007
It is not hardcoded you can configure the path in the Plugins settings in the UI under Klipper/Basic/Klipper Config Path
Yes, I can add the path, but it just not works ...not sure if it is hard to detect current user's home path and look for printer.cfg there instead of trying to load '/home/pi/printer.cfg'
Yes that would be possible an absolute path seemed more flexible. Last thing you could try after checking whether the path displayed in the UI is correct is to restart Octoprint as the settings are only read on startup at the moment.
Yes, the path in settings exists after Octoprint restart, that was the first I tried to do :)
I'm trying to reproduce the issue. What is your actual path?
actual path /home/slv/printer.cfg I guess it is in octoprint log too
actual path /home/slv/printer.cfg I guess it is in octoprint log too
No in the log it is still looking for "/home/pi/printer.cfg" which is the default
If you're still willing to debug some more you could check your Octoprint config file. For me this is located at ~/.octoprint/config.yaml That is where the plugin stores its settings. There should be an entry:
klipper:
_config_version: 2
configuration:
path: /home/slv/printer.cfg
klipper:
_config_version: 2
softwareupdate:
_config_version: 6
check_providers:
fanspeedslider: fanspeedslider
klipper: klipper
printerProfiles:
default: _default
serial:
additionalPorts:
- /tmp/printer
autoconnect: true
disconnectOnErrors: false
port: /tmp/printer
server:
firstRun: false
onlineCheck:
enabled: true
pluginBlacklist:
enabled: true
OK. I think I can reproduce the issue know. It's a bug. As a quick fix you could manually add the correct path to the config.yaml then the rest of the default config should load as well. I will provide a bugfix release soon.
klipper:
_config_version: 2
configuration:
path: /home/slv/printer.cfg
The release will include the possibility to configure the path for the klipper logfiles. Where are they located for your install?
klipper log file is in its default location /tmp/klippy.log
OK. Thanks for the debug session.
Thank you for great plugin!
Sorry for late reply, on business trip. I installed 0.2.2 today (after upgrading pip). I have the klippy.log in /tmp . Still, I don't get any file displayed in the choice for the log file. I restarted octoprint. No change.
Cheers Armin
Please post a octoprint.log otherwise I can't really diagnose the problem.
octoprint.log This is my last log.
Hi Armin, I can't find anything at the moment. The log is very long and I dont know when the dialog was opened. It would be great if you could delete you local log file so that a new one is created by octoprint. Then please restart octoprint, open the graph dialog and hit the refresh button for the file listing. Then post this log. Is everything else working? Especially can you view the Klipper Configuration in the settings dialog?
octoprint(1).log Done! Everything else including editing Klipper configuration works fine.
Hmm. Looks clean.
Given you have shell access to the pi we can directly execute the commands I use to list the log files. In a shell execute the following:
ls -l /tmp/*log.* # list all log files in the temp dir to make sure files a there.
cd # to go to the user directory
source oprint/bin/activate # activate the virtual environment used by octoprint
python # launch a python console
import glob
glob.glob("/tmp/*.log*")
The last command should list all klippy logfiles in the directory.
If that works the server side works and the problems must be the Browser. Which Browser are you using btw. ?
2018-08-17 20:56:49,291 - tornado.access - WARNING - 403 POST /api/plugin/klipper (::ffff:192.168.1.40) 45.13ms 2018-08-17 20:56:55,689 - tornado.access - WARNING - 403 POST /api/plugin/klipper (::ffff:192.168.1.40) 48.96ms 2018-08-17 20:56:57,211 - tornado.access - WARNING - 403 POST /api/plugin/klipper (::ffff:192.168.1.40) 44.05ms 2018-08-17 20:56:58,707 - tornado.access - WARNING - 403 POST /api/plugin/klipper (::ffff:192.168.1.40) 45.99ms
Looks like the webserver denies access. Just to check, I tried both nodes on octoprint: access control enabled and disabled. No change...
Hm good catch missed that one :-) Is the octoprint user you have currently logged in "Admin"?
ls -l /tmp/*log.*
doesn't work!
ls: cannot access '/tmp/*log.*': No such file or directory
if I change it to
ls -l /tmp/*log
I get
-rw-r--r-- 1 pi pi 8596690 Aug 17 21:03 klippy.log
cd pi@octopi:~ $ source oprint/bin/activate (oprint) pi@octopi:~ $ python Python 2.7.13 (default, Nov 24 2017, 17:33:09) [GCC 6.3.0 20170516] on linux2 Type "help", "copyright", "credits" or "license" for more information.
import glob glob.glob("/tmp/*log") ['/tmp/klippy.log']
So maybe typo in the wildcard-selection?
Using Firefox btw.
I wrote "ls -l /tmp/*log.*" and glob.glob("/tmp/*.log*")
Aber an dem liegt's wohl eher nicht! Ich geh mal ins Bett! Bis morgen!
Bis dann ich denke mal nochmal nach ... :-)
Du hast aber oben tatsächlich
ls -l /tmp/*log.*
geschrieben!
Guck mal!
Kein Stress übrigens. Das Plugin läuft sonst super! Macht deutlich mehr Spaß mit Klipper jetzt! Danke dafür!
Denke ich weiß inzwischen warum es bei mir funktioniert und bei dir nicht. Denke kann das morgen abend fixen.
Mit dem neuen release 0.2.3 sollte es funktionieren. lg Martin
Sehr geil! Danke Dir! Es druckt gerade - danach teste ich sofort!
Klappt!! Sauber!
Installed plugin on Octoprint Version 1.3.9, Klipper Firmware version: v0.6.0-339-g3f59c3d Running on latest Armbian. After install I can't open klipper config (it is just empty), all settings in plugin empty, default emergency stop macro empty too. The only thing working - panel buttons like "get status", "firmware restart". However Performance Graph is empty too (no files in dropdown file selector)