kennethjiang / OctoPrint-Slicer

A full-blown GUI-based slicer plugin for OctoPrint
MIT License
99 stars 29 forks source link

no longer works on octoprint 1.6.0 #176

Closed lsellens closed 3 years ago

lsellens commented 3 years ago

Looks like 1.6.0 brings built in slicing which overrides this plugin. I'm not sure if a change needs to happen in this plugin or in octoprint to get it to function as expected once again. The built in slicing is just a pop up that lets you pick slicer and profile. No positioning or profile settings changes can be made. Screenshot_2021-04-28 OctoPrint

eyal0 commented 3 years ago

The change that you linked is from 2015. It's unlikely that this plugin has been broken for 6 years and no one noticed.

It ought to be pretty easy to bisect the issue, if there is one.

I can try to run this plugin with the latest version of OctoPrint and find which change broken this plugin, if there is one.

lsellens commented 3 years ago

Yeah forget about that change I linked. I apparently didn't get enough sleep last night. I rolled my octoprint back to 1.5.3 everything works as expected again. Just update to 1.6.0 and you'll see what I'm referring to.

kg333 commented 3 years ago

Same results here when updating to 1.6.0.

mmirate commented 3 years ago

The minified JS in this repo includes a copy of the babel polyfill. So does OctoPrint. As you may know, the babel polyfill may be instantiated only once per page-load. Hence, this plugin's JS throws an error and gives up.

mmirate commented 3 years ago

And, __plugin_load__ doesn't exist anymore in 1.6.0. Nope, sorry, I got that mixed up with __plugin__init__ which is what actually got blown away in 1.6.0.

eyal0 commented 3 years ago

As you may know

Actually, I know very little about this stuff! You'd be surprised.

Do you know how to fix this? Surely this is not the only plugin with such a problem!

mmirate commented 3 years ago

When compiling the JS, don't include babel, just rely on OctoPrint's instance of it.

I'd send in a PR myself, but I can't find the unminified sourcecode. Don't mind me, I'm stupid. PR is up.

rudy734 commented 3 years ago

Hello Will there be an update for Octo 1.6 ??

eyal0 commented 3 years ago

@foosel Are you familiar with this issue? It seems that the babel polyfill in this plugin conflicts with the polyfill that is now a part of OctoPrint.

Do other plugins have this problem? How are they solving this problem?

foosel commented 3 years ago

Not familiar, no. I also didn't get any reports about this during the RC phase, or after for that matter.

Moraxan commented 3 years ago

Hi!

I'm using this in my work as a teacher. My students use Chromebooks, and the slicing options on the platform are limitied. I've invested quite a lot of time to get octoprint and the slicer plugin to work and it did up until this version. From what I've read in this thread is that the slicer and another plugin needs to be updated in order to work with Octoprint 1.6. One solution for me is to downgrade to 1.5.x, but that doesn't give any sustainbility to the solution that worked until recently. I have 0 knowledge on plugin development, but I am willing to invest time in this for it to work. My questions are the following:

What needs to be done? Preferrably in order from easiest to hardest tasks.

Pointers on how to get those things done would be appreciated. I know some programming and debugging but is far from fluent in any language. I read code better than I write.

How do I get fail logs from Octoprint? I've looked in the settings, but haven't managed to find them. I guess that's the first place to start. To see why addons fail and then adress those problems in order.

eyal0 commented 3 years ago

The javascript ecosystem is the worst part of javascript. What a nightmare.

I've been trying to figure out how to make a version that will work for 1.6 and <1.6. I can do either/or very easily but making one that works for both is elusive.

kg333 commented 3 years ago

I've been trying to figure out how to make a version that will work for 1.6 and <1.6. I can do either/or very easily but making one that works for both is elusive.

Requiring a minimum of Octoprint 1.6 going forward seems reasonable. Using the latest plugin while unable to update Octoprint would be unusual.

eyal0 commented 3 years ago

Or I could try to strip out the polyfill. I don't know enough about javascript to do that.

lsellens commented 3 years ago

eyal0's PR works great for me. I'm back up and running on 1.6.0. Thanks!

eyal0 commented 3 years ago

@Moraxan Looks like new version will fix your problem. Try it out and let me know how it goes. Thank you for being a teacher. Let me know if I can be of further service.

Moraxan commented 3 years ago

This nearly made me teary eyed. 1) You fixed it. 2) You thanked me for being a teacher, and that's rare. You're the best! A huge thank you from the bottom of my heart.

Den fre 7 maj 2021 kl 17:43 skrev Eyal @.***>:

@Moraxan https://github.com/Moraxan Looks like new version will fix your problem. Try it out and let me know how it goes. Thank you for being a teacher. Let me know if I can be of further service.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/kennethjiang/OctoPrint-Slicer/issues/176#issuecomment-834547097, or unsubscribe https://github.com/notifications/unsubscribe-auth/AT6T5MVOOKSVGVCF4KFAL3LTMQDAPANCNFSM43XSFZ3A .