Alternative Prompts:Intended "[|" or "||" or "|]" fails generate.
Describe the bug Through alternative prompts, I'm trying to add blank prompts ~~to allow prompts being skipped randomly~~Misunderstood the feature yet this is a bug. However [| or || or |] would fail generate. Considered a bug because using a space like [ | seems fixing the problem yet I'm not sure if this works as desired. Alternative Prompts is nevertheless a lottery thing and needs some large batch to test. To Reproduce Steps to reproduce the behavior:
- Enter "[|" or "||" or "|]" in prompt.
- Click on 'Generate.'
- See error, outputs attached
Expected behavior
A blank prompt would be randomly chosen.
I assume the [from::when] prompt is [from:to black prompt:when] so this should be similar?
Desktop (please complete the following information):
- OS: Windows
- Browser MS Edge
- Commit revision c8045c5ad4f99deb3a19add06e0457de1df62b05 Additional context Error output as follows. `Error completing request Arguments: ('[||]', '', 'None', 'None', 60, 0, False, False, 1, 1, 11, -1.0, -1.0, 0, 0, 0, False, 832, 512, True, 0.8, 0, 0, 0, False, False, None, '', 1, '', 0, '', True, False, False) {} Traceback (most recent call last): File "C:\STDF\stable-diffusion-webui\modules\prompt_parser.py", line 74, in alternate yield next(args[(step - 1)%len(args)]) StopIteration
The above exception was the direct cause of the following exception:
Traceback (most recent call last): File "C:\STDF\stable-diffusion-webui\venv\lib\site-packages\lark\visitors.py", line 116, in _call_userfunc return f(children) File "C:\STDF\stable-diffusion-webui\modules\prompt_parser.py", line 82, in start return ''.join(flatten(args)) File "C:\STDF\stable-diffusion-webui\modules\prompt_parser.py", line 81, in flatten yield from flatten(gen) File "C:\STDF\stable-diffusion-webui\modules\prompt_parser.py", line 80, in flatten for gen in x: File "C:\STDF\stable-diffusion-webui\modules\prompt_parser.py", line 87, in default yield from child RuntimeError: generator raised StopIteration
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\STDF\stable-diffusion-webui\modules\ui.py", line 212, in f
res = list(func(*args, **kwargs))
File "C:\STDF\stable-diffusion-webui\webui.py", line 64, in f
res = func(*args, **kwargs)
File "C:\STDF\stable-diffusion-webui\modules\txt2img.py", line 44, in txt2img
processed = process_images(p)
File "C:\STDF\stable-diffusion-webui\modules\processing.py", line 393, in process_images
c = prompt_parser.get_multicond_learned_conditioning(shared.sd_model, prompts, p.steps)
File "C:\STDF\stable-diffusion-webui\modules\prompt_parser.py", line 203, in get_multicond_learned_conditioning
learned_conditioning = get_learned_conditioning(model, prompt_flat_list, steps)
File "C:\STDF\stable-diffusion-webui\modules\prompt_parser.py", line 127, in get_learned_conditioning
prompt_schedules = get_learned_conditioning_prompt_schedules(prompts, steps)
File "C:\STDF\stable-diffusion-webui\modules\prompt_parser.py", line 100, in get_learned_conditioning_prompt_schedules
promptdict = {prompt: get_schedule(prompt) for prompt in set(prompts)}
File "C:\STDF\stable-diffusion-webui\modules\prompt_parser.py", line 100, in
generator raised StopIteration `
I misunderstood Alternative Prompts badly but this should still be a bug.
is this still not fixed or at least addressed to by someone?
Closing as stale.