| Summary | Automatically download performer images from stashdb or other stash-boxes. Add the [Stashbox Performer Gallery] tag to a performer and it will create a gallery of images from that stash-box database. Apply the tag [Set Profile Image] to an image to set it as the profile image of that performer. Note you will need to configure the download path and add this as a path under settings > library. | |
| Repository | https://github.com/stashapp/CommunityScripts/blob/main/plugins/stashdb-performer-gallery | |
| Source URL | https://stashapp.github.io/CommunityScripts/stable/index.yml | |
| Install | How to install a plugin? |
Hey! unsure if this is working? I could be doing this wrong though. Have set a downloads folder (before adding to library, so its not managed by stash yet, as well as not in the main stash folder) And have added Stashbox Performer Gallery to some performers but nothing is happening when I run the tasks for the plugin. Same with Set Profile Image, that doesnt seem to do anything either
check if you have stashapi installed, I saw the error when I checked my log.
Hey, the image download seems to work fine, but the galleries that are created are empty. When I click the add tab, all downloaded images show up, but I have to manually match them to each performer. I reckon this can’t be the intended way. Am I missing something?
Where are you saving the images?
in the settings > plugins > stashdb performer gallery and set a folder Download parent folder.
You also need to have this folder as a library in stash and this enabled for images so stash will automatically add them to stash, import the metadata and add them to the galleries.
Adding the gallery, running scan and running the “relink missing images” task to import the image metadata and add it to the gallery.
It downloads images for me, but creates empty blank galleries for me as well. Have a folder setup out, added to library and enabled for images. I get errors when running relink missing images, ending with:
ERRO[2025-10-10 03:52:02] Plugin returned error: exit status 1
Hi, I am having similar issues, download works fine, images visible, it creates the galleries but does not populate them, have tried having the images on a network drive and a local drive neither works, the plugin was working when i initially installed it.
when running the process performers task it gives a repeat of the following error message
2025-11-21 12:22:10Error [Plugin / stashdb performer gallery] 422 Unprocessable Entity query failed. v0.29.3-7716
2025-11-21 12:22:10Error [Plugin / stashdb performer gallery] 422 Unprocessable Entity GQL data response is null
2025-11-21 12:22:10Error [Plugin / stashdb performer gallery] GRAPHQL_VALIDATION_FAILED: Field "fingerprint" argument "type" of type "String!" is required, but it was not provided.
2025-11-21 12:22:10Error [Plugin / stashdb performer gallery] GRAPHQL_VALIDATION_FAILED: Field "fingerprint" argument "type" of type "String!" is required, but it was not provided.
2025-11-21 12:22:10Error [Plugin / stashdb performer gallery] GRAPHQL_VALIDATION_FAILED: Field "fingerprint" argument "type" of type "String!" is required, but it was not provided.
2025-11-21 12:22:10Error [Plugin / stashdb performer gallery] GRAPHQL_VALIDATION_FAILED: Field "fingerprint" argument "type" of type "String!" is required, but it was not provided.
2025-11-21 12:22:10Error [Plugin / stashdb performer gallery] GRAPHQL_VALIDATION_FAILED: Cannot spread fragment "Folder" within itself.
2025-11-21 12:22:10Error [Plugin / stashdb performer gallery] GRAPHQL_VALIDATION_FAILED: Cannot spread fragment "Folder" within itself via "BasicFile".
2025-11-21 12:22:10Error [Plugin / stashdb performer gallery] GRAPHQL_VALIDATION_FAILED: Cannot spread fragment "BasicFile" within itself.
2025-11-21 12:22:10Error [Plugin / stashdb performer gallery] GRAPHQL_VALIDATION_FAILED: Field "fingerprint" argument "type" of type "String!" is required, but it was not provided.
2025-11-21 12:22:10Error [Plugin / stashdb performer gallery] GRAPHQL_VALIDATION_FAILED: Field "fingerprint" argument "type" of type "String!" is required, but it was not provided.
2025-11-21 12:22:08Info [Plugin / stashdb performer gallery] processing performer Anya Olsen, 40 endpoint: https://stashdb.org/graphql, stash id: 65a03569-c651-49a4-85c7-9c8f6fc3362d
2025-11-21 12:22:08Info [Plugin / stashdb performer gallery] Created gallery 1867
2025-11-21 12:22:08Warning [Plugin / stashdb performer gallery] could not parse 1858 to Gallery ID (int)
I think there is a bug in the relink step when a performer has more than 100 images. It loops through the first 100, then appears to try to move to the next page, except the offset gets set to 9900 so it loops forever.
I believe this is the line of code and the associated log item. I think i would equal 100 here so I am guessing it is doing something like (i - 1) * per_page, or (100 - 1) * 100 = 9900. Just a guess from some fuzzy maths but it seems to be the contributing factor.
images = stash.find_images(f=query, filter={"page": i, "per_page": per_page})
Debug
SLOW SQL [403.08712ms]: SELECT DISTINCT images.id FROM images LEFT JOIN images_files ON images_files.image_id = images.id LEFT JOIN files ON images_files.file_id = files.id LEFT JOIN folders ON files.parent_folder_id = folders.id WHERE ((folders.path || '/' || files.basename LIKE ?)) LIMIT 100 OFFSET 9900 , args: [%REMOVED%]
I tried making a separate page variable, which does prevent the endless loop, however I am not 100% confident it is working that way it should be. Reviewing the log kind of seems like it runs the first page twice so I might not completely understand what is happening. Figured I’d report my findings either way.
i = 0
images = []
page = 0
while i < total:
images = stash.find_images(f=query, filter={"page": page, "per_page": per_page})
page = page + 1
for img in images:
log.debug("image: %s" % (img,))
processImages(img)
i = i + 1
log.progress((i / total))
Based on the way the Graphql query appears to handle the page count based on some testing in the playground, searching with page = 0 and page = 1 functionally return the same list of images. End result you end up in effect processing the first page twice.
So personally I’d either start the page count at one or if starting at zero I’d have the page number increment before the find images query line, thus ensuring that the first page is only processed once.