pydn/ComfyUI-to-Python-Extension

"Save as Script" option not available in ComfyUI v0.3.50

Closed this issue · 4 comments

The "Save as Script" option from the UI is not available after the latest UI update in the ComfyUI version 0.3.50
Image

The crux of the issue is the new style menu element injector no longer works.

This, really, isn't the right way to add a UI element anyway, we need to be using Comfy's API for this. I'll have a play around and see if I can't figure something out.

The following works (chuck it in save-as-script.js, remove everything relating to the new style menu as dropdownMenu will be null and cause problems), but I'm having some other issue that's preventing the rest of the process from working.

			name: "SaveAsScript",
			commands: [
				{
					id: "triggerSaveAsScript",
					label: "Save As Script",
					function: () => { savePythonScript(); }
				}
			],
			menuCommands: [
				{
					path: ["File"],
					commands: ["triggerSaveAsScript"]
				}
			]
		});```

i figured it out, will send a PR

Just disable the new menu on config, the "Save as script..." menu available in the old version.