Giter VIP home page Giter VIP logo

stashapp-tools's People

Contributors

jaypikay avatar stg-annon avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

stashapp-tools's Issues

[Bug] find_image(id) always return None

No matter the id of provided, find_image will return None even though the id exists
Tried
find_image('1234') > None
find_image(1234) > GRAPHQL_ERROR: must not be null ['findImage', 'file', 'mod_time']

adding performers to scenes

How can I add performers to scenes? I've tried to update the scene like this:

stash.update_scene({'id': 1, 'performers': [{ 'id': 10 }, { 'id': 220 }]})

But I get a unknown filed error

Fixes for Stash 0.24.0

GRAPHQL_VALIDATION_FAILED: Cannot query field "aliases" on type "Performer".
422 Unprocessable Entity GQL data response is null
422 Unprocessable Entity query failed. v0.24.0-3
Exception: 422 Unprocessable Entity query failed. v0.24.0-3

GRAPHQL_VALIDATION_FAILED: Field "fingerprint" argument "type" of type "String!" is required, but it was not provided.

Python Version: 3.10.11
stashapp-tools Version: 0.2.38
Stash Version: 0.24.1

I updated Stash from 0.22 to 0.24.1 now this code isn't working anymore.

import stashapi.log as log
from stashapi.stashapp import StashInterface

stash = StashInterface({
    "scheme": "http",
    "host":"xxx.xxx.xxx.xxx",
    "port": "10000",
    "logger": log
})

scene_data = stash.find_images({
    "organized": True
})

log.info(scene_data)

i am always getting the following error message:

☺d☻ Using stash (v0.24.1-0) endpoint at http://xxx.xxx.xxx.xxx:10000/graphql
☺e☻ GRAPHQL_VALIDATION_FAILED: Field "fingerprint" argument "type" of type "String!" is required, but it was not provided.
☺e☻ GRAPHQL_VALIDATION_FAILED: Field "fingerprint" argument "type" of type "String!" is required, but it was not provided.
☺e☻ GRAPHQL_VALIDATION_FAILED: Field "fingerprint" argument "type" of type "String!" is required, but it was not provided.
☺e☻ GRAPHQL_VALIDATION_FAILED: Field "fingerprint" argument "type" of type "String!" is required, but it was not provided.
☺e☻ GRAPHQL_VALIDATION_FAILED: Field "fingerprint" argument "type" of type "String!" is required, but it was not provided.
☺e☻ GRAPHQL_VALIDATION_FAILED: Field "fingerprint" argument "type" of type "String!" is required, but it was not provided.
☺e☻ 422 Unprocessable Entity GQL data response is null
☺e☻ 422 Unprocessable Entity query failed. v0.24.1-0
☺d☻
☺d☻ query FindImages($filter: FindFilterType, $image_filter: ImageFilterType, $image_ids: [Int!]) {
☺d☻     findImages(filter: $filter, image_filter: $image_filter, image_ids: $image_ids) {
☺d☻             count
☺d☻             images {
☺d☻                     ...Image
☺d☻             }
☺d☻     }
☺d☻ }
☺d☻
☺d☻ fragment Image on Image {
☺d☻     id
☺d☻     title
☺d☻     code
☺d☻     rating100
☺d☻     urls
☺d☻     date
☺d☻     details
☺d☻     photographer
☺d☻     o_counter
☺d☻     organized
☺d☻     created_at
☺d☻     updated_at
☺d☻     visual_files { ...VisualFile }
☺d☻     paths { ...ImagePathsType }
☺d☻     galleries { id }
☺d☻     studio { id }
☺d☻     tags { ...Tag }
☺d☻     performers { id }
☺d☻ }
☺d☻ fragment VisualFile on VisualFile {
☺d☻     ... on VideoFile {
☺d☻     id
☺d☻     path
☺d☻     basename
☺d☻     parent_folder_id
☺d☻     zip_file_id
☺d☻     mod_time
☺d☻     size
☺d☻     fingerprint
☺d☻     fingerprints { ...Fingerprint }
☺d☻     format
☺d☻     width
☺d☻     height
☺d☻     duration
☺d☻     video_codec
☺d☻     audio_codec
☺d☻     frame_rate
☺d☻     bit_rate
☺d☻     created_at
☺d☻     updated_at}
☺d☻     ... on ImageFile {
☺d☻     id
☺d☻     path
☺d☻     basename
☺d☻     parent_folder_id
☺d☻     zip_file_id
☺d☻     mod_time
☺d☻     size
☺d☻     fingerprint
☺d☻     fingerprints { ...Fingerprint }
☺d☻     width
☺d☻     height
☺d☻     created_at
☺d☻     updated_at}
☺d☻ }
☺d☻ fragment Tag on Tag {
☺d☻     id
☺d☻     name
☺d☻     description
☺d☻     aliases
☺d☻     ignore_auto_tag
☺d☻     created_at
☺d☻     updated_at
☺d☻     image_path
☺d☻     scene_count
☺d☻     scene_marker_count
☺d☻     image_count
☺d☻     gallery_count
☺d☻     performer_count
☺d☻     parents { id }
☺d☻     children { id }
☺d☻     parent_count
☺d☻     child_count
☺d☻ }
☺d☻ fragment ImagePathsType on ImagePathsType {
☺d☻     thumbnail
☺d☻     preview
☺d☻     image
☺d☻ }
☺d☻ fragment Fingerprint on Fingerprint {
☺d☻     type
☺d☻     value
☺d☻ }
☺d☻ Variables: {'filter': {'per_page': -1, 'q': ''}, 'image_filter': {'organized': True}}

NoneType' object is not subscriptable on StashInterface Initialization

I've been trying to use stashapp-tools after a while (which used to work perfectly), however, I'm getting the following error when trying to initialize the StashInterface class:

e Could not connect to Stash at http://:/graphql e 'NoneType' object is not subscriptable

When trying to access GraphQL directly from http://:/playground that works perfectly fine.

Any ideas what might have changed? Thanks

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.