plexflow 0.0.84__py3-none-any.whl → 0.0.92__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- plexflow/core/context/partials/candidates.py +7 -1
- plexflow/core/context/partials/torrents.py +10 -0
- plexflow/core/torrents/providers/piratesparadise/utils.py +3 -0
- plexflow/core/torrents/providers/tpb/utils.py +3 -0
- plexflow/core/torrents/results/torrent.py +2 -7
- plexflow/utils/google/pubsub/produce.py +21 -0
- {plexflow-0.0.84.dist-info → plexflow-0.0.92.dist-info}/METADATA +2 -2
- {plexflow-0.0.84.dist-info → plexflow-0.0.92.dist-info}/RECORD +10 -9
- {plexflow-0.0.84.dist-info → plexflow-0.0.92.dist-info}/WHEEL +0 -0
- {plexflow-0.0.84.dist-info → plexflow-0.0.92.dist-info}/entry_points.txt +0 -0
@@ -19,4 +19,10 @@ class Candidates(PartialContext):
|
|
19
19
|
self.set('download/ranked/candidates', ranked_candidates)
|
20
20
|
|
21
21
|
def ranked(self) -> Ranked:
|
22
|
-
return self.get('download/ranked/candidates')
|
22
|
+
return self.get('download/ranked/candidates')
|
23
|
+
|
24
|
+
def update_selected(self, candidate: DownloadCandidate):
|
25
|
+
self.set('download/selected', candidate)
|
26
|
+
|
27
|
+
def selected(self) -> DownloadCandidate:
|
28
|
+
return self.get('download/selected')
|
@@ -21,3 +21,13 @@ class Torrents(PartialContext):
|
|
21
21
|
return
|
22
22
|
source = next(iter(torrents)).source
|
23
23
|
self.set(f"torrents/{source}", torrents)
|
24
|
+
|
25
|
+
def update_subtitled(self, torrents: List[Torrent]):
|
26
|
+
if len(torrents) == 0:
|
27
|
+
return
|
28
|
+
source = next(iter(torrents)).source
|
29
|
+
self.set(f"subtitled/torrents/{source}", torrents)
|
30
|
+
|
31
|
+
def from_subtitled_source(self, source: str) -> List[Torrent]:
|
32
|
+
return self.get(f"subtitled/torrents/{source}")
|
33
|
+
|
@@ -32,6 +32,9 @@ class TPBSearchResult(Torrent):
|
|
32
32
|
self.username = kwargs.get("username")
|
33
33
|
self.src = "tpb"
|
34
34
|
|
35
|
+
self._native_dutch_subtitles = []
|
36
|
+
self._native_english_subtitles = []
|
37
|
+
|
35
38
|
@property
|
36
39
|
def magnet(self) -> str:
|
37
40
|
return f'magnet:?xt=urn:btih:{self.info_hash}'
|
@@ -9,9 +9,6 @@ class Torrent(ABC):
|
|
9
9
|
This is an abstract base class that represents a Torrent.
|
10
10
|
Any class that inherits from this must implement all the properties.
|
11
11
|
"""
|
12
|
-
_native_dutch_subtitles = []
|
13
|
-
_native_english_subtitles = []
|
14
|
-
|
15
12
|
@property
|
16
13
|
@abstractmethod
|
17
14
|
def seeds(self) -> int:
|
@@ -161,12 +158,10 @@ class Torrent(ABC):
|
|
161
158
|
return len(self._native_english_subtitles) > 0
|
162
159
|
|
163
160
|
def add_native_dutch_subtitle(self, name: str):
|
164
|
-
|
165
|
-
self._native_dutch_subtitles.append(name)
|
161
|
+
self._native_dutch_subtitles.append(name)
|
166
162
|
|
167
163
|
def add_native_english_subtitle(self, name: str):
|
168
|
-
|
169
|
-
self._native_english_subtitles.append(name)
|
164
|
+
self._native_english_subtitles.append(name)
|
170
165
|
|
171
166
|
@property
|
172
167
|
def is_bad_quality(self):
|
@@ -0,0 +1,21 @@
|
|
1
|
+
from google.cloud import pubsub_v1
|
2
|
+
import json
|
3
|
+
|
4
|
+
def produce_message(value, topic_id: str, project_id: str, as_json: bool = True):
|
5
|
+
publisher = pubsub_v1.PublisherClient()
|
6
|
+
# The `topic_path` method creates a fully qualified identifier
|
7
|
+
# in the form `projects/{project_id}/topics/{topic_id}`
|
8
|
+
topic_path = publisher.topic_path(project_id, topic_id)
|
9
|
+
|
10
|
+
if as_json:
|
11
|
+
data_str = json.dumps(value)
|
12
|
+
else:
|
13
|
+
data_str = str(value)
|
14
|
+
|
15
|
+
# Data must be a bytestring
|
16
|
+
data = data_str.encode("utf-8")
|
17
|
+
# When you publish a message, the client returns a future.
|
18
|
+
future = publisher.publish(topic_path, data)
|
19
|
+
print(future.result())
|
20
|
+
|
21
|
+
print(f"Published messages to {topic_path}.")
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.3
|
2
2
|
Name: plexflow
|
3
|
-
Version: 0.0.
|
3
|
+
Version: 0.0.92
|
4
4
|
Summary: A short description of the package.
|
5
5
|
License: MIT
|
6
6
|
Keywords: keyword1,keyword2,keyword3
|
@@ -25,10 +25,10 @@ Requires-Dist: brotli (>=1.1.0,<2.0.0)
|
|
25
25
|
Requires-Dist: cloudinary (>=1.41.0,<2.0.0)
|
26
26
|
Requires-Dist: cloudscraper (>=1.2.71,<2.0.0)
|
27
27
|
Requires-Dist: cohere (>=5.5.0,<6.0.0)
|
28
|
-
Requires-Dist: confluent-kafka[avro] (>=2.4.0,<3.0.0)
|
29
28
|
Requires-Dist: dataclasses-json (>=0.6.4,<0.7.0)
|
30
29
|
Requires-Dist: dateparser (>=1.2.0,<2.0.0)
|
31
30
|
Requires-Dist: fake-useragent (>=1.4.0,<2.0.0)
|
31
|
+
Requires-Dist: google-cloud-pubsub (>=2.28.0,<3.0.0)
|
32
32
|
Requires-Dist: groq (>=0.9.0,<0.10.0)
|
33
33
|
Requires-Dist: html5lib (>=1.1,<2.0)
|
34
34
|
Requires-Dist: humanfriendly (>=10.0,<11.0)
|
@@ -25,7 +25,7 @@ plexflow/core/context/partials/__pycache__/__init__.cpython-311.pyc,sha256=x_5HU
|
|
25
25
|
plexflow/core/context/partials/__pycache__/ids.cpython-311.pyc,sha256=wV7r4FAwonAshns-NGcowqGamtrM_Q_2NbiHQhOLkjg,2638
|
26
26
|
plexflow/core/context/partials/__pycache__/watchlist.cpython-311.pyc,sha256=k-0BM-AvH-zObpwY0XR8CYrT21kPEa0fmeBmf0wscE0,1466
|
27
27
|
plexflow/core/context/partials/cache.py,sha256=1QQ6yP69wqJiacuc2idhHsXpyUUCqavqgLk25wQB_tI,508
|
28
|
-
plexflow/core/context/partials/candidates.py,sha256=
|
28
|
+
plexflow/core/context/partials/candidates.py,sha256=TnAPeSEolchQ3znT40xKjEQfeCl9qAMLFThWaeT46JY,1033
|
29
29
|
plexflow/core/context/partials/context.py,sha256=pFzpAFxwCJdqPuhXJqhs6j4Xyvf0GQtzPRMmL4fcjEA,314
|
30
30
|
plexflow/core/context/partials/ids.py,sha256=QoQ6FbX1OIWrE-iuz-G6kSzBlTt1_I1jyfl2JgKge2o,913
|
31
31
|
plexflow/core/context/partials/movie.py,sha256=VXQ2SspFgGSRgDefg4VlHrH2fns3KRuKlU72ps6527o,3861
|
@@ -33,7 +33,7 @@ plexflow/core/context/partials/reports.py,sha256=0W58RwK3VSsVHbF0rhvMNNlZZr01eut
|
|
33
33
|
plexflow/core/context/partials/subtitles.py,sha256=Eax0rdGeTqEHkt9KNiyv097X3I1Drt9xb19VDalyA4Q,542
|
34
34
|
plexflow/core/context/partials/tgx_batch.py,sha256=TduB09oBOQ8CtmPYsHIeNe7AI-ypKw21zQAX-7qktEs,859
|
35
35
|
plexflow/core/context/partials/tgx_context.py,sha256=_FuhOvKsFqi_uynHxgC9_QIR2CfYmz-uJCRFtGFJmXI,1641
|
36
|
-
plexflow/core/context/partials/torrents.py,sha256=
|
36
|
+
plexflow/core/context/partials/torrents.py,sha256=GtO4rlb7V2N-4QEWt-ODssEsdUlQ2o0lTo_BFI5i3lw,1109
|
37
37
|
plexflow/core/context/partials/universal_torrents.py,sha256=yohdSEhspSdvmrI6NeBB2Racb7yS2kz7qyFat6gNw6k,563
|
38
38
|
plexflow/core/context/partials/watchlist.py,sha256=XL4H3AXHhyuhuImm3OBfrOmlc9rMvVhBJJGumQijM-c,1108
|
39
39
|
plexflow/core/context/plexflow_context.py,sha256=_Le01owaf_0hW6BwMCvMKrKX0IRHyWGWGYTzxCWmdSE,904
|
@@ -438,7 +438,7 @@ plexflow/core/torrents/providers/piratesparadise/__pycache__/tpb.cpython-312.pyc
|
|
438
438
|
plexflow/core/torrents/providers/piratesparadise/__pycache__/utils.cpython-311.pyc,sha256=YwB71cMUDX6MxUduWoFXRQXsP_LIRqK4rAVrJMX4v38,6704
|
439
439
|
plexflow/core/torrents/providers/piratesparadise/__pycache__/utils.cpython-312.pyc,sha256=IrcVcSYpD4mAn21gja6_3ULB0Kt_JUd3ZTX7piLmNRc,3447
|
440
440
|
plexflow/core/torrents/providers/piratesparadise/piratesparadise.py,sha256=p0V00VKDKijf3B63yVaea2YdRLLIkJAOpPVhTKPglDc,929
|
441
|
-
plexflow/core/torrents/providers/piratesparadise/utils.py,sha256=
|
441
|
+
plexflow/core/torrents/providers/piratesparadise/utils.py,sha256=XIFQZT15e4rOjiI71uPvXPiEz2tNHAZg4jU1hrlrupU,1459
|
442
442
|
plexflow/core/torrents/providers/rarbg2/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
443
443
|
plexflow/core/torrents/providers/rarbg2/__pycache__/__init__.cpython-311.pyc,sha256=5V3wvzaKuEsqNyOL4-jILERBitIwrVqVnMjuQ_gAgik,189
|
444
444
|
plexflow/core/torrents/providers/rarbg2/__pycache__/__init__.cpython-312.pyc,sha256=2-307lDdUrMbmxg9YI1DSbM8Mj6BYWLXva6rQojRh2M,177
|
@@ -500,7 +500,7 @@ plexflow/core/torrents/providers/tpb/__pycache__/tpb.cpython-312.pyc,sha256=MAp1
|
|
500
500
|
plexflow/core/torrents/providers/tpb/__pycache__/utils.cpython-311.pyc,sha256=YwB71cMUDX6MxUduWoFXRQXsP_LIRqK4rAVrJMX4v38,6704
|
501
501
|
plexflow/core/torrents/providers/tpb/__pycache__/utils.cpython-312.pyc,sha256=cJSN6zMizHkzh3_WWJ2uF4bZ6_svJSQnN296iP8YJv4,6378
|
502
502
|
plexflow/core/torrents/providers/tpb/tpb.py,sha256=YB-a3kZ4DUzXkI4TJJszVvoJiX4L0QUJuCo-9iqC6JQ,681
|
503
|
-
plexflow/core/torrents/providers/tpb/utils.py,sha256=
|
503
|
+
plexflow/core/torrents/providers/tpb/utils.py,sha256=M1LdYgMMhFOZ-b12eazCh81tx-KTQMkQ2H21IuhfGOQ,3708
|
504
504
|
plexflow/core/torrents/providers/yts/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
505
505
|
plexflow/core/torrents/providers/yts/__pycache__/__init__.cpython-311.pyc,sha256=QTE1sD-I-LNDtSuyErNJyVT5WwwI5V4nhk3nzW4c60Q,186
|
506
506
|
plexflow/core/torrents/providers/yts/__pycache__/__init__.cpython-312.pyc,sha256=rb26jCjKRY0RXaanm-6RLAFANV4e4DwgUPbZcsCw-gc,174
|
@@ -518,7 +518,7 @@ plexflow/core/torrents/results/__pycache__/torrent.cpython-311.pyc,sha256=Sxfylb
|
|
518
518
|
plexflow/core/torrents/results/__pycache__/torrent.cpython-312.pyc,sha256=gVBo7bTDY_6m9MmdgYy6fcnnoVQkXZiRI2iDANyG5RA,7776
|
519
519
|
plexflow/core/torrents/results/__pycache__/universal.cpython-312.pyc,sha256=fWAmvqL76rp3K0_ydGNEHFJe-05duOvvo76ZpYjZQYE,14162
|
520
520
|
plexflow/core/torrents/results/__pycache__/utils.cpython-312.pyc,sha256=vqEt3jQLzZ-K_E9WV0kKz4K79AScvcg2xyOUTlAcu70,1136
|
521
|
-
plexflow/core/torrents/results/torrent.py,sha256=
|
521
|
+
plexflow/core/torrents/results/torrent.py,sha256=hSYlP_0Uktumi4wzXqIJ-WRRi5YAlvrZVhf_treXDrI,5203
|
522
522
|
plexflow/core/torrents/results/universal.py,sha256=ycprOMT1Px8IthmB82YhmnxeNt7P3GAcrOlEkpKoaQk,7706
|
523
523
|
plexflow/core/torrents/results/utils.py,sha256=abiiO_QQYDpA5aMyO8WFPxnGu5sL5xfACezE5bwrnJU,691
|
524
524
|
plexflow/events/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
@@ -588,6 +588,7 @@ plexflow/utils/filesystem/search.py,sha256=ed2ixbx5r2z_xtk19--Dfi5KK9g3HcsaAk0sq
|
|
588
588
|
plexflow/utils/gmail/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
589
589
|
plexflow/utils/gmail/__pycache__/mails.cpython-311.pyc,sha256=FAYfZzjLVqpPMjrEYcrOIsohtWrZYYXOZSUHod3r8Qg,7239
|
590
590
|
plexflow/utils/gmail/mails.py,sha256=hQIXiYR5LYeoiSH_lhbVM9criDBnTeCNmpZ5tvuUnsA,4562
|
591
|
+
plexflow/utils/google/pubsub/produce.py,sha256=AFlf6QZl6owA4QNzgrmed-d8lFbhsy-0bnMVVbAGNt4,713
|
591
592
|
plexflow/utils/hooks/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
592
593
|
plexflow/utils/hooks/__pycache__/__init__.cpython-311.pyc,sha256=vlT8vFKsxMRss2XuHLM6ouyTl7Wk1To76MVYXowIABs,170
|
593
594
|
plexflow/utils/hooks/__pycache__/__init__.cpython-312.pyc,sha256=c2gIcwOonxPVWWXQE6C3BgiQ7CBIM4EOrvTxD0TIbyw,158
|
@@ -675,7 +676,7 @@ plexflow/utils/video/__pycache__/audio.cpython-312.pyc,sha256=vXBnJwWgTDFdixMBs-
|
|
675
676
|
plexflow/utils/video/__pycache__/subtitle.cpython-312.pyc,sha256=PCjpCLydGXaRsQy6cikhgsEs8WlComfOoYPiLFqfVMA,2515
|
676
677
|
plexflow/utils/video/audio.py,sha256=tJ_lNwcjVuBQYD5cYOlXpr__eh8-hnReIgNRgIYOpqo,3380
|
677
678
|
plexflow/utils/video/subtitle.py,sha256=LOGONGxs_RzmqtGP-DBKreOzS1eUFEKo75Q6AfnavW0,1290
|
678
|
-
plexflow-0.0.
|
679
|
-
plexflow-0.0.
|
680
|
-
plexflow-0.0.
|
681
|
-
plexflow-0.0.
|
679
|
+
plexflow-0.0.92.dist-info/METADATA,sha256=KFluh3UpTaNVM05w_Qw8GR51NlFT2NHPueEoQpkorz4,2953
|
680
|
+
plexflow-0.0.92.dist-info/WHEEL,sha256=IYZQI976HJqqOpQU6PHkJ8fb3tMNBFjg-Cn-pwAbaFM,88
|
681
|
+
plexflow-0.0.92.dist-info/entry_points.txt,sha256=aEqDHlozu_zjWrl2sibtrqtQHMgU8kSJZrE782CP47g,1362
|
682
|
+
plexflow-0.0.92.dist-info/RECORD,,
|
File without changes
|
File without changes
|