Skip to content

Commit

Permalink
clean up unused dependencies requirements (#399)
Browse files Browse the repository at this point in the history
Co-authored-by: feederbox826 <[email protected]>
  • Loading branch information
feederbox826 and feederbox826 authored Aug 16, 2024
1 parent dc0b6c6 commit b166d47
Show file tree
Hide file tree
Showing 9 changed files with 10 additions and 29 deletions.
2 changes: 0 additions & 2 deletions plugins/DateParser/date_parser.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
import sys, json
from pathlib import Path

import stashapi.log as log
from stashapi.stashapp import StashInterface
import re
from dateparser import parse
from datetime import datetime


def main():
Expand Down
14 changes: 1 addition & 13 deletions plugins/DateParser/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,14 +1,2 @@
certifi>=2022.9.24
charset-normalizer>=2.1.1
dateparser>=1.1.3
idna>=3.4
python-dateutil>=2.8.2
pytz>=2022.6
pytz-deprecation-shim>=0.1.0.post0
regex>=2022.3.2
requests>=2.28.1
six>=1.16.0
stashapp-tools>=0.2.17
tzdata>=2022.6
tzlocal>=4.2
urllib3>=1.26.12
stashapp-tools>=0.2.17
3 changes: 2 additions & 1 deletion plugins/FileMonitor/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
stashapp-tools >= 0.2.49
pyYAML
watchdog
watchdog
schedule
1 change: 0 additions & 1 deletion plugins/RenameFile/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
stashapp-tools >= 0.2.49
pyYAML
requests
11 changes: 6 additions & 5 deletions plugins/TPDBMarkers/tpdbMarkers.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,11 @@
per_page = 100
request_s = requests.Session()

TPDB_ENDPOINT = "https://theporndb.net/graphql"

def processScene(scene):
for sid in scene["stash_ids"]:
if sid["endpoint"] == "https://theporndb.net/graphql":
if sid["endpoint"] == TPDB_ENDPOINT:
log.debug("Scene has a TPDB stash id, looking up %s " % (sid["stash_id"],))
res = request_s.get(
"https://api.theporndb.net/scenes/%s" % (sid["stash_id"],)
Expand Down Expand Up @@ -58,7 +59,7 @@ def processAll():
count = stash.find_scenes(
f={
"stash_id_endpoint": {
"endpoint": "https://theporndb.net/graphql",
"endpoint": TPDB_ENDPOINT,
"modifier": "NOT_NULL",
"stash_id": "",
},
Expand Down Expand Up @@ -87,7 +88,7 @@ def processAll():
scenes = stash.find_scenes(
f={
"stash_id_endpoint": {
"endpoint": "https://theporndb.net/graphql",
"endpoint": TPDB_ENDPOINT,
"modifier": "NOT_NULL",
"stash_id": "",
},
Expand Down Expand Up @@ -160,11 +161,11 @@ def processMovie(m):
log.debug("settings: %s " % (settings,))

# Set up the auth token for tpdb
if "https://theporndb.net/graphql" in [
if TPDB_ENDPOINT in [
x["endpoint"] for x in stash.get_configuration()["general"]["stashBoxes"]
]:
for x in stash.get_configuration()["general"]["stashBoxes"]:
if x["endpoint"] == "https://theporndb.net/graphql":
if x["endpoint"] == TPDB_ENDPOINT:
request_s.headers["Authorization"] = "Bearer %s" % (x["api_key"],)

if "mode" in json_input["args"]:
Expand Down
1 change: 0 additions & 1 deletion plugins/setSceneCoverFromFile/set_cover.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
import re
import sys
import json
import base64

try:
import stashapi.log as log
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
import stashapi.log as log
from stashapi.stashapp import StashInterface, StashItem
from stashapi.stashapp import StashInterface
from stashapi.stashbox import StashBoxInterface
import os
import sys
import requests
import json
import time
import math
import requests
from pathlib import Path
import base64
Expand Down
2 changes: 0 additions & 2 deletions plugins/tagScenesWithPerfTags/tagScenesWithPerfTags.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
import stashapi.log as log
from stashapi.stashapp import StashInterface
import sys
import json


def processAll():
query = {
"tags": {
Expand Down
1 change: 0 additions & 1 deletion plugins/timestampTrade/timestampTrade.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import stashapi.log as log
from stashapi.stashapp import StashInterface
import stashapi.marker_parse as mp
import os
import sys
import requests
import json
Expand Down

0 comments on commit b166d47

Please sign in to comment.