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

xyz grid handle axis_type is None #14394

Merged
merged 1 commit into from
Dec 30, 2023
Merged

xyz grid handle axis_type is None #14394

merged 1 commit into from
Dec 30, 2023

Conversation

w-e-w
Copy link
Collaborator

@w-e-w w-e-w commented Dec 21, 2023

Description

xyz grid
if the selected axle from dropdown is not found the axis_type index will be None
triggering and error

  File "B:\GitHub\stable-diffusion-webui\scripts\xyz_grid.py", line 479, in select_axis
    choices = self.current_axis_options[axis_type].choices
TypeError: list indices must be integers or slices, not NoneType

simple fix
if axis_type is None then set to index 0 (Nothing)

same logic also applies to run()

Screenshots/videos:

2023-12-22.00_14_11_609.chrome.mp4

Checklist:

@w-e-w w-e-w changed the title handle axis_type is None xyz grid handle axis_type is None Dec 21, 2023
@AUTOMATIC1111 AUTOMATIC1111 merged commit 1d603eb into dev Dec 30, 2023
6 checks passed
@AUTOMATIC1111 AUTOMATIC1111 deleted the minor-xyz-fix branch December 30, 2023 12:06
@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