Darklyter / StashPlexAgent.bundle

Plex agent for Stash metadata
61 stars 7 forks source link

CRITICAL (agentkit:1018) - Exception in the search function of agent named 'Stash Plex Agent' #29

Open MarsFade opened 1 year ago

MarsFade commented 1 year ago

Hello,

The scenes are not getting metadata from Stash.

I'm getting the below error in the agent logs.

I couldn't find any reference to the agentkit:1018 error ... appreciate helping me sort it out. Thanks.

2023-11-25 14:54:40,957 (7fc6e9765b38) :  DEBUG (runtime:88) - Sending packed state data (114 bytes)
2023-11-25 14:54:40,958 (7fc6e9765b38) :  DEBUG (runtime:924) - Response: [200] str, 16 bytes
2023-11-25 15:02:55,600 (7fc6e9765b38) :  DEBUG (runtime:717) - Handling request GET /:/plugins/com.plexapp.agents.stashplexagent/prefs
2023-11-25 15:02:55,770 (7fc6e9765b38) :  DEBUG (runtime:814) - Found route matching /:/plugins/com.plexapp.agents.stashplexagent/prefs
2023-11-25 15:02:55,787 (7fc6e9765b38) :  DEBUG (runtime:88) - Sending packed state data (114 bytes)
2023-11-25 15:02:55,787 (7fc6e9765b38) :  DEBUG (runtime:924) - Response: [200] MediaContainer, 5861 bytes
2023-11-25 15:03:03,323 (7fc6e9765b38) :  DEBUG (runtime:717) - Handling request GET /:/plugins/com.plexapp.agents.stashplexagent/messaging/function/X0FnZW50S2l0OlNlYXJjaA__/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoyCmRpY3QKZGljdAo2CnMyCmVuczQKbGFuZ2IwczYKbWFudWFsYjFzNwpwcmltYXJ5aTAKczcKdmVyc2lvbnIxCnM2Cmt3YXJnc3M1Ck1vdmllczEwCm1lZGlhX3R5cGU2CnMxNgo0MTE4MzUyNTRlMDUyZjU2czE3Cm9wZW5TdWJ0aXRsZXNIYXNoczQ2Ck51YmlsZXMgMjIgMDYgMjMgV2Vuc2RheSBLIFBpbnQgU2l6ZWQgUHJpbmNlc3NzNApuYW1lczIwMQolMkZ2aXMlMkZVbnNvcnRlZCUyRk51YmlsZXMlMkUyMiUyRTA2JTJFMjMlMkVXZW5zZGF5JTJFSyUyRVBpbnQlMkVTaXplZCUyRVByaW5jZXNzJTJFWFhYJTJFWHZpRC1pUFQlMkVUZWFtJTJGTnViaWxlcyUyRTIyJTJFMDYlMkUyMyUyRVdlbnNkYXklMkVLJTJFUGludCUyRVNpemVkJTJFUHJpbmNlc3MlMkVYWFglMkVYdmlELWlQVCUyRVRlYW0lMkVhdmlzOApmaWxlbmFtZXM0MAoyODMzMDhmZjc0M2Q1MmNkYTUwMDQxNzA4NTIyN2JjYTc4ZTdhMjY3czgKcGxleEhhc2hzMgotMXM4CmR1cmF0aW9uczMKNjE0czIKaWRyMAo_
2023-11-25 15:03:03,324 (7fc6e9765b38) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2023-11-25 15:03:03,327 (7fc6e9765b38) :  DEBUG (runtime:814) - Found route matching /:/plugins/com.plexapp.agents.stashplexagent/messaging/function/X0FnZW50S2l0OlNlYXJjaA__/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoyCmRpY3QKZGljdAo2CnMyCmVuczQKbGFuZ2IwczYKbWFudWFsYjFzNwpwcmltYXJ5aTAKczcKdmVyc2lvbnIxCnM2Cmt3YXJnc3M1Ck1vdmllczEwCm1lZGlhX3R5cGU2CnMxNgo0MTE4MzUyNTRlMDUyZjU2czE3Cm9wZW5TdWJ0aXRsZXNIYXNoczQ2Ck51YmlsZXMgMjIgMDYgMjMgV2Vuc2RheSBLIFBpbnQgU2l6ZWQgUHJpbmNlc3NzNApuYW1lczIwMQolMkZ2aXMlMkZVbnNvcnRlZCUyRk51YmlsZXMlMkUyMiUyRTA2JTJFMjMlMkVXZW5zZGF5JTJFSyUyRVBpbnQlMkVTaXplZCUyRVByaW5jZXNzJTJFWFhYJTJFWHZpRC1pUFQlMkVUZWFtJTJGTnViaWxlcyUyRTIyJTJFMDYlMkUyMyUyRVdlbnNkYXklMkVLJTJFUGludCUyRVNpemVkJTJFUHJpbmNlc3MlMkVYWFglMkVYdmlELWlQVCUyRVRlYW0lMkVhdmlzOApmaWxlbmFtZXM0MAoyODMzMDhmZjc0M2Q1MmNkYTUwMDQxNzA4NTIyN2JjYTc4ZTdhMjY3czgKcGxleEhhc2hzMgotMXM4CmR1cmF0aW9uczMKNjE0czIKaWRyMAo_
2023-11-25 15:03:03,328 (7fc6e9765b38) :  INFO (agentkit:961) - Searching for matches for {'openSubtitlesHash': '411835254e052f56', 'name': 'Nubiles 22 06 23 Wensday K Pint Sized Princess', 'filename': '%2Fvis%2FUnsorted%2FNubiles%2E22%2E06%2E23%2EWensday%2EK%2EPint%2ESized%2EPrincess%2EXXX%2EXviD-iPT%2ETeam%2FNubiles%2E22%2E06%2E23%2EWensday%2EK%2EPint%2ESized%2EPrincess%2EXXX%2EXviD-iPT%2ETeam%2Eavi', 'plexHash': '283308ff743d52cda500417085227bca78e7a267', 'duration': '-1', 'id': '614'}
2023-11-25 15:03:03,345 (7fc6e9765b38) :  DEBUG (networking:144) - Requesting 'http://127.0.0.1:32400/library/metadata/614/tree'
2023-11-25 15:03:03,411 (7fc6e9765b38) :  DEBUG (networking:144) - Requesting 'http://10.1.11.1:9999/graphql?query=query{findScenes(scene_filter:{path:{value:"\"Nubiles.22.06.23.Wensday.K.Pint.Sized.Princess.XXX.XviD-iPT.Team\"",modifier:INCLUDES}}){scenes{id,title,date,studio{id,name}}}}&apikey=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1aWQiOiJhZG1pbiIsImlhdCI6MTcwMDkwNjU0Niwic3ViIjoiQVBJS2V5In0.wuFHHR0cLlXRqzqg6nct1o84ZZmI1R05_prgOS_XEbE'
2023-11-25 15:03:03,455 (7fc6e9765b38) :  INFO (__init__:127) - {'data': {'findScenes': {'scenes': [{'date': '2022-06-23', 'studio': None, 'id': '152', 'title': 'Pint Sized Princess'}]}}}
2023-11-25 15:03:03,455 (7fc6e9765b38) :  INFO (__init__:135) - Title Found: Pint Sized Princess - 2022-06-23 Score: 100 ID:152
2023-11-25 15:03:03,457 (7fc6e9765b38) :  CRITICAL (agentkit:1018) - Exception in the search function of agent named 'Stash Plex Agent', called with keyword arguments {'openSubtitlesHash': '411835254e052f56', 'name': 'Nubiles 22 06 23 Wensday K Pint Sized Princess', 'filename': '%2Fvis%2FUnsorted%2FNubiles%2E22%2E06%2E23%2EWensday%2EK%2EPint%2ESized%2EPrincess%2EXXX%2EXviD-iPT%2ETeam%2FNubiles%2E22%2E06%2E23%2EWensday%2EK%2EPint%2ESized%2EPrincess%2EXXX%2EXviD-iPT%2ETeam%2Eavi', 'plexHash': '283308ff743d52cda500417085227bca78e7a267', 'duration': '-1', 'id': '614'} (most recent call last):
  File "/usr/lib/plexmediaserver/Resources/Plug-ins-871adbd44/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/api/agentkit.py", line 1011, in _search
    agent.search(*f_args, **f_kwargs)
  File "/config/Library/Application Support/Plex Media Server/Plug-ins/StashPlexAgent.bundle/Contents/Code/__init__.py", line 137, in search
    title = FormattedTitle(scene, title)
  File "/config/Library/Application Support/Plex Media Server/Plug-ins/StashPlexAgent.bundle/Contents/Code/__init__.py", line 98, in FormattedTitle
    studio=studio
KeyError: 'Studio'
MikeLund commented 11 months ago

It looks like your scene doesn't have any Studio tagged to it, which the plugin needs. So check your scene 152 in Stash and see that it has a Studio set.