Internal Server Error - not going away

Hey hey,

Big fan here; thank you for an awesome product! I’m sorry to inform you that I could not use Karmen since this morning at all. Everything seems normal but then a grey overlay pops up and it won’t go away. It says the developers have been notified, but I hope my view might help to debug it better and expedite the solution.

All the best,
A

image

Hey Adam,

Thanks for letting us know. We have been updating our servers, and as we investigated the issue, we found that it was related to one of our backend servers, which caused the problem. As of now, we are not aware of any other issues. Please let us know if everything is alright.

Nevertheless, we will improve the error notification mechanism to better inform users when such situations occur. We are also actively monitoring all our infrastructure 24/7 and doing everything possible to prevent such error states.

Thanks again for bringing this to our attention.

Best,
Martin

1 Like

After further investigation, we have identified a bug that caused the error you reported. We will fix it as soon as possible and keep you informed of the progress.

Additional information: The bug is related to the camera stream. When it is configured in a way that we did not anticipate, it triggers an error. This issue only affects a small number of users with specific configurations, which is why I overlooked it initially.

Thank you once again for bringing this to our attention!

Martin

Thank you a million for looking into it so quickly. It means the world to me. I understand it might be related to my specific Octoprint setup on custom HW with the USB camera and self-configured stream. If you need any assistance on my part, do not hesitate to let me know!

A

1 Like

I have received information from our developers that it is clear to them where the problem lies. It is specific to your configuration, where we do not expect an absolute URL for the camera stream. We will fix it soon and inform you accordingly.

Please refrain from changing the camera URL in Octoprint until we resolve the issue, as we would like to use you as a tester later on. :blush:

Thank you,
Martin

Roger that! Thank you again for looking into it. I’ll let you know when it starts working again.

Cheers,
A

Hi Adam,

I’m developer of Karmen. I have investigated the bug and fixed it in our
code (which is currently in the testing phase). Unfortunately, this fix will
not solve your issue due to security reasons (which I will explain later).
However, I believe you can resolve it by changing the configuration of your
printer.

I see two options for reconfiguring Octoprint to allow Karmen to see the
printer:

  • If the camera snapshot can be acquired from the same device where the
    Websocket Proxy/Octoprint runs, simply change the snapshot hostname to
    127.0.0.1.

  • If the URL of the camera snapshots leads to a different device with its own
    IP address, you can set up a proxy on the Websocket Proxy/Octoprint device to
    forward snapshot requests to the camera.

Please let me know if you were able to solve the issue.

Explanation:

First, let me explain the root of the problem. Your printer software is
configured to use a camera snapshots URL that points to an address in your
local network. This configuration is correct and works fine as long as you are
on the same local network as the camera. On the other hand, Karmen is located
in a different network and can only connect to the machine where the Websocket
Proxy or Octoprint plugin runs, not to other devices on your local network.
This intentional decision adds a layer of security. If someone were to gain
access to your Karmen-generated printer key, they would only be able to connect
to your printer. If we were to extend that access to the entire local network,
it would create an unnecessary vulnerability that could be exploited by an
attacker who somehow gained access to the key.

Cheers,
Robin

@adam bump

Did it help? Please, let us know :innocent:

Hey hey,

I’m sorry for the radio silence. It works and it makes sense. Thank you for making me understand how the Octoprint camera/webcam setup and the Karmen Octoprint plugin work. I assume Karmen Camera Preview is actually using the Timelapse snapshot command, as seen in the Timelapse Recordings not the webcam stream.

I’d just stress that the setting that needs to be changed is “OctoPrint Settings > Webcam & Timelapse > Timelapse Recordings > Snapshot URL

Thanks for you feedback!

I can see that you have 10.1.0.112:8080 in your Stream URL. It should be 127.0.0.1:8080. Karmen plugin doesn’t support network connections that don’t meet the criteria of *localhost* or *127.0.0.1* - for security reasons.

So, if I understand correctly, video works for you now?

Best,
Martin