LoRA Weight value from grid parameter are applied to one and only one inline <lora:...> entry when the currently processing LoRA grid parameter is a blank/empty value in the list
Expected Behavior
The Grid's Lora Weight parameter values should never be applied to inline loras found in the prompt, even if the grid's Lora parameter values include an empty/blank entry inside the ',' or '||' delimited list.
Actual Behavior
For the images where the value in the grid Lora list is blank, the grid weight is applied to one and only one of the inline lora objects in the prompt text, which is surprising.
Steps to Reproduce
Using a prompt of this structure...
<lora:lion:0.2><lora:blue_fur:0.7>a picture of a cat
...while running a grid that includes parameters of this structure:
...
Lora Weight: [0.5,1.0]
Lora: [,style_disney,style_80s_cartoon,style_sunday_comics] # note: there are four entries here, the first is empty, though the position of the empty value does not matter
...
When iterating through the list, during the processing of the grid for the, say, two images where the grid Lora parameter value is empty, the Lora Weight value is unexpectedly applied to one of the inline LoRAs, changing the weight (e.g. one of 0.2 or 0.7 becomes 0.5 and 1.0 for those two images, and then returns to the hard-coded value for all other images on the grid where the grid Lora parameter values are not blank).
Note: there is some utility in including a blank entry in the grid LoRA list, I won't bore with details unless asked.
Thanks, Brendan
Debug Logs
Intentionally left blank.
Other
No response
I'm going to consider this a feature request rather than a bug, on the grounds that adding weights to a non-existent lora is naturally going to do weird stuff, and you're essentially instead requesting new handling for a behavior that previously was just not considered valid to do.
In the short term to make wonky lora hacks in grids work reliably, use Prompt Replace to insert loras to the prompt and/or modify them. The setmacro prompt syntax might also be helpful for connecting and gridifying different pieces here.