commit
5c56866d56
@ -0,0 +1,16 @@
|
|||||||
|
import { SelectorOption } from "@/components";
|
||||||
|
|
||||||
|
export const subtitlesTypeOptions: SelectorOption<string>[] = [
|
||||||
|
{
|
||||||
|
label: "Normal",
|
||||||
|
value: "normal",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "Hearing-Impaired",
|
||||||
|
value: "hi",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: "Forced",
|
||||||
|
value: "forced",
|
||||||
|
},
|
||||||
|
];
|
@ -1 +0,0 @@
|
|||||||
pip
|
|
@ -1,20 +0,0 @@
|
|||||||
argparse is (c) 2006-2009 Steven J. Bethard <steven.bethard@gmail.com>.
|
|
||||||
|
|
||||||
The argparse module was contributed to Python as of Python 2.7 and thus
|
|
||||||
was licensed under the Python license. Same license applies to all files in
|
|
||||||
the argparse package project.
|
|
||||||
|
|
||||||
For details about the Python License, please see doc/Python-License.txt.
|
|
||||||
|
|
||||||
History
|
|
||||||
-------
|
|
||||||
|
|
||||||
Before (and including) argparse 1.1, the argparse package was licensed under
|
|
||||||
Apache License v2.0.
|
|
||||||
|
|
||||||
After argparse 1.1, all project files from the argparse project were deleted
|
|
||||||
due to license compatibility issues between Apache License 2.0 and GNU GPL v2.
|
|
||||||
|
|
||||||
The project repository then had a clean start with some files taken from
|
|
||||||
Python 2.7.1, so definitely all files are under Python License now.
|
|
||||||
|
|
@ -1,84 +0,0 @@
|
|||||||
Metadata-Version: 2.1
|
|
||||||
Name: argparse
|
|
||||||
Version: 1.4.0
|
|
||||||
Summary: Python command-line parsing library
|
|
||||||
Home-page: https://github.com/ThomasWaldmann/argparse/
|
|
||||||
Author: Thomas Waldmann
|
|
||||||
Author-email: tw@waldmann-edv.de
|
|
||||||
License: Python Software Foundation License
|
|
||||||
Keywords: argparse command line parser parsing
|
|
||||||
Platform: any
|
|
||||||
Classifier: Development Status :: 5 - Production/Stable
|
|
||||||
Classifier: Environment :: Console
|
|
||||||
Classifier: Intended Audience :: Developers
|
|
||||||
Classifier: License :: OSI Approved :: Python Software Foundation License
|
|
||||||
Classifier: Operating System :: OS Independent
|
|
||||||
Classifier: Programming Language :: Python
|
|
||||||
Classifier: Programming Language :: Python :: 2
|
|
||||||
Classifier: Programming Language :: Python :: 3
|
|
||||||
Classifier: Programming Language :: Python :: 2.3
|
|
||||||
Classifier: Programming Language :: Python :: 2.4
|
|
||||||
Classifier: Programming Language :: Python :: 2.5
|
|
||||||
Classifier: Programming Language :: Python :: 2.6
|
|
||||||
Classifier: Programming Language :: Python :: 2.7
|
|
||||||
Classifier: Programming Language :: Python :: 3.0
|
|
||||||
Classifier: Programming Language :: Python :: 3.1
|
|
||||||
Classifier: Programming Language :: Python :: 3.2
|
|
||||||
Classifier: Programming Language :: Python :: 3.3
|
|
||||||
Classifier: Programming Language :: Python :: 3.4
|
|
||||||
Classifier: Topic :: Software Development
|
|
||||||
License-File: LICENSE.txt
|
|
||||||
|
|
||||||
The argparse module makes it easy to write user friendly command line
|
|
||||||
interfaces.
|
|
||||||
|
|
||||||
The program defines what arguments it requires, and argparse will figure out
|
|
||||||
how to parse those out of sys.argv. The argparse module also automatically
|
|
||||||
generates help and usage messages and issues errors when users give the
|
|
||||||
program invalid arguments.
|
|
||||||
|
|
||||||
As of Python >= 2.7 and >= 3.2, the argparse module is maintained within the
|
|
||||||
Python standard library. For users who still need to support Python < 2.7 or
|
|
||||||
< 3.2, it is also provided as a separate package, which tries to stay
|
|
||||||
compatible with the module in the standard library, but also supports older
|
|
||||||
Python versions.
|
|
||||||
|
|
||||||
Also, we can fix bugs here for users who are stuck on some non-current python
|
|
||||||
version, like e.g. 3.2.3 (which has bugs that were fixed in a later 3.2.x
|
|
||||||
release).
|
|
||||||
|
|
||||||
argparse is licensed under the Python license, for details see LICENSE.txt.
|
|
||||||
|
|
||||||
|
|
||||||
Compatibility
|
|
||||||
-------------
|
|
||||||
|
|
||||||
argparse should work on Python >= 2.3, it was tested on:
|
|
||||||
|
|
||||||
* 2.3, 2.4, 2.5, 2.6 and 2.7
|
|
||||||
* 3.1, 3.2, 3.3, 3.4
|
|
||||||
|
|
||||||
|
|
||||||
Installation
|
|
||||||
------------
|
|
||||||
|
|
||||||
Try one of these:
|
|
||||||
|
|
||||||
python setup.py install
|
|
||||||
|
|
||||||
easy_install argparse
|
|
||||||
|
|
||||||
pip install argparse
|
|
||||||
|
|
||||||
putting argparse.py in some directory listed in sys.path should also work
|
|
||||||
|
|
||||||
|
|
||||||
Bugs
|
|
||||||
----
|
|
||||||
|
|
||||||
If you find a bug in argparse (pypi), please try to reproduce it with latest
|
|
||||||
python 2.7 and 3.4 (and use argparse from stdlib).
|
|
||||||
|
|
||||||
If it happens there also, please file a bug in the python.org issue tracker.
|
|
||||||
If it does not happen there, file a bug in the argparse package issue tracker.
|
|
||||||
|
|
@ -1,8 +0,0 @@
|
|||||||
argparse-1.4.0.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4
|
|
||||||
argparse-1.4.0.dist-info/LICENSE.txt,sha256=bVBNRcTRCfkl7wWJYLbRzicSu2tXk-kmv8FRcWrHQEg,741
|
|
||||||
argparse-1.4.0.dist-info/METADATA,sha256=yZGPMA4uvkui2P7qaaiI89zqwjDbyFcehJG4j5Pk8Yk,2816
|
|
||||||
argparse-1.4.0.dist-info/RECORD,,
|
|
||||||
argparse-1.4.0.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
||||||
argparse-1.4.0.dist-info/WHEEL,sha256=P2T-6epvtXQ2cBOE_U1K4_noqlJFN3tj15djMgEu4NM,110
|
|
||||||
argparse-1.4.0.dist-info/top_level.txt,sha256=TgiWrQsF0mKWwqS2KHLORD0ZtqYHPRGdCAAzKwtVvJ4,9
|
|
||||||
argparse.py,sha256=0ksYqisQDQvhoiuo19JERCSpg51tc641GFJIx7pTA0g,89214
|
|
@ -1,6 +0,0 @@
|
|||||||
Wheel-Version: 1.0
|
|
||||||
Generator: bdist_wheel (0.41.3)
|
|
||||||
Root-Is-Purelib: true
|
|
||||||
Tag: py2-none-any
|
|
||||||
Tag: py3-none-any
|
|
||||||
|
|
@ -1 +0,0 @@
|
|||||||
argparse
|
|
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,15 @@
|
|||||||
|
import logging
|
||||||
|
|
||||||
|
from bazarr.app.logger import UnwantedWaitressMessageFilter
|
||||||
|
|
||||||
|
def test_true_for_bazarr():
|
||||||
|
record = logging.LogRecord("", logging.INFO, "", 0, "a message from BAZARR for logging", (), None)
|
||||||
|
assert UnwantedWaitressMessageFilter().filter(record)
|
||||||
|
|
||||||
|
def test_false_below_error():
|
||||||
|
record = logging.LogRecord("", logging.INFO, "", 0, "", (), None)
|
||||||
|
assert not UnwantedWaitressMessageFilter().filter(record)
|
||||||
|
|
||||||
|
def test_true_above_error():
|
||||||
|
record = logging.LogRecord("", logging.CRITICAL, "", 0, "", (), None)
|
||||||
|
assert UnwantedWaitressMessageFilter().filter(record)
|
@ -1,50 +0,0 @@
|
|||||||
from subliminal_patch.providers import subscene_cloudscraper as subscene
|
|
||||||
|
|
||||||
|
|
||||||
def test_provider_scraper_call():
|
|
||||||
with subscene.SubsceneProvider() as provider:
|
|
||||||
result = provider._scraper_call(
|
|
||||||
"https://subscene.com/subtitles/breaking-bad-fifth-season"
|
|
||||||
)
|
|
||||||
assert result.status_code == 200
|
|
||||||
|
|
||||||
|
|
||||||
def test_provider_gen_results():
|
|
||||||
with subscene.SubsceneProvider() as provider:
|
|
||||||
assert list(provider._gen_results("Breaking Bad"))
|
|
||||||
|
|
||||||
|
|
||||||
def test_provider_search_movie():
|
|
||||||
with subscene.SubsceneProvider() as provider:
|
|
||||||
result = provider._search_movie("Taxi Driver", 1976)
|
|
||||||
assert result == "/subtitles/taxi-driver"
|
|
||||||
|
|
||||||
|
|
||||||
def test_provider_find_movie_subtitles(languages):
|
|
||||||
with subscene.SubsceneProvider() as provider:
|
|
||||||
result = provider._find_movie_subtitles(
|
|
||||||
"/subtitles/taxi-driver", languages["en"]
|
|
||||||
)
|
|
||||||
assert result
|
|
||||||
|
|
||||||
|
|
||||||
def test_provider_search_tv_show_season():
|
|
||||||
with subscene.SubsceneProvider() as provider:
|
|
||||||
result = provider._search_tv_show_season("The Wire", 1)
|
|
||||||
assert result == "/subtitles/the-wire--first-season"
|
|
||||||
|
|
||||||
|
|
||||||
def test_provider_find_episode_subtitles(languages):
|
|
||||||
with subscene.SubsceneProvider() as provider:
|
|
||||||
result = provider._find_episode_subtitles(
|
|
||||||
"/subtitles/the-wire--first-season", 1, 1, languages["en"]
|
|
||||||
)
|
|
||||||
assert result
|
|
||||||
|
|
||||||
|
|
||||||
def test_provider_download_subtitle(languages):
|
|
||||||
path = "https://subscene.com/subtitles/the-wire--first-season/english/115904"
|
|
||||||
subtitle = subscene.SubsceneSubtitle(languages["en"], path, "", 1)
|
|
||||||
with subscene.SubsceneProvider() as provider:
|
|
||||||
provider.download_subtitle(subtitle)
|
|
||||||
assert subtitle.is_valid()
|
|
Loading…
Reference in new issue