Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add # to the invalid_filename_chars list #14640

Merged

Conversation

WebDev9000
Copy link
Contributor

Description

Simply adds the # character to the invalid_filename_chars list, which causes it to get replaced by _ in filenames.

Reason is due to a Gradio bug, hashtags in filenames will display as a broken image in the result gallery when the image is saved. This can happen when you have a hashtag in your prompt, lora, etc. if the prompt, lora, or etc. is saved to the filename.

#5271 #5470 (These issues are closed but the problem persists)

Screenshots/videos:

image

Before change
cat
(sped up a bit)

The image is saved correctly, but can't be displayed.
Filename: image

After change
image

The image is displayed and still saved, expect with # replaced by _.
Filename: image

Checklist:

@AUTOMATIC1111 AUTOMATIC1111 merged commit 58a142b into AUTOMATIC1111:dev Jan 20, 2024
3 checks passed
@w-e-w w-e-w mentioned this pull request Feb 17, 2024
@pawel665j pawel665j mentioned this pull request Apr 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants