Open scruffynerf opened 1 year ago
Looks like using *listvariablename
is the way to go, on both sides of the ui and run functions. That expands the list correctly when returning the values, and gives the run script access to the parts in the arguments.
Thanks for your information, got the same error here and solved it. Seems like it doesn't support list input.
Is there an existing issue for this?
What happened?
Writing a custom script... and I've encountered this a few times... crashing a1111 entirely, so I'm doing something wrong, and wanting to know the right way to do this.
Try to pass a list of values from Gradio UI function in custom script to run function in custom script.
Steps to reproduce the problem
Gradio UI... custom script Essentially, if I populate a list and attempt pass it along... so here's a minimal example.
and I get an error:
and stops web.ui entirely, back to CLI
If I remove the myvar from the return and args in run, no error... so it's purely passing a list. If myvar is not a list, no error.
What should have happened?
correctly passing a list value from Gradio to the custom script, same as any other sort of value, as expected...
Commit where the problem happens
0cc0ee1bcb4c24a8c9715f66cede06601bfc00c8
What platforms do you use to access the UI ?
Windows, Linux, MacOS, Android
What browsers do you use to access the UI ?
Mozilla Firefox, Google Chrome, Brave, Microsoft Edge
Command Line Arguments
List of extensions
No, happens regardless of extensions...
Console logs
Additional information
No response