Welcome to Dev CouchPotato’s documentation!

Some text, describing this index-document.

Hello, and currently, it is all I could write here.

This is just first version

Module Index

Unittest

CouchPotato uses native module unittest and some additional tools:

  • mock (for mocking)
  • nosetests (automatic test discovering, report gen, coverage calc)

Current coverage is always accessible on Coveralls

How to run

>>> grunt test

How to write test

Best practices in process...

Travis CI

Travis CI provides building and testing features for each push to git.

Integration details

About Travis CI integration...

Coveralls

Shows the current code coverage

Appveyor

Required to implement integration to provide testing of Win-version.

Custom index

Custom index of modules

CouchPotato module

class CouchPotato.Loader[source]

Bases: object

addSignals()
daemonize()
do_restart = False
onExit(signal, frame)
restart()
run()
runAsDaemon()
setRestart(restart)

couchpotato package

Subpackages

couchpotato.core package
Subpackages
couchpotato.core.downloaders package
Subpackages
couchpotato.core.downloaders.putio package
Submodules
couchpotato.core.downloaders.putio.main module
class couchpotato.core.downloaders.putio.main.PutIO[source]

Bases: couchpotato.core._base.downloader.main.DownloaderBase

convertFolder(client, folder)
download(data=None, media=None, filedata=None)
downloading_list = []
getAllDownloadStatus(ids)
getAuthorizationUrl(host=None, **kwargs)
getCredentials(**kwargs)
getFromPutio(**kwargs)
oauth_authenticate = 'https://api.couchpota.to/authorize/putio/'
protocol = ['torrent', 'torrent_magnet']
putioDownloader(fid)
recursionFolder(client, folder=0, tfolder='')
test()
Module contents
couchpotato.core.downloaders.putio.autoload()[source]
Submodules
couchpotato.core.downloaders.blackhole module
class couchpotato.core.downloaders.blackhole.Blackhole[source]

Bases: couchpotato.core._base.downloader.main.DownloaderBase

download(data=None, media=None, filedata=None)

Send a torrent/nzb file to the downloader

Parameters:
  • data – dict returned from provider Contains the release information
  • media – media dict with information Used for creating the filename when possible
  • filedata – downloaded torrent/nzb filedata The file gets downloaded in the searcher and send to this function This is done to have failed checking before using the downloader, so the downloader doesn’t need to worry about that
Returns:

boolean One faile returns false, but the downloaded should log his own errors

getEnabledProtocol()

What protocols is this downloaded used for :return: list with protocols

isEnabled(manual=False, data=None)

Check if protocol is used (and enabled) :param manual: The user has clicked to download a link through the webUI :param data: dict returned from provider

Contains the release information
Returns:boolean
protocol = ['nzb', 'torrent', 'torrent_magnet']
status_support = False
test()

Test and see if the directory is writable :return: boolean

couchpotato.core.downloaders.deluge module
class couchpotato.core.downloaders.deluge.Deluge[source]

Bases: couchpotato.core._base.downloader.main.DownloaderBase

connect(reconnect=False)

Connect to the delugeRPC, re-use connection when already available :param reconnect: force reconnect :return: DelugeRPC instance

download(data=None, media=None, filedata=None)

Send a torrent/nzb file to the downloader

Parameters:
  • data – dict returned from provider Contains the release information
  • media – media dict with information Used for creating the filename when possible
  • filedata – downloaded torrent/nzb filedata The file gets downloaded in the searcher and send to this function This is done to have failed checking before using the downloader, so the downloader doesn’t need to worry about that
Returns:

boolean One faile returns false, but the downloaded should log his own errors

drpc = None
getAllDownloadStatus(ids)

Get status of all active downloads

Parameters:ids – list of (mixed) downloader ids Used to match the releases for this downloader as there could be other downloaders active that it should ignore
Returns:list of releases
log = <couchpotato.core.logger.CPLog object>
pause(release_download, pause=True)
processComplete(release_download, delete_files=False)
protocol = ['torrent', 'torrent_magnet']
removeFailed(release_download)
test()

Check if connection works :return: bool

class couchpotato.core.downloaders.deluge.DelugeRPC(host='localhost', port=58846, username=None, password=None)[source]

Bases: object

add_torrent_file(filename, torrent, options)
add_torrent_magnet(torrent, options)
client = None
connect()
disconnect()
get_alltorrents(ids)
host = 'localhost'
password = None
pause_torrent(torrent_ids)
port = 58846
remove_torrent(torrent_id, remove_local_data)
resume_torrent(torrent_ids)
test()
username = None
couchpotato.core.downloaders.hadouken module
class couchpotato.core.downloaders.hadouken.Hadouken[source]

Bases: couchpotato.core._base.downloader.main.DownloaderBase

connect()[source]
download(data=None, media=None, filedata=None)[source]

Send a torrent/nzb file to the downloader

Parameters:
  • data – dict returned from provider Contains the release information
  • media – media dict with information Used for creating the filename when possible
  • filedata – downloaded torrent/nzb filedata The file gets downloaded in the searcher and send to this function This is done to have failed checking before using the downloader, so the downloader doesn’t need to worry about that
Returns:

boolean One faile returns false, but the downloaded should log his own errors

getAllDownloadStatus(ids)[source]

Get status of all active downloads

Parameters:ids – list of (mixed) downloader ids Used to match the releases for this downloader as there could be other downloaders active that it should ignore
Returns:list of releases
hadouken_api = None
pause(release_download, pause=True)[source]

Pauses or resumes the torrent specified by the ID field in release_download.

Keyword arguments: release_download – The CouchPotato release_download to pause/resume. pause – Boolean indicating whether to pause or resume.

processComplete(release_download, delete_files=False)[source]

Removes the completed torrent from Hadouken and optionally removes the data associated with it.

Keyword arguments: release_download – The CouchPotato release_download to remove. delete_files: Boolean indicating whether to remove the associated data.

protocol = ['torrent', 'torrent_magnet']
removeFailed(release_download)[source]

Removes a failed torrent and also remove the data associated with it.

Keyword arguments: release_download – The CouchPotato release_download to remove.

test()[source]

Tests the given host:port and API key

class couchpotato.core.downloaders.hadouken.HadoukenAPI(rpc_client)[source]

Bases: object

add_file(data, params)[source]

Add a file to Hadouken with the specified parameters.

Keyword arguments: filedata – The binary torrent data. torrent_params – Additional parameters for the file.

Add a magnet link to Hadouken with the specified parameters.

Keyword arguments: magnetLink – The magnet link to send. torrent_params – Additional parameters for the magnet link.

get_by_hash_list(infoHashList)[source]

Gets a list of torrents filtered by the given info hash list.

Keyword arguments: infoHashList – A list of info hashes.

get_files_by_hash(infoHash)[source]

Gets a list of files for the torrent identified by the given info hash.

Keyword arguments: infoHash – The info hash of the torrent to return files for.

get_version()[source]

Gets the version, commitish and build date of Hadouken.

pause(infoHash, pause)[source]

Pauses/unpauses the torrent identified by the given info hash.

Keyword arguments: infoHash – The info hash of the torrent to operate on. pause – If true, pauses the torrent. Otherwise resumes.

remove(infoHash, remove_data=False)[source]

Removes the torrent identified by the given info hash and optionally removes the data as well.

Keyword arguments: infoHash – The info hash of the torrent to remove. remove_data – If true, removes the data associated with the torrent.

class couchpotato.core.downloaders.hadouken.HadoukenAPIv4[source]

Bases: object

add_file(data, params)[source]
get_by_hash_list(infoHashList)[source]
get_files_by_hash(infoHash)[source]
get_version()[source]
pause(infoHash, pause)[source]
remove(infoHash, remove_data=False)[source]
class couchpotato.core.downloaders.hadouken.HadoukenAPIv5(rpc_client)[source]

Bases: couchpotato.core.downloaders.hadouken.HadoukenAPI

add_file(data, params)[source]
get_by_hash_list(infoHashList)[source]
get_files_by_hash(infoHash)[source]
get_version()[source]
pause(infoHash, pause)[source]
remove(infoHash, remove_data=False)[source]
class couchpotato.core.downloaders.hadouken.JsonRpcClient(url, auth_header=None)[source]

Bases: object

invoke(method, params)[source]
class couchpotato.core.downloaders.hadouken.TorrentItem[source]

Bases: object

get_seed_ratio()[source]

Returns the seed ratio for a given torrent.

get_status()[source]

Returns the CouchPotato status for a given torrent.

info_hash
name
save_path
state
class couchpotato.core.downloaders.hadouken.TorrentItemv4(obj)[source]

Bases: couchpotato.core.downloaders.hadouken.TorrentItem

get_seed_ratio()[source]
get_status()[source]
info_hash()[source]
name()[source]
save_path()[source]
state()[source]
class couchpotato.core.downloaders.hadouken.TorrentItemv5(obj)[source]

Bases: couchpotato.core.downloaders.hadouken.TorrentItem

get_seed_ratio()[source]
get_status()[source]
info_hash()[source]
name()[source]
save_path()[source]
state()[source]
couchpotato.core.downloaders.nzbget module
class couchpotato.core.downloaders.nzbget.NZBGet[source]

Bases: couchpotato.core._base.downloader.main.DownloaderBase

download(data=None, media=None, filedata=None)

Send a torrent/nzb file to the downloader

Parameters:
  • data – dict returned from provider Contains the release information
  • media – media dict with information Used for creating the filename when possible
  • filedata – downloaded torrent/nzb filedata The file gets downloaded in the searcher and send to this function This is done to have failed checking before using the downloader, so the downloader doesn’t need to worry about that
Returns:

boolean One faile returns false, but the downloaded should log his own errors

getAllDownloadStatus(ids)

Get status of all active downloads

Parameters:ids – list of (mixed) downloader ids Used to match the releases for this downloader as there could be other downloaders active that it should ignore
Returns:list of releases
getRPC()
protocol = ['nzb']
removeFailed(release_download)
rpc = 'xmlrpc'
test()

Check if connection works :return: bool

couchpotato.core.downloaders.nzbvortex module
class couchpotato.core.downloaders.nzbvortex.NZBVortex[source]

Bases: couchpotato.core._base.downloader.main.DownloaderBase

api_level = None
call(call, parameters=None, is_repeat=False, auth=True, *args, **kwargs)
download(data=None, media=None, filedata=None)

Send a torrent/nzb file to the downloader

Parameters:
  • data – dict returned from provider Contains the release information
  • media – media dict with information Used for creating the filename when possible
  • filedata – downloaded torrent/nzb filedata The file gets downloaded in the searcher and send to this function This is done to have failed checking before using the downloader, so the downloader doesn’t need to worry about that
Returns:

boolean One faile returns false, but the downloaded should log his own errors

getAllDownloadStatus(ids)

Get status of all active downloads

Parameters:ids – list of (mixed) downloader ids Used to match the releases for this downloader as there could be other downloaders active that it should ignore
Returns:list of releases
getApiLevel()
isEnabled(manual=False, data=None)
login()
protocol = ['nzb']
removeFailed(release_download)
session_id = None
test()

Check if connection works :return: bool

couchpotato.core.downloaders.pneumatic module
class couchpotato.core.downloaders.pneumatic.Pneumatic[source]

Bases: couchpotato.core._base.downloader.main.DownloaderBase

download(data=None, media=None, filedata=None)

Send a torrent/nzb file to the downloader

Parameters:
  • data – dict returned from provider Contains the release information
  • media – media dict with information Used for creating the filename when possible
  • filedata – downloaded torrent/nzb filedata The file gets downloaded in the searcher and send to this function This is done to have failed checking before using the downloader, so the downloader doesn’t need to worry about that
Returns:

boolean One faile returns false, but the downloaded should log his own errors

protocol = ['nzb']
status_support = False
strm_syntax = 'plugin://plugin.program.pneumatic/?mode=strm&type=add_file&nzb=%s&nzbname=%s'
test()

Check if connection works :return: bool

couchpotato.core.downloaders.qbittorrent_ module
class couchpotato.core.downloaders.qbittorrent_.qBittorrent[source]

Bases: couchpotato.core._base.downloader.main.DownloaderBase

connect()
download(data=None, media=None, filedata=None)

Send a torrent/nzb file to the downloader

Parameters:
  • data – dict returned from provider Contains the release information
  • media – media dict with information Used for creating the filename when possible
  • filedata – downloaded torrent/nzb filedata The file gets downloaded in the searcher and send to this function This is done to have failed checking before using the downloader, so the downloader doesn’t need to worry about that
Returns:

boolean One faile returns false, but the downloaded should log his own errors

getAllDownloadStatus(ids)

Get status of all active downloads

Parameters:ids – list of (mixed) downloader ids Used to match the releases for this downloader as there could be other downloaders active that it should ignore
Returns:list of releases
getTorrentStatus(torrent)
pause(release_download, pause=True)
processComplete(release_download, delete_files)
protocol = ['torrent', 'torrent_magnet']
qb = None
removeFailed(release_download)
test()

Check if connection works :return: bool

couchpotato.core.downloaders.rtorrent_ module
class couchpotato.core.downloaders.rtorrent_.rTorrent[source]

Bases: couchpotato.core._base.downloader.main.DownloaderBase

connect(reconnect=False)
download(data=None, media=None, filedata=None)

Send a torrent/nzb file to the downloader

Parameters:
  • data – dict returned from provider Contains the release information
  • media – media dict with information Used for creating the filename when possible
  • filedata – downloaded torrent/nzb filedata The file gets downloaded in the searcher and send to this function This is done to have failed checking before using the downloader, so the downloader doesn’t need to worry about that
Returns:

boolean One faile returns false, but the downloaded should log his own errors

error_msg = ''
getAllDownloadStatus(ids)

Get status of all active downloads

Parameters:ids – list of (mixed) downloader ids Used to match the releases for this downloader as there could be other downloaders active that it should ignore
Returns:list of releases
getAuth()
getTorrentStatus(torrent)
getVerifySsl()
migrate()
pause(release_download, pause=True)
processComplete(release_download, delete_files)
protocol = ['torrent', 'torrent_magnet']
removeFailed(release_download)
rt = None
settingsChanged()
test()

Check if connection works :return: bool

couchpotato.core.downloaders.sabnzbd module
class couchpotato.core.downloaders.sabnzbd.Sabnzbd[source]

Bases: couchpotato.core._base.downloader.main.DownloaderBase

call(request_params, use_json=True, **kwargs)
download(data=None, media=None, filedata=None)

Send a torrent/nzb file to the downloader

Parameters:
  • data – dict returned from provider Contains the release information
  • media – media dict with information Used for creating the filename when possible
  • filedata – downloaded torrent/nzb filedata The file gets downloaded in the searcher and send to this function This is done to have failed checking before using the downloader, so the downloader doesn’t need to worry about that
Returns:

boolean One faile returns false, but the downloaded should log his own errors

getAllDownloadStatus(ids)

Get status of all active downloads

Parameters:ids – list of (mixed) downloader ids Used to match the releases for this downloader as there could be other downloaders active that it should ignore
Returns:list of releases
processComplete(release_download, delete_files=False)
protocol = ['nzb']
removeFailed(release_download)
test()

Check if connection works Return message if an old version of SAB is used :return: bool

couchpotato.core.downloaders.synology module
class couchpotato.core.downloaders.synology.Synology[source]

Bases: couchpotato.core._base.downloader.main.DownloaderBase

download(data=None, media=None, filedata=None)

Send a torrent/nzb file to the downloader

Parameters:
  • data – dict returned from provider Contains the release information
  • media – media dict with information Used for creating the filename when possible
  • filedata – downloaded torrent/nzb filedata The file gets downloaded in the searcher and send to this function This is done to have failed checking before using the downloader, so the downloader doesn’t need to worry about that
Returns:

boolean One faile returns false, but the downloaded should log his own errors

getEnabledProtocol()
isEnabled(manual=False, data=None)
protocol = ['nzb', 'torrent', 'torrent_magnet']
status_support = False
test()

Check if connection works :return: bool

class couchpotato.core.downloaders.synology.SynologyRPC(host='localhost', port=5000, username=None, password=None, destination=None)[source]

Bases: object

SynologyRPC lite library

create_task(url=None, filename=None, filedata=None)

Creates new download task in Synology DownloadStation. Either specify url or pair (filename, filedata).

Returns True if task was created, False otherwise

test()
couchpotato.core.downloaders.transmission module
class couchpotato.core.downloaders.transmission.Transmission[source]

Bases: couchpotato.core._base.downloader.main.DownloaderBase

connect()
download(data=None, media=None, filedata=None)

Send a torrent/nzb file to the downloader

Parameters:
  • data – dict returned from provider Contains the release information
  • media – media dict with information Used for creating the filename when possible
  • filedata – downloaded torrent/nzb filedata The file gets downloaded in the searcher and send to this function This is done to have failed checking before using the downloader, so the downloader doesn’t need to worry about that
Returns:

boolean One faile returns false, but the downloaded should log his own errors

getAllDownloadStatus(ids)

Get status of all active downloads

Parameters:ids – list of (mixed) downloader ids Used to match the releases for this downloader as there could be other downloaders active that it should ignore
Returns:list of releases
log = <couchpotato.core.logger.CPLog object>
pause(release_download, pause=True)
processComplete(release_download, delete_files=False)
protocol = ['torrent', 'torrent_magnet']
removeFailed(release_download)
test()

Check if connection works :return: bool

trpc = None
class couchpotato.core.downloaders.transmission.TransmissionRPC(host='http://localhost', port=9091, rpc_url='transmission', username=None, password=None)[source]

Bases: object

TransmissionRPC lite library

add_torrent_file(torrent, arguments)
add_torrent_uri(torrent, arguments)
get_alltorrents(arguments)
get_session()
remove_torrent(torrent_id, delete_local_data)
set_torrent(torrent_id, arguments)
start_torrent(torrent_id)
stop_torrent(torrent_id)
couchpotato.core.downloaders.utorrent module
class couchpotato.core.downloaders.utorrent.uTorrent[source]

Bases: couchpotato.core._base.downloader.main.DownloaderBase

connect()
download(data=None, media=None, filedata=None)

Send a torrent/nzb file to the downloader

Parameters:
  • data – dict returned from provider Contains the release information
  • media – media dict with information Used for creating the filename when possible
  • filedata – downloaded torrent/nzb filedata The file gets downloaded in the searcher and send to this function This is done to have failed checking before using the downloader, so the downloader doesn’t need to worry about that
Returns:

boolean One faile returns false, but the downloaded should log his own errors

getAllDownloadStatus(ids)

Get status of all active downloads

Parameters:ids – list of (mixed) downloader ids Used to match the releases for this downloader as there could be other downloaders active that it should ignore
Returns:list of releases
pause(release_download, pause=True)
processComplete(release_download, delete_files=False)
protocol = ['torrent', 'torrent_magnet']
removeFailed(release_download)
removeReadOnly(files)
status_flags = {'PAUSED': 32, 'CHECKING': 2, 'CHECKED': 8, 'ERROR': 16, 'STARTED': 1, 'LOADED': 128, 'CHECK-START': 4, 'QUEUED': 64}
test()

Check if connection works :return: bool

utorrent_api = None
class couchpotato.core.downloaders.utorrent.uTorrentAPI(host='localhost', port=8000, username=None, password=None)[source]

Bases: object

add_torrent_file(filename, filedata, add_folder=False)
add_torrent_uri(filename, torrent, add_folder=False)
get_build()
get_files(hash)
get_settings()
get_status()
get_token()
pause_torrent(hash, pause=True)
remove_torrent(hash, remove_data=False)
set_settings(settings_dict=None)
set_torrent(hash, params)
stop_torrent(hash)
Module contents
couchpotato.core.helpers package
Submodules
couchpotato.core.helpers.encoding module
couchpotato.core.helpers.encoding.ek(original, *args)[source]
couchpotato.core.helpers.encoding.isInt(value)[source]
couchpotato.core.helpers.encoding.simplifyString(original)[source]
couchpotato.core.helpers.encoding.sp(path, *args)[source]
couchpotato.core.helpers.encoding.ss(original, *args)[source]
couchpotato.core.helpers.encoding.stripAccents(s)[source]
couchpotato.core.helpers.encoding.toSafeString(original)[source]
couchpotato.core.helpers.encoding.toUnicode(original, *args)[source]
couchpotato.core.helpers.encoding.tryUrlencode(s)[source]
couchpotato.core.helpers.request module
couchpotato.core.helpers.request.dictToList(params)[source]
couchpotato.core.helpers.request.getParams(params)[source]
couchpotato.core.helpers.rss module
class couchpotato.core.helpers.rss.RSS[source]

Bases: object

getElement(xml, path)

Find element and return text

getElements(xml, path)
getItems(data, path='channel/item')
getTextElement(xml, path)

Find element and return text

getTextElements(xml, path)

Find elements and return tree

couchpotato.core.helpers.variable module
couchpotato.core.helpers.variable.cleanHost(host, protocol=True, ssl=False, username=None, password=None)[source]

Return a cleaned up host with given url options set

Changes protocol to https if ssl is set to True and http if ssl is set to false. >>> cleanHost(“localhost:80”, ssl=True) ‘https://localhost:80/’ >>> cleanHost(“localhost:80”, ssl=False) ‘http://localhost:80/’

Username and password is managed with the username and password variables >>> cleanHost(“localhost:80”, username=”user”, password=”passwd”) ‘http://user:passwd@localhost:80/’

Output without scheme (protocol) can be forced with protocol=False >>> cleanHost(“localhost:80”, protocol=False) ‘localhost:80’

couchpotato.core.helpers.variable.compareVersions(version1, version2)[source]
couchpotato.core.helpers.variable.dictIsSubset(a, b)[source]
couchpotato.core.helpers.variable.find(func, iterable)[source]
couchpotato.core.helpers.variable.flattenList(l)[source]
couchpotato.core.helpers.variable.fnEscape(pattern)[source]
couchpotato.core.helpers.variable.getDataDir()[source]
couchpotato.core.helpers.variable.getDownloadDir()[source]
couchpotato.core.helpers.variable.getExt(filename)[source]
couchpotato.core.helpers.variable.getFreeSpace(directories)[source]
couchpotato.core.helpers.variable.getIdentifier(media)[source]
couchpotato.core.helpers.variable.getImdb(txt, check_inside=False, multiple=False)[source]
couchpotato.core.helpers.variable.getSize(paths)[source]
couchpotato.core.helpers.variable.getTitle(media_dict)[source]
couchpotato.core.helpers.variable.getUserDir()[source]
couchpotato.core.helpers.variable.isDict(obj)[source]
couchpotato.core.helpers.variable.isLocalIP(ip)[source]
couchpotato.core.helpers.variable.isSubFolder(sub_folder, base_folder)[source]
couchpotato.core.helpers.variable.md5(text)[source]
couchpotato.core.helpers.variable.mergeDicts(a, b, prepend_list=False)[source]
couchpotato.core.helpers.variable.natsortKey(string_)[source]

See http://www.codinghorror.com/blog/archives/001018.html

couchpotato.core.helpers.variable.possibleTitles(raw_title)[source]
couchpotato.core.helpers.variable.randomString(size=8, chars='ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789')[source]
couchpotato.core.helpers.variable.removeDuplicate(l)[source]
couchpotato.core.helpers.variable.removeEmpty(l)[source]
couchpotato.core.helpers.variable.removeListDuplicates(seq)[source]
couchpotato.core.helpers.variable.removePyc(folder, only_excess=True, show_logs=True)[source]
couchpotato.core.helpers.variable.scanForPassword(name)[source]
couchpotato.core.helpers.variable.sha1(text)[source]
couchpotato.core.helpers.variable.splitString(str, split_on=', ', clean=True)[source]
couchpotato.core.helpers.variable.toIterable(value)[source]
couchpotato.core.helpers.variable.tryFloat(s)[source]
couchpotato.core.helpers.variable.tryInt(s, default=0)[source]
couchpotato.core.helpers.variable.underscoreToCamel(name)[source]
Module contents
couchpotato.core.media package
Subpackages
couchpotato.core.media.movie package
Subpackages
couchpotato.core.media.movie.charts package
Submodules
couchpotato.core.media.movie.charts.main module
class couchpotato.core.media.movie.charts.main.Charts[source]

Bases: couchpotato.core.plugins.base.Plugin

automationView(force_update=False, **kwargs)
ignoreView(imdb=None, **kwargs)
Module contents
couchpotato.core.media.movie.charts.autoload()[source]
couchpotato.core.media.movie.providers package
Subpackages
couchpotato.core.media.movie.providers.automation package
Subpackages
couchpotato.core.media.movie.providers.automation.trakt package
Submodules
couchpotato.core.media.movie.providers.automation.trakt.main module
class couchpotato.core.media.movie.providers.automation.trakt.main.Trakt[source]

Bases: couchpotato.core.media.movie.providers.automation.base.Automation, couchpotato.core.media.movie.providers.automation.trakt.main.TraktBase

getAuthorizationUrl(host=None, **kwargs)
getCredentials(**kwargs)
getIMDBids()
getWatchlist()
refreshToken()
urls = {'watchlist': 'sync/watchlist/movies/', 'oauth': 'https://api.couchpota.to/authorize/trakt/', 'refresh_token': 'https://api.couchpota.to/authorize/trakt_refresh/'}
class couchpotato.core.media.movie.providers.automation.trakt.main.TraktBase[source]

Bases: couchpotato.core.media._base.providers.base.Provider

api_url = 'https://api-v2launch.trakt.tv/'
call(method_url, post_data=None)
client_id = '8a54ed7b5e1b56d874642770ad2e8b73e2d09d6e993c3a92b1e89690bb1c9014'
Module contents
couchpotato.core.media.movie.providers.automation.trakt.autoload()[source]
Submodules
couchpotato.core.media.movie.providers.automation.base module
class couchpotato.core.media.movie.providers.automation.base.Automation[source]

Bases: couchpotato.core.media._base.providers.automation.base.AutomationBase

canCheck()
chart_enabled_option = 'chart_display_enabled'
enabled_option = 'automation_enabled'
getChartList()
getIMDBids()
getMinimal(min_type)
http_time_between_calls = 2
interval = 1800
isMinimalMovie(movie)
last_checked = 0
search(name, year=None, imdb_only=False)
couchpotato.core.media.movie.providers.automation.bluray module
class couchpotato.core.media.movie.providers.automation.bluray.Bluray[source]

Bases: couchpotato.core.media.movie.providers.automation.base.Automation, couchpotato.core.helpers.rss.RSS

backlog_url = 'http://www.blu-ray.com/movies/movies.php?show=newreleases&page=%s'
chart_order = 1
display_url = 'http://www.blu-ray.com/movies/movies.php?show=newreleases'
getChartList()
getIMDBids()
interval = 1800
rss_url = 'http://www.blu-ray.com/rss/newreleasesfeed.xml'
couchpotato.core.media.movie.providers.automation.crowdai module
class couchpotato.core.media.movie.providers.automation.crowdai.CrowdAI[source]

Bases: couchpotato.core.media.movie.providers.automation.base.Automation, couchpotato.core.helpers.rss.RSS

getIMDBids()
interval = 1800
couchpotato.core.media.movie.providers.automation.flixster module
class couchpotato.core.media.movie.providers.automation.flixster.Flixster[source]

Bases: couchpotato.core.media.movie.providers.automation.base.Automation

getIMDBids()
getWatchlist()
interval = 60
url = 'http://www.flixster.com/api/users/%s/movies/ratings?scoreTypes=wts'
couchpotato.core.media.movie.providers.automation.goodfilms module
class couchpotato.core.media.movie.providers.automation.goodfilms.Goodfilms[source]

Bases: couchpotato.core.media.movie.providers.automation.base.Automation

getIMDBids()
getWatchlist()
interval = 1800
url = 'https://goodfil.ms/%s/queue?page=%d&without_layout=1'
couchpotato.core.media.movie.providers.automation.hummingbird module
class couchpotato.core.media.movie.providers.automation.hummingbird.Hummingbird[source]

Bases: couchpotato.core.media.movie.providers.automation.base.Automation

getIMDBids()
getWatchlist()
couchpotato.core.media.movie.providers.automation.imdb module
class couchpotato.core.media.movie.providers.automation.imdb.IMDB[source]

Bases: couchpotato.core.media._base.providers.base.MultiProvider

getTypes()
class couchpotato.core.media.movie.providers.automation.imdb.IMDBAutomation[source]

Bases: couchpotato.core.media.movie.providers.automation.imdb.IMDBBase

enabled_option = 'automation_providers_enabled'
getIMDBids()
class couchpotato.core.media.movie.providers.automation.imdb.IMDBBase[source]

Bases: couchpotato.core.media.movie.providers.automation.base.Automation, couchpotato.core.helpers.rss.RSS

charts = {'top250': {'url': 'http://www.imdb.com/chart/top', 'order': 3, 'name': 'IMDB - Top 250 Movies'}, 'theater': {'url': 'http://www.imdb.com/movies-in-theaters/', 'order': 1, 'name': 'IMDB - Movies in Theaters'}, 'boxoffice': {'url': 'http://www.imdb.com/boxoffice/', 'order': 2, 'name': 'IMDB - Box Office'}}
getFromURL(url)
getInfo(imdb_id)
interval = 1800
class couchpotato.core.media.movie.providers.automation.imdb.IMDBCharts[source]

Bases: couchpotato.core.media.movie.providers.automation.imdb.IMDBBase

getChartList()
class couchpotato.core.media.movie.providers.automation.imdb.IMDBWatchlist[source]

Bases: couchpotato.core.media.movie.providers.automation.imdb.IMDBBase

enabled_option = 'automation_enabled'
getIMDBids()
couchpotato.core.media.movie.providers.automation.itunes module
class couchpotato.core.media.movie.providers.automation.itunes.ITunes[source]

Bases: couchpotato.core.media.movie.providers.automation.base.Automation, couchpotato.core.helpers.rss.RSS

getIMDBids()
interval = 1800
couchpotato.core.media.movie.providers.automation.kinepolis module
class couchpotato.core.media.movie.providers.automation.kinepolis.Kinepolis[source]

Bases: couchpotato.core.media.movie.providers.automation.base.Automation, couchpotato.core.helpers.rss.RSS

getIMDBids()
interval = 1800
rss_url = 'http://kinepolis.be/nl/top10-box-office/feed'
couchpotato.core.media.movie.providers.automation.letterboxd module
class couchpotato.core.media.movie.providers.automation.letterboxd.Letterboxd[source]

Bases: couchpotato.core.media.movie.providers.automation.base.Automation

getIMDBids()
getWatchlist()
interval = 1800
pattern = <_sre.SRE_Pattern object>
url = 'http://letterboxd.com/%s/watchlist/'
couchpotato.core.media.movie.providers.automation.moviemeter module
class couchpotato.core.media.movie.providers.automation.moviemeter.Moviemeter[source]

Bases: couchpotato.core.media.movie.providers.automation.base.Automation, couchpotato.core.helpers.rss.RSS

getIMDBids()
interval = 1800
rss_url = 'http://www.moviemeter.nl/rss/cinema'
couchpotato.core.media.movie.providers.automation.movies_io module
class couchpotato.core.media.movie.providers.automation.movies_io.MoviesIO[source]

Bases: couchpotato.core.media.movie.providers.automation.base.Automation, couchpotato.core.helpers.rss.RSS

getIMDBids()
interval = 1800
couchpotato.core.media.movie.providers.automation.popularmovies module
class couchpotato.core.media.movie.providers.automation.popularmovies.PopularMovies[source]

Bases: couchpotato.core.media.movie.providers.automation.base.Automation

getIMDBids()
interval = 1800
url = 'https://s3.amazonaws.com/popular-movies/movies.json'
Module contents
couchpotato.core.media.movie.providers.info package
Submodules
couchpotato.core.media.movie.providers.info.couchpotatoapi module
class couchpotato.core.media.movie.providers.info.couchpotatoapi.CouchPotatoApi[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider

api_version = 1
call(url, **kwargs)
getInfo(identifier=None, adding=False, **kwargs)
getMessages(last_check=0)
getReleaseDate(identifier=None)
getRequestHeaders()
getSourceUrl(repo=None, repo_name=None, branch=None)
getSuggestions(movies=None, ignore=None)
http_time_between_calls = 0
isMovie(identifier=None, adding=False, **kwargs)
search(q, limit=5)
urls = {'info': 'https://api.couchpota.to/info/%s/', 'search': 'https://api.couchpota.to/search/%s/', 'eta': 'https://api.couchpota.to/eta/%s/', 'updater': 'https://api.couchpota.to/updater/?%s', 'suggest': 'https://api.couchpota.to/suggest/', 'validate': 'https://api.couchpota.to/validate/%s/', 'messages': 'https://api.couchpota.to/messages/?%s', 'is_movie': 'https://api.couchpota.to/ismovie/%s/'}
validate(name=None)
couchpotato.core.media.movie.providers.info.fanarttv module
class couchpotato.core.media.movie.providers.info.fanarttv.FanartTV[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider

MAX_EXTRAFANART = 20
getArt(identifier=None, extended=True, **kwargs)
http_time_between_calls = 0
isDisabled()
urls = {'api': 'http://webservice.fanart.tv/v3/movies/%s?api_key=b28b14e9be662e027cfbc7c3dd600405'}
couchpotato.core.media.movie.providers.info.omdbapi module
class couchpotato.core.media.movie.providers.info.omdbapi.OMDBAPI[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider

getInfo(identifier=None, **kwargs)
http_time_between_calls = 0
parseMovie(movie)
runtimeToMinutes(runtime_str)
search(q, limit=12)
urls = {'info': 'http://www.omdbapi.com/?type=movie&i=%s', 'search': 'http://www.omdbapi.com/?type=movie&%s'}
couchpotato.core.media.movie.providers.info.themoviedb module
class couchpotato.core.media.movie.providers.info.themoviedb.TheMovieDb[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider

config()
configuration = {'images': {'secure_base_url': 'https://image.tmdb.org/t/p/'}}
getImage(movie, type='poster', size='poster')
getInfo(identifier=None, extended=True, **kwargs)
getMultImages(movie, type='backdrops', size='original')
http_time_between_calls = 0.35
isDisabled()
parseMovie(movie, extended=True)
request(call='', params={}, return_key=None)
search(q, limit=3)

Find movie by name

Module contents
couchpotato.core.media.movie.providers.metadata package
Submodules
couchpotato.core.media.movie.providers.metadata.base module
class couchpotato.core.media.movie.providers.metadata.base.MovieMetaData[source]

Bases: couchpotato.core.media._base.providers.metadata.base.MetaDataBase

create(message=None, group=None)
enabled_option = 'meta_enabled'
getBanner(movie_info=None, data=None, i=0)
getBannerName(name, root, i)
getClearArt(movie_info=None, data=None, i=0)
getClearArtName(name, root, i)
getDiscArt(movie_info=None, data=None, i=0)
getDiscArtName(name, root, i)
getExtraFanart(movie_info=None, data=None, i=0)
getExtraFanartName(name, root, i)
getExtraThumbs(movie_info=None, data=None, i=0)
getExtraThumbsName(name, root, i)
getFanart(movie_info=None, data=None, i=0)
getFanartName(name, root, i)
getLandscape(movie_info=None, data=None, i=0)
getLandscapeName(name, root, i)
getLogoName(name, root, i)
getNfo(movie_info=None, data=None, i=0)
getNfoName(name, root, i)
getRootName(data=None)
getThumbnail(movie_info=None, data=None, wanted_file_type='poster_original', i=0)
getThumbnailName(name, root, i)
couchpotato.core.media.movie.providers.metadata.mediabrowser module
class couchpotato.core.media.movie.providers.metadata.mediabrowser.MediaBrowser[source]

Bases: couchpotato.core.media.movie.providers.metadata.base.MovieMetaData

getFanartName(name, root, i)
getThumbnailName(name, root, i)
couchpotato.core.media.movie.providers.metadata.ps3 module
class couchpotato.core.media.movie.providers.metadata.ps3.SonyPS3[source]

Bases: couchpotato.core.media.movie.providers.metadata.base.MovieMetaData

getThumbnailName(name, root, i)
couchpotato.core.media.movie.providers.metadata.wdtv module
class couchpotato.core.media.movie.providers.metadata.wdtv.WdtvLive[source]

Bases: couchpotato.core.media.movie.providers.metadata.base.MovieMetaData

createMetaName(basename, name, root)
getNfo(movie_info=None, data=None, i=0)
getNfoName(name, root, i)
getThumbnailName(name, root, i)
couchpotato.core.media.movie.providers.metadata.wmc module
class couchpotato.core.media.movie.providers.metadata.wmc.WindowsMediaCenter[source]

Bases: couchpotato.core.media.movie.providers.metadata.base.MovieMetaData

getThumbnailName(name, root, i)
couchpotato.core.media.movie.providers.metadata.xbmc module
class couchpotato.core.media.movie.providers.metadata.xbmc.XBMC[source]

Bases: couchpotato.core.media.movie.providers.metadata.base.MovieMetaData

createMetaName(basename, name, root)
createMetaNameMult(basename, name, root, i)
getBannerName(name, root, i)
getClearArtName(name, root, i)
getDiscArtName(name, root, i)
getExtraFanartName(name, root, i)
getExtraThumbsName(name, root, i)
getFanartName(name, root, i)
getLandscapeName(name, root, i)
getLogoName(name, root, i)
getNfo(movie_info=None, data=None, i=0)
getNfoName(name, root, i)
getThumbnailName(name, root, i)
Module contents
couchpotato.core.media.movie.providers.nzb package
Submodules
couchpotato.core.media.movie.providers.nzb.binsearch module
class couchpotato.core.media.movie.providers.nzb.binsearch.BinSearch[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.nzb.binsearch.Base

buildUrl(media, quality)
couchpotato.core.media.movie.providers.nzb.newznab module
class couchpotato.core.media.movie.providers.nzb.newznab.Newznab[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.nzb.newznab.Base

buildUrl(media, host)
couchpotato.core.media.movie.providers.nzb.nzbclub module
class couchpotato.core.media.movie.providers.nzb.nzbclub.NZBClub[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.nzb.nzbclub.Base

buildUrl(media)
couchpotato.core.media.movie.providers.nzb.omgwtfnzbs module
class couchpotato.core.media.movie.providers.nzb.omgwtfnzbs.OMGWTFNZBs[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.nzb.omgwtfnzbs.Base

Module contents
couchpotato.core.media.movie.providers.torrent package
Submodules
couchpotato.core.media.movie.providers.torrent.alpharatio module
class couchpotato.core.media.movie.providers.torrent.alpharatio.AlphaRatio[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.alpharatio.Base

buildUrl(media, quality)
cat_backup_id = 6
cat_ids = [([7, 9], ['bd50']), ([7, 9], ['720p', '1080p']), ([6, 8], ['dvdr']), ([6, 8], ['brrip', 'dvdrip'])]
couchpotato.core.media.movie.providers.torrent.awesomehd module
class couchpotato.core.media.movie.providers.torrent.awesomehd.AwesomeHD[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.awesomehd.Base

couchpotato.core.media.movie.providers.torrent.bithdtv module
class couchpotato.core.media.movie.providers.torrent.bithdtv.BiTHDTV[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.bithdtv.Base

buildUrl(media, quality)[source]
cat_backup_id = 7
cat_ids = [([2], ['bd50'])]
couchpotato.core.media.movie.providers.torrent.bitsoup module
class couchpotato.core.media.movie.providers.torrent.bitsoup.Bitsoup[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.bitsoup.Base

buildUrl(title, media, quality)[source]
cat_backup_id = 0
cat_ids = [([17], ['3d']), ([80], ['720p', '1080p']), ([20], ['dvdr']), ([19], ['brrip', 'dvdrip'])]
couchpotato.core.media.movie.providers.torrent.hd4free module
class couchpotato.core.media.movie.providers.torrent.hd4free.HD4Free[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.hd4free.Base

couchpotato.core.media.movie.providers.torrent.hdaccess module
class couchpotato.core.media.movie.providers.torrent.hdaccess.HDAccess[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.hdaccess.Base

couchpotato.core.media.movie.providers.torrent.hdbits module
class couchpotato.core.media.movie.providers.torrent.hdbits.HDBits[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.hdbits.Base

couchpotato.core.media.movie.providers.torrent.ilovetorrents module
class couchpotato.core.media.movie.providers.torrent.ilovetorrents.ILoveTorrents[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.ilovetorrents.Base

couchpotato.core.media.movie.providers.torrent.iptorrents module
class couchpotato.core.media.movie.providers.torrent.iptorrents.IPTorrents[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.iptorrents.Base

buildUrl(title, media, quality)
cat_ids = [([87], ['3d']), ([48], ['720p', '1080p', 'bd50']), ([72], ['cam', 'ts', 'tc', 'r5', 'scr']), ([7, 48, 20], ['dvdrip', 'brrip']), ([6], ['dvdr'])]
couchpotato.core.media.movie.providers.torrent.kickasstorrents module
class couchpotato.core.media.movie.providers.torrent.kickasstorrents.KickAssTorrents[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.kickasstorrents.Base

couchpotato.core.media.movie.providers.torrent.morethantv module
class couchpotato.core.media.movie.providers.torrent.morethantv.MoreThanTV[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.morethantv.Base

couchpotato.core.media.movie.providers.torrent.passthepopcorn module
class couchpotato.core.media.movie.providers.torrent.passthepopcorn.PassThePopcorn[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.passthepopcorn.Base

post_search_filters = {'dvdr': {'Codec': ['DVD5', 'DVD9']}, 'bd50': {'Codec': ['BD50']}, 'dvdrip': {'Source': ['DVD'], 'Codec': ['!DVD5', '!DVD9']}, 'scr': {'Source': ['DVD-Screener']}, 'r5': {'Source': ['R5']}, '1080p': {'Resolution': ['1080p']}, '720p': {'Resolution': ['720p']}, 'ts': {'Source': ['TS']}, 'cam': {'Source': ['CAM']}, 'brrip': {'Container': ['!ISO'], 'Quality': ['High Definition']}, 'tc': {'Source': ['TC']}}
quality_search_params = {'dvdr': {'resolution': 'anysd'}, 'bd50': {'media': 'Blu-ray', 'format': 'BD50'}, 'dvdrip': {'media': 'DVD'}, 'scr': {'media': 'DVD-Screener'}, 'r5': {'media': 'R5'}, '1080p': {'resolution': '1080p'}, '720p': {'resolution': '720p'}, 'ts': {'media': 'TS'}, 'cam': {'media': 'CAM'}, 'brrip': {'resolution': 'anyhd'}, 'tc': {'media': 'TC'}}
couchpotato.core.media.movie.providers.torrent.rarbg module
class couchpotato.core.media.movie.providers.torrent.rarbg.Rarbg[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.rarbg.Base

couchpotato.core.media.movie.providers.torrent.sceneaccess module
class couchpotato.core.media.movie.providers.torrent.sceneaccess.SceneAccess[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.sceneaccess.Base

buildUrl(title, media, quality)
cat_ids = [([22], ['720p', '1080p']), ([7], ['cam', 'ts', 'dvdrip', 'tc', 'r5', 'scr', 'brrip']), ([8], ['dvdr'])]
couchpotato.core.media.movie.providers.torrent.scenetime module
class couchpotato.core.media.movie.providers.torrent.scenetime.SceneTime[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.scenetime.Base

couchpotato.core.media.movie.providers.torrent.thepiratebay module
class couchpotato.core.media.movie.providers.torrent.thepiratebay.ThePirateBay[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.thepiratebay.Base

buildUrl(media, page, cats)
cat_ids = [([209], ['3d']), ([207], ['720p', '1080p', 'bd50']), ([201], ['cam', 'ts', 'dvdrip', 'tc', 'r5', 'scr']), ([201, 207], ['brrip']), ([202], ['dvdr'])]
couchpotato.core.media.movie.providers.torrent.torrentbytes module
class couchpotato.core.media.movie.providers.torrent.torrentbytes.TorrentBytes[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.torrentbytes.Base

couchpotato.core.media.movie.providers.torrent.torrentday module
class couchpotato.core.media.movie.providers.torrent.torrentday.TorrentDay[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.torrentday.Base

cat_ids = [([11], ['720p', '1080p']), ([1, 21, 25], ['cam', 'ts', 'dvdrip', 'tc', 'r5', 'scr', 'brrip']), ([3], ['dvdr']), ([5], ['bd50'])]
couchpotato.core.media.movie.providers.torrent.torrentleech module
class couchpotato.core.media.movie.providers.torrent.torrentleech.TorrentLeech[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.torrentleech.Base

buildUrl(title, media, quality)
cat_ids = [([13], ['720p', '1080p', 'bd50']), ([8], ['cam']), ([9], ['ts', 'tc']), ([10], ['r5', 'scr']), ([11], ['dvdrip']), ([13, 14], ['brrip']), ([12], ['dvdr'])]
couchpotato.core.media.movie.providers.torrent.torrentpotato module
class couchpotato.core.media.movie.providers.torrent.torrentpotato.TorrentPotato[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.torrentpotato.Base

buildUrl(media, host)
couchpotato.core.media.movie.providers.torrent.torrentshack module
class couchpotato.core.media.movie.providers.torrent.torrentshack.TorrentShack[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.torrentshack.Base

buildUrl(media, quality)
cat_backup_id = 400
cat_ids = [([970, 320], ['bd50']), ([300, 320], ['720p', '1080p']), ([350], ['dvdr']), ([400], ['brrip', 'dvdrip'])]
couchpotato.core.media.movie.providers.torrent.torrentz module
class couchpotato.core.media.movie.providers.torrent.torrentz.Torrentz[source]

Bases: couchpotato.core.media.movie.providers.base.MovieProvider, couchpotato.core.media._base.providers.torrent.torrentz.Base

buildUrl(title, media, quality)
Module contents
couchpotato.core.media.movie.providers.trailer package
Submodules
couchpotato.core.media.movie.providers.trailer.base module
class couchpotato.core.media.movie.providers.trailer.base.TrailerProvider[source]

Bases: couchpotato.core.media._base.providers.base.Provider

search(*args, **kwargs)
type = 'trailer'
couchpotato.core.media.movie.providers.trailer.hdtrailers module
class couchpotato.core.media.movie.providers.trailer.hdtrailers.HDTrailers[source]

Bases: couchpotato.core.media.movie.providers.trailer.base.TrailerProvider

findByProvider(data, provider)
findViaAlternative(group)
movieUrlName(string)
only_tables_tags = <bs4.element.SoupStrainer object>
providers = ['apple.ico', 'yahoo.ico', 'moviefone.ico', 'myspace.ico', 'favicon.ico']
search(group)
urls = {'api': 'http://www.hd-trailers.net/movie/%s/', 'backup': 'http://www.hd-trailers.net/blog/'}
Module contents
couchpotato.core.media.movie.providers.userscript package
Submodules
couchpotato.core.media.movie.providers.userscript.allocine module
class couchpotato.core.media.movie.providers.userscript.allocine.AlloCine[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

getMovie(url)
includes = ['http://www.allocine.fr/film/*']
couchpotato.core.media.movie.providers.userscript.appletrailers module
class couchpotato.core.media.movie.providers.userscript.appletrailers.AppleTrailers[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

getMovie(url)
includes = ['http://trailers.apple.com/trailers/*']
couchpotato.core.media.movie.providers.userscript.criticker module
class couchpotato.core.media.movie.providers.userscript.criticker.Criticker[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

includes = ['http://www.criticker.com/film/*']
couchpotato.core.media.movie.providers.userscript.filmcentrum module
class couchpotato.core.media.movie.providers.userscript.filmcentrum.FilmCentrum[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

includes = ['*://filmcentrum.nl/films/*']
couchpotato.core.media.movie.providers.userscript.filmstarts module
class couchpotato.core.media.movie.providers.userscript.filmstarts.Filmstarts[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

getMovie(url)
includes = ['*://www.filmstarts.de/kritiken/*']
couchpotato.core.media.movie.providers.userscript.filmweb module
class couchpotato.core.media.movie.providers.userscript.filmweb.Filmweb[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

getMovie(url)
includes = ['http://www.filmweb.pl/film/*']
version = 3
couchpotato.core.media.movie.providers.userscript.flickchart module
class couchpotato.core.media.movie.providers.userscript.flickchart.Flickchart[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

getMovie(url)
includes = ['http://www.flickchart.com/movie/*']
version = 2
couchpotato.core.media.movie.providers.userscript.imdb module
class couchpotato.core.media.movie.providers.userscript.imdb.IMDB[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

getMovie(url)
includes = ['*://*.imdb.com/title/tt*', '*://imdb.com/title/tt*']
couchpotato.core.media.movie.providers.userscript.letterboxd module
class couchpotato.core.media.movie.providers.userscript.letterboxd.Letterboxd[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

includes = ['*://letterboxd.com/film/*']
couchpotato.core.media.movie.providers.userscript.moviemeter module
class couchpotato.core.media.movie.providers.userscript.moviemeter.MovieMeter[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

getMovie(url)
includes = ['*://*.moviemeter.nl/film/*', '*://moviemeter.nl/film/*']
version = 3
couchpotato.core.media.movie.providers.userscript.moviesio module
class couchpotato.core.media.movie.providers.userscript.moviesio.MoviesIO[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

includes = ['*://movies.io/m/*']
couchpotato.core.media.movie.providers.userscript.reddit module
class couchpotato.core.media.movie.providers.userscript.reddit.Reddit[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

getMovie(url)
includes = ['*://www.reddit.com/r/Ijustwatched/comments/*']
couchpotato.core.media.movie.providers.userscript.rottentomatoes module
class couchpotato.core.media.movie.providers.userscript.rottentomatoes.RottenTomatoes[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

excludes = ['*://www.rottentomatoes.com/m/*/*/']
getMovie(url)
includes = ['*://www.rottentomatoes.com/m/*']
version = 4
couchpotato.core.media.movie.providers.userscript.tmdb module
class couchpotato.core.media.movie.providers.userscript.tmdb.TMDB[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

getMovie(url)
includes = ['*://www.themoviedb.org/movie/*']
version = 2
couchpotato.core.media.movie.providers.userscript.trakt module
class couchpotato.core.media.movie.providers.userscript.trakt.Trakt[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

excludes = ['*://trakt.tv/movies/*/*', '*://*.trakt.tv/movies/*/*']
includes = ['*://trakt.tv/movies/*', '*://*.trakt.tv/movies/*']
version = 2
couchpotato.core.media.movie.providers.userscript.youteather module
class couchpotato.core.media.movie.providers.userscript.youteather.YouTheater[source]

Bases: couchpotato.core.media._base.providers.userscript.base.UserscriptBase

getMovie(url)[source]
id_re = <_sre.SRE_Pattern object>
includes = ['http://www.youtheater.com/view.php?id=*', 'http://youtheater.com/view.php?id=*', 'http://www.sratim.co.il/view.php?id=*', 'http://sratim.co.il/view.php?id=*']
Module contents
Submodules
couchpotato.core.media.movie.providers.base module
class couchpotato.core.media.movie.providers.base.MovieProvider[source]

Bases: couchpotato.core.media._base.providers.info.base.BaseInfoProvider

type = 'movie'
Module contents
Submodules
couchpotato.core.media.movie.library module
class couchpotato.core.media.movie.library.MovieLibraryPlugin[source]

Bases: couchpotato.core.media._base.library.base.LibraryBase

query(media, first=True, include_year=True, **kwargs)
couchpotato.core.media.movie.searcher module
class couchpotato.core.media.movie.searcher.MovieSearcher[source]

Bases: couchpotato.core.media._base.searcher.base.SearcherBase, couchpotato.core.media.movie.MovieTypeBase

correctRelease(nzb=None, media=None, quality=None, **kwargs)
couldBeReleased(is_pre_release, dates, year=None)
getSearchTitle(media)
in_progress = False
searchAll(manual=False)
searchAllView(**kwargs)
single(movie, search_protocols=None, manual=False, force_download=False)
tryNextRelease(media_id, manual=False, force_download=False)
tryNextReleaseView(media_id=None, **kwargs)
exception couchpotato.core.media.movie.searcher.SearchSetupError[source]

Bases: exceptions.Exception

couchpotato.core.media.movie.suggestion module
class couchpotato.core.media.movie.suggestion.Suggestion[source]

Bases: couchpotato.core.plugins.base.Plugin

ignoreView(imdb=None, limit=6, remove_only=False, mark_seen=False, **kwargs)
suggestView(limit=6, **kwargs)
updateSuggestionCache(ignore_imdb=None, limit=6, ignored=None, seen=None)
Module contents
class couchpotato.core.media.movie.MovieTypeBase[source]

Bases: couchpotato.core.media.MediaBase

Module contents
class couchpotato.core.media.MediaBase[source]

Bases: couchpotato.core.plugins.base.Plugin

createNotifyFront(media_id)
createOnComplete(media_id)
getDefaultTitle(info, default_title=None)
getPoster(media, image_urls)
getType()
initType()
couchpotato.core.notifications package
Subpackages
couchpotato.core.notifications.core package
Submodules
couchpotato.core.notifications.core.index module
class couchpotato.core.notifications.core.index.NotificationIndex(*args, **kwargs)[source]

Bases: CodernityDB.tree_index.TreeBasedIndex

custom_header = 'from CodernityDB.tree_index import TreeBasedIndex\nimport time'
make_key(key)[source]
make_key_value(data)[source]
class couchpotato.core.notifications.core.index.NotificationUnreadIndex(*args, **kwargs)[source]

Bases: CodernityDB.tree_index.TreeBasedIndex

custom_header = 'from CodernityDB.tree_index import TreeBasedIndex\nimport time'
make_key(key)[source]
make_key_value(data)[source]
couchpotato.core.notifications.core.main module
class couchpotato.core.notifications.core.main.CoreNotifier[source]

Bases: couchpotato.core.notifications.base.Notification

addListener(callback, last_id=None)
checkMessages()
clean()
cleanMessages()
frontend(type='notification', data=None, message=None)
getMessages(last_id)
listView(limit_offset=None, **kwargs)
listen_to = ['media.available', 'renamer.after', 'movie.snatched', 'updater.available', 'updater.updated', 'core.message', 'core.message.important']
listener(init=False, **kwargs)
m_lock = None
markAsRead(ids=None, **kwargs)
notify(message='', data=None, listener=None)
removeListener(callback)
Module contents
couchpotato.core.notifications.core.autoload()[source]
couchpotato.core.notifications.plex package
Submodules
couchpotato.core.notifications.plex.client module
class couchpotato.core.notifications.plex.client.PlexClientHTTP(plex)[source]

Bases: couchpotato.core.notifications.plex.client.PlexClientProtocol

notify(client, message)[source]
request(command, client)[source]
class couchpotato.core.notifications.plex.client.PlexClientJSON(plex)[source]

Bases: couchpotato.core.notifications.plex.client.PlexClientProtocol

notify(client, message)[source]
request(method, params, client)[source]
class couchpotato.core.notifications.plex.client.PlexClientProtocol(plex)[source]

Bases: object

notify(client, message)[source]
couchpotato.core.notifications.plex.main module
class couchpotato.core.notifications.plex.main.Plex[source]

Bases: couchpotato.core.notifications.base.Notification

addToLibrary(message=None, group=None)
getClientNames()
http_time_between_calls = 0
notify(message='', data=None, listener=None)
notifyClients(message, client_names)
test(**kwargs)
couchpotato.core.notifications.plex.server module
class couchpotato.core.notifications.plex.server.PlexServer(plex)[source]

Bases: object

createHost(host, port=None)[source]
refresh(section_types=None)[source]
request(path, data_type='xml')[source]
staleClients()[source]
updateClients(client_names)[source]
Module contents
couchpotato.core.notifications.plex.autoload()[source]
couchpotato.core.notifications.twitter package
Submodules
couchpotato.core.notifications.twitter.main module
class couchpotato.core.notifications.twitter.main.Twitter[source]

Bases: couchpotato.core.notifications.base.Notification

consumer_key = '3POVsO3KW90LKZXyzPOjQ'
consumer_secret = 'Qprb94hx9ucXvD4Wvg2Ctsk4PDK7CcQAKgCELXoyIjE'
getAuthorizationUrl(host=None, **kwargs)
getCredentials(oauth_verifier, **kwargs)
notify(message='', data=None, listener=None)
request_token = None
urls = {'access': 'https://api.twitter.com/oauth/access_token', 'authorize': 'https://api.twitter.com/oauth/authorize', 'request': 'https://api.twitter.com/oauth/request_token'}
Module contents
couchpotato.core.notifications.twitter.autoload()[source]
Submodules
couchpotato.core.notifications.androidpn module
class couchpotato.core.notifications.androidpn.AndroidPN[source]

Bases: couchpotato.core.notifications.base.Notification

notify(message='', data=None, listener=None)
couchpotato.core.notifications.base module
class couchpotato.core.notifications.base.Notification[source]

Bases: couchpotato.core.media._base.providers.base.Provider

createNotifyHandler(listener)
default_title = 'CouchPotato'
dont_listen_to = []
getNotificationImage(size='small')
listen_to = ['media.available', 'renamer.after', 'movie.snatched', 'updater.available', 'updater.updated', 'core.message.important']
notify(message='', data=None, listener=None)
test(**kwargs)
testNotifyName()
test_message = 'ZOMG Lazors Pewpewpew!'
type = 'notification'
couchpotato.core.notifications.boxcar2 module
class couchpotato.core.notifications.boxcar2.Boxcar2[source]

Bases: couchpotato.core.notifications.base.Notification

isEnabled()
notify(message='', data=None, listener=None)
url = 'https://new.boxcar.io/api/notifications'
couchpotato.core.notifications.email_ module
class couchpotato.core.notifications.email_.Email[source]

Bases: couchpotato.core.notifications.base.Notification

notify(message='', data=None, listener=None)
couchpotato.core.notifications.emby module
class couchpotato.core.notifications.emby.Emby[source]

Bases: couchpotato.core.notifications.base.Notification

notify(message='', data=None, listener=None)
test(**kwargs)
couchpotato.core.notifications.growl module
class couchpotato.core.notifications.growl.Growl[source]

Bases: couchpotato.core.notifications.base.Notification

notify(message='', data=None, listener=None)
register()
registered = False
couchpotato.core.notifications.nmj module
class couchpotato.core.notifications.nmj.NMJ[source]

Bases: couchpotato.core.notifications.base.Notification

addToLibrary(message=None, group=None)
autoConfig(host='localhost', **kwargs)
failed()
test(**kwargs)
couchpotato.core.notifications.notifymyandroid module
class couchpotato.core.notifications.notifymyandroid.NotifyMyAndroid[source]

Bases: couchpotato.core.notifications.base.Notification

notify(message='', data=None, listener=None)
couchpotato.core.notifications.prowl module
class couchpotato.core.notifications.prowl.Prowl[source]

Bases: couchpotato.core.notifications.base.Notification

notify(message='', data=None, listener=None)
urls = {'api': 'https://api.prowlapp.com/publicapi/add'}
couchpotato.core.notifications.pushalot module
class couchpotato.core.notifications.pushalot.Pushalot[source]

Bases: couchpotato.core.notifications.base.Notification

notify(message='', data=None, listener=None)
urls = {'api': 'https://pushalot.com/api/sendmessage'}
couchpotato.core.notifications.pushbullet module
class couchpotato.core.notifications.pushbullet.Pushbullet[source]

Bases: couchpotato.core.notifications.base.Notification

getChannels()
getDevices()
notify(message='', data=None, listener=None)
request(method, **kwargs)
url = 'https://api.pushbullet.com/v2/%s'
couchpotato.core.notifications.pushover module
class couchpotato.core.notifications.pushover.Pushover[source]

Bases: couchpotato.core.notifications.base.Notification

api_url = 'https://api.pushover.net'
notify(message='', data=None, listener=None)
couchpotato.core.notifications.slack module
class couchpotato.core.notifications.slack.Slack[source]

Bases: couchpotato.core.notifications.base.Notification

notify(message='', data=None, listener=None)[source]
required_confs = ('token', 'channels')
url = 'https://slack.com/api/chat.postMessage'
couchpotato.core.notifications.synoindex module
class couchpotato.core.notifications.synoindex.Synoindex[source]

Bases: couchpotato.core.notifications.base.Notification

addToLibrary(message=None, group=None)
index_path = '/usr/syno/bin/synoindex'
test(**kwargs)
couchpotato.core.notifications.telegrambot module
class couchpotato.core.notifications.telegrambot.TelegramBot[source]

Bases: couchpotato.core.notifications.base.Notification

TELEGRAM_API = 'https://api.telegram.org/bot%s/%s'
notify(message='', data=None, listener=None)
couchpotato.core.notifications.toasty module
class couchpotato.core.notifications.toasty.Toasty[source]

Bases: couchpotato.core.notifications.base.Notification

notify(message='', data=None, listener=None)
urls = {'api': 'http://api.supertoasty.com/notify/%s?%s'}
couchpotato.core.notifications.trakt module
class couchpotato.core.notifications.trakt.Trakt[source]

Bases: couchpotato.core.notifications.base.Notification, couchpotato.core.media.movie.providers.automation.trakt.main.TraktBase

enabled_option = 'notification_enabled'
listen_to = ['renamer.after']
notify(message='', data=None, listener=None)
urls = {'test': 'sync/last_activities', 'unwatchlist': 'sync/watchlist/remove', 'library': 'sync/collection'}
couchpotato.core.notifications.webhook module
class couchpotato.core.notifications.webhook.Webhook[source]

Bases: couchpotato.core.notifications.base.Notification

notify(message='', data=None, listener=None)
couchpotato.core.notifications.xbmc module
class couchpotato.core.notifications.xbmc.XBMC[source]

Bases: couchpotato.core.notifications.base.Notification

getXBMCJSONversion(host, message='')
http_time_between_calls = 0
listen_to = ['renamer.after', 'movie.snatched']
notify(message='', data=None, listener=None)
notifyXBMCnoJSON(host, data)
request(host, do_requests)
use_json_notifications = {}
couchpotato.core.notifications.xmpp_ module
class couchpotato.core.notifications.xmpp_.Xmpp[source]

Bases: couchpotato.core.notifications.base.Notification

notify(message='', data=None, listener=None)
Module contents
couchpotato.core.plugins package
Subpackages
couchpotato.core.plugins.category package
Submodules
couchpotato.core.plugins.category.index module
class couchpotato.core.plugins.category.index.CategoryIndex(*args, **kwargs)[source]

Bases: CodernityDB.tree_index.TreeBasedIndex

make_key(key)[source]
make_key_value(data)[source]
class couchpotato.core.plugins.category.index.CategoryMediaIndex(*args, **kwargs)[source]

Bases: CodernityDB.tree_index.TreeBasedIndex

make_key(key)[source]
make_key_value(data)[source]
couchpotato.core.plugins.category.main module
class couchpotato.core.plugins.category.main.CategoryPlugin[source]

Bases: couchpotato.core.plugins.base.Plugin

all()
allView(**kwargs)
delete(id=None, **kwargs)
removeFromMovie(category_id)
save(**kwargs)
saveOrder(**kwargs)
Module contents
couchpotato.core.plugins.category.autoload()[source]
couchpotato.core.plugins.log package
Submodules
couchpotato.core.plugins.log.main module
class couchpotato.core.plugins.log.main.Logging[source]

Bases: couchpotato.core.plugins.base.Plugin

clear(**kwargs)
get(nr=0, **kwargs)
log(type='error', **kwargs)
partial(type='all', lines=30, offset=0, **kwargs)
toList(log_content='')
Module contents
couchpotato.core.plugins.log.autoload()[source]
couchpotato.core.plugins.profile package
Submodules
couchpotato.core.plugins.profile.index module
class couchpotato.core.plugins.profile.index.ProfileIndex(*args, **kwargs)[source]

Bases: CodernityDB.tree_index.TreeBasedIndex

make_key(key)[source]
make_key_value(data)[source]
couchpotato.core.plugins.profile.main module
class couchpotato.core.plugins.profile.main.ProfilePlugin[source]

Bases: couchpotato.core.plugins.base.Plugin

all()
allView(**kwargs)
default()
delete(id=None, **kwargs)
fill()
forceDefaults()
save(**kwargs)
saveOrder(**kwargs)
Module contents
couchpotato.core.plugins.profile.autoload()[source]
couchpotato.core.plugins.quality package
Submodules
couchpotato.core.plugins.quality.index module
class couchpotato.core.plugins.quality.index.QualityIndex(*args, **kwargs)[source]

Bases: CodernityDB.hash_index.HashIndex

make_key(key)[source]
make_key_value(data)[source]
couchpotato.core.plugins.quality.main module
class couchpotato.core.plugins.quality.main.QualityPlugin[source]

Bases: couchpotato.core.plugins.base.Plugin

addOrder()
all()
allView(**kwargs)
cached_order = None
cached_qualities = None
calcScore(score, quality, add_score, threedscore=(0, None), penalty=0)
contains3D(quality, words, cur_file='')
containsTagScore(quality, words, cur_file='')
doTest()
fill(reorder=False)
fillBlank()
getOrder()
getQuality(identifier)
guess(files, extra=None, size=None, use_cache=True)
guessLooseScore(quality, extra=None)
guessSizeScore(quality, size=None)
isFinish(quality, profile, release_age=0)
isHigher(quality, compare_with, profile=None)
preReleases()
pre_releases = ['cam', 'ts', 'tc', 'r5', 'scr']
qualities = [{'tags': ['x264', 'h264', '2160'], 'height': 2160, 'alternative': [], 'allow_3d': True, 'hd': True, 'size': (10000, 650000), 'label': '2160p', 'width': 3840, 'ext': ['mkv'], 'allow': [], 'identifier': '2160p', 'median_size': 20000}, {'size': (20000, 60000), 'ext': ['iso', 'img'], 'label': 'BR-Disk', 'allow': ['1080p'], 'tags': ['bdmv', 'certificate', ('complete', 'bluray'), 'avc', 'mvc'], 'alternative': ['bd25', ('br', 'disk')], 'identifier': 'bd50', 'median_size': 40000, 'hd': True, 'allow_3d': True}, {'tags': ['m2ts', 'x264', 'h264', '1080'], 'height': 1080, 'alternative': [], 'allow_3d': True, 'hd': True, 'size': (4000, 20000), 'label': '1080p', 'width': 1920, 'ext': ['mkv', 'm2ts', 'ts'], 'allow': [], 'identifier': '1080p', 'median_size': 10000}, {'tags': ['x264', 'h264', '720'], 'height': 720, 'alternative': [], 'allow_3d': True, 'hd': True, 'size': (3000, 10000), 'label': '720p', 'width': 1280, 'ext': ['mkv', 'ts'], 'allow': [], 'identifier': '720p', 'median_size': 5500}, {'size': (700, 7000), 'ext': ['mp4', 'avi'], 'label': 'BR-Rip', 'allow': ['720p', '1080p'], 'tags': ['webdl', ('web', 'dl')], 'alternative': ['bdrip', ('br', 'rip'), 'hdtv', 'hdrip'], 'identifier': 'brrip', 'median_size': 2000, 'hd': True, 'allow_3d': True}, {'ext': ['iso', 'img', 'vob'], 'label': 'DVD-R', 'allow': [], 'tags': ['pal', 'ntsc', 'video_ts', 'audio_ts', ('dvd', 'r'), 'dvd9'], 'alternative': ['br2dvd', ('dvd', 'r')], 'identifier': 'dvdr', 'median_size': 4500, 'size': (3000, 10000)}, {'width': 720, 'ext': ['avi'], 'label': 'DVD-Rip', 'allow': [], 'tags': [('dvd', 'rip'), ('dvd', 'xvid'), ('dvd', 'divx')], 'alternative': [('dvd', 'rip')], 'identifier': 'dvdrip', 'median_size': 1500, 'size': (600, 2400)}, {'ext': [], 'label': 'Screener', 'allow': ['dvdr', 'dvdrip', '720p', '1080p'], 'tags': [], 'alternative': ['screener', 'dvdscr', 'ppvrip', 'dvdscreener', 'hdscr', 'webrip', ('web', 'rip')], 'identifier': 'scr', 'median_size': 700, 'size': (600, 1600)}, {'label': 'R5', 'ext': [], 'allow': ['dvdr', '720p', '1080p'], 'alternative': ['r6'], 'identifier': 'r5', 'median_size': 700, 'size': (600, 1000)}, {'label': 'TeleCine', 'ext': [], 'allow': ['720p', '1080p'], 'alternative': ['telecine'], 'identifier': 'tc', 'median_size': 700, 'size': (600, 1000)}, {'label': 'TeleSync', 'ext': [], 'allow': ['720p', '1080p'], 'alternative': ['telesync', 'hdts'], 'identifier': 'ts', 'median_size': 700, 'size': (600, 1000)}, {'label': 'Cam', 'ext': [], 'allow': ['720p', '1080p'], 'alternative': ['camrip', 'hdcam'], 'identifier': 'cam', 'median_size': 700, 'size': (600, 1000)}]
saveSize(**kwargs)
single(identifier='')
threed_tags = {'sbs': [('half', 'sbs'), 'hsbs', ('full', 'sbs'), 'fsbs'], 'ou': [('half', 'ou'), 'hou', ('full', 'ou'), 'fou'], '3d': ['2d3d', '3d2d', '3d']}
Module contents
couchpotato.core.plugins.quality.autoload()[source]
couchpotato.core.plugins.release package
Submodules
couchpotato.core.plugins.release.index module
class couchpotato.core.plugins.release.index.ReleaseDownloadIndex(*args, **kwargs)[source]

Bases: CodernityDB.hash_index.HashIndex

make_key(key)[source]
make_key_value(data)[source]
class couchpotato.core.plugins.release.index.ReleaseIDIndex(*args, **kwargs)[source]

Bases: CodernityDB.hash_index.HashIndex

make_key(key)[source]
make_key_value(data)[source]
class couchpotato.core.plugins.release.index.ReleaseIndex(*args, **kwargs)[source]

Bases: CodernityDB.tree_index.TreeBasedIndex

make_key(key)[source]
make_key_value(data)[source]
class couchpotato.core.plugins.release.index.ReleaseStatusIndex(*args, **kwargs)[source]

Bases: CodernityDB.tree_index.TreeBasedIndex

make_key(key)[source]
make_key_value(data)[source]
couchpotato.core.plugins.release.main module
class couchpotato.core.plugins.release.main.Release[source]

Bases: couchpotato.core.plugins.base.Plugin

add(group, update_info=True, update_id=None)
clean(release_id)
cleanDone()
createFromSearch(search_results, media, quality)
delete(release_id)
deleteView(id=None, **kwargs)
download(data, media, manual=False)
forMedia(media_id)
ignore(id=None, **kwargs)
manualDownload(id=None, **kwargs)
tryDownloadResult(results, media, quality_custom)
updateStatus(release_id, status=None)
withStatus(status, with_doc=True)
Module contents
couchpotato.core.plugins.release.autoload()[source]
couchpotato.core.plugins.score package
Submodules
couchpotato.core.plugins.score.main module
class couchpotato.core.plugins.score.main.Score[source]

Bases: couchpotato.core.plugins.base.Plugin

calculate(nzb, movie)

Calculate the score of a NZB, used for sorting later

couchpotato.core.plugins.score.scores module
couchpotato.core.plugins.score.scores.duplicateScore(nzb_name, movie_name)[source]
couchpotato.core.plugins.score.scores.halfMultipartScore(nzb_name)[source]
couchpotato.core.plugins.score.scores.namePositionScore(nzb_name, movie_name)[source]
couchpotato.core.plugins.score.scores.nameRatioScore(nzb_name, movie_name)[source]
couchpotato.core.plugins.score.scores.nameScore(name, year, preferred_words)[source]

Calculate score for words in the NZB name

couchpotato.core.plugins.score.scores.partialIgnoredScore(nzb_name, movie_name, ignored_words)[source]
couchpotato.core.plugins.score.scores.providerScore(provider)[source]
couchpotato.core.plugins.score.scores.sceneScore(nzb_name)[source]
couchpotato.core.plugins.score.scores.sizeScore(size)[source]
Module contents
couchpotato.core.plugins.score.autoload()[source]
couchpotato.core.plugins.userscript package
Submodules
couchpotato.core.plugins.userscript.main module
class couchpotato.core.plugins.userscript.main.Userscript[source]

Bases: couchpotato.core.plugins.base.Plugin

bookmark(host=None, **kwargs)
doTest()
getIncludes(**kwargs)
getUserScript(script_route, **kwargs)
getVersion()
getViaUrl(url=None, **kwargs)
iFrame(**kwargs)
version = 8
Module contents
couchpotato.core.plugins.userscript.autoload()[source]
couchpotato.core.plugins.wizard package
Submodules
couchpotato.core.plugins.wizard.main module
class couchpotato.core.plugins.wizard.main.Wizard[source]

Bases: couchpotato.core.plugins.base.Plugin

Module contents
couchpotato.core.plugins.wizard.autoload()[source]
Submodules
couchpotato.core.plugins.automation module
class couchpotato.core.plugins.automation.Automation[source]

Bases: couchpotato.core.plugins.base.Plugin

addMovies()
setCrons()
couchpotato.core.plugins.base module
class couchpotato.core.plugins.base.Plugin[source]

Bases: object

acquireLock(key)
afterCall(handler)
beforeCall(handler)
checkFilesChanged(files, unchanged_for=60)
conf(attr, value=None, default=None, section=None)
cpTag(media, unique_tag=False)
createFile(path, content, binary=False)
createFileName(data, filedata, media, unique_tag=False)
createNzbName(data, media, unique_tag=False)
databaseSetup()
deleteConf(attr)
deleteEmptyFolder(folder, show_error=True, only_clean=None)
doShutdown(*args, **kwargs)
enabled_option = 'enabled'
getCache(cache_key, url=None, **kwargs)
getFileTimes(file_path)
getName()
http_failed_disabled = {}
http_failed_request = {}
http_last_use = {}
http_last_use_queue = {}
http_time_between_calls = 0
isDisabled()
isEnabled()
isRunning(value=None, boolean=True)
makeDir(path)
plugin_path = None
registerPlugin()
releaseLock(key)
renderTemplate(parent_file, templ, **params)
setCache(cache_key, value, timeout=300)
setName(name)
shuttingDown(value=None)
urlopen(url, timeout=30, data=None, headers=None, files=None, show_error=True, stream=False)
user_agent = 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:40.0) Gecko/20100101 Firefox/40.0'
wait(host='', url='')
couchpotato.core.plugins.browser module
class couchpotato.core.plugins.browser.FileBrowser[source]

Bases: couchpotato.core.plugins.base.Plugin

getDirectories(path='/', show_hidden=True)
getDriveLetters()
getFiles()
has_hidden_attribute(filepath)
is_hidden(filepath)
view(path='/', show_hidden=True, **kwargs)
couchpotato.core.plugins.custom module
class couchpotato.core.plugins.custom.Custom[source]

Bases: couchpotato.core.plugins.base.Plugin

createStructure()
couchpotato.core.plugins.dashboard module
class couchpotato.core.plugins.dashboard.Dashboard[source]

Bases: couchpotato.core.plugins.base.Plugin

getLateView(limit_offset=None, random=False, late=False, **kwargs)
getSoonView(limit_offset=None, random=False, late=False, **kwargs)
couchpotato.core.plugins.file module
class couchpotato.core.plugins.file.FileManager[source]

Bases: couchpotato.core.plugins.base.Plugin

cleanup()
doSubfolderTest()
download(url='', dest=None, overwrite=False, urlopen_kwargs=None)
showCacheFile(route, **kwargs)
couchpotato.core.plugins.manage module
class couchpotato.core.plugins.manage.Manage[source]

Bases: couchpotato.core.plugins.base.Plugin

createAddToLibrary(folder, added_identifiers=[])
createAfterUpdate(folder, identifier)
directories()
getDiskSpace()
getProgress(**kwargs)
in_progress = False
scanFilesToLibrary(folder=None, files=None, release_download=None)
setCrons()
updateLibrary(full=True)
updateLibraryQuick()
updateLibraryView(full=1, **kwargs)
updateProgress(folder, to_go)
couchpotato.core.plugins.renamer module
class couchpotato.core.plugins.renamer.Renamer[source]

Bases: couchpotato.core.plugins.base.Plugin

checkSnatched(fire_scan=True)
checking_snatched = False
doReplace(string, replacements, remove_multiple=False, folder=False)

replace confignames with the real thing

downloadIsTorrent(release_download)
extendReleaseDownload(release_download)
extractFiles(folder=None, media_folder=None, files=None, cleanup=False)
fileIsAdded(src, group)
getProgress(**kwargs)
getRenameExtras(extra_type='', replacements=None, folder_name='', file_name='', destination='', group=None, current_file='', remove_multiple=False)
hastagRelease(release_download, tag='')
moveFile(old, dest, use_default=False)
moveTypeIsLinked()
movieInFromFolder(media_folder)
renaming_started = False
replaceDoubles(string)
scan(base_folder=None, release_download=None, to_folder=None)
scanView(**kwargs)
setCrons()
statusInfoComplete(release_download)
tagRelease(tag, group=None, release_download=None)
untagRelease(group=None, release_download=None, tag='')
couchpotato.core.plugins.scanner module
class couchpotato.core.plugins.scanner.Scanner[source]

Bases: couchpotato.core.plugins.base.Plugin

audio_codec_map = {8192: 'AC3', 8193: 'DTS', 3: 'WAV', 1: 'PCM', 80: 'MP2', 85: 'MP3', 22358: 'WAV', 26448: 'Vorbis', 30625: 'TTA1', 61868: 'FLAC', 255: 'AAC'}
clean = '([ _\\,\\.\\(\\)\\[\\]\\-]|^)(3d|hsbs|sbs|half.sbs|full.sbs|ou|half.ou|full.ou|extended|extended.cut|directors.cut|french|fr|swedisch|sw|danish|dutch|nl|swesub|subs|spanish|german|ac3|dts|custom|dc|divx|divx5|dsr|dsrip|dutch|dvd|dvdr|dvdrip|dvdscr|dvdscreener|screener|dvdivx|cam|fragment|fs|hdtv|hdrip|hdtvrip|webdl|web.dl|webrip|web.rip|internal|limited|multisubs|ntsc|ogg|ogm|pal|pdtv|proper|repack|rerip|retail|r3|r5|bd5|se|svcd|swedish|german|read.nfo|nfofix|unrated|ws|telesync|ts|telecine|tc|brrip|bdrip|video_ts|audio_ts|480p|480i|576p|576i|720p|720i|1080p|1080i|hrhd|hrhdtv|hddvd|bluray|x264|h264|x265|h265|xvid|xvidvd|xxx|www.www|hc|\\[.*\\])(?=[ _\\,\\.\\(\\)\\[\\]\\-]|$)'
codecs = {'audio': ['DTS', 'AC3', 'AC3D', 'MP3'], 'video': ['x264', 'H264', 'x265', 'H265', 'DivX', 'Xvid']}
cp_imdb = '\\.cp\\((?P<id>tt[0-9]+),?\\s?(?P<random>[A-Za-z0-9]+)?\\)'
createStringIdentifier(file_path, folder='', exclude_filename=False)
determineMedia(group, release_download=None)
extensions = {'subtitle_extra': ['idx'], 'movie_extra': ['mds'], 'nfo': ['nfo', 'txt', 'tag'], 'movie': ['mkv', 'wmv', 'avi', 'mpg', 'mpeg', 'mp4', 'm2ts', 'iso', 'img', 'mdf', 'ts', 'm4v', 'flv'], 'dvd': ['vts_*', 'vob'], 'subtitle': ['sub', 'srt', 'ssa', 'ass'], 'trailer': ['mov', 'mp4', 'flv']}
file_sizes = {'movie': {'min': 200}, 'backdrop': {'max': 5, 'min': 0}, 'trailer': {'max': 199, 'min': 2}}
file_types = {'subtitle_extra': ('subtitle', 'subtitle_extra'), 'subtitle': ('subtitle', 'subtitle'), 'backdrop': ('image', 'backdrop'), 'poster': ('image', 'poster'), 'nfo': ('nfo', 'nfo'), 'movie': ('video', 'movie'), 'movie_extra': ('movie', 'movie_extra'), 'leftover': ('leftover', 'leftover'), 'thumbnail': ('image', 'thumbnail'), 'trailer': ('video', 'trailer')}
filesizeBetween(file, file_size=None)
findYear(text)
get3dType(filename)
getCPImdb(string)
getCodec(filename, codecs)
getDVDFiles(files)
getFileSize(file)
getGroup(file)
getImages(files)
getMediaFiles(files)
getMeta(filename)
getMetaData(group, folder='', release_download=None)
getMovieExtras(files)
getNfo(files)
getPartNumber(name)
getReleaseNameYear(release_name, file_name=None)
getResolution(filename)
getSamples(files)
getSourceMedia(file)
getSubtitleLanguage(group)
getSubtitles(files)
getSubtitlesExtras(files)
getTrailers(files)
ignore_names = ['extract', 'extracting', 'extracted', 'movie', 'movies', 'film', 'films', 'download', 'downloads', 'video_ts', 'audio_ts', 'bdmv', 'certificate']
ignored_in_path = ['/extracted/', 'extracting', '_unpack', '_failed_', '_unknown_', '_exists_', '_failed_remove_', '_failed_rename_', '.appledouble', '.appledb', '.appledesktop', '/._', '.ds_store', 'cp.cpnfo', 'thumbs.db', 'ehthumbs.db', 'desktop.ini']
isDVDFile(file_name)
isSampleFile(filename)
keepFile(filename)
multipart_regex = ['[ _\\.-]+cd[ _\\.-]*([0-9a-d]+)', '[ _\\.-]+dvd[ _\\.-]*([0-9a-d]+)', '[ _\\.-]+part[ _\\.-]*([0-9a-d]+)', '[ _\\.-]+dis[ck][ _\\.-]*([0-9a-d]+)', 'cd[ _\\.-]*([0-9a-d]+)$', 'dvd[ _\\.-]*([0-9a-d]+)$', 'part[ _\\.-]*([0-9a-d]+)$', 'dis[ck][ _\\.-]*([0-9a-d]+)$', '()[ _\\.-]+([0-9]*[abcd]+)(\\.....?)$', '([a-z])([0-9]+)(\\.....?)$', '()([ab])(\\.....?)$']
removeCPTag(name)
removeMultipart(name)
resolutions = {'480p': {'resolution_height': 480, 'resolution_width': 640, 'aspect': 1.33}, '720i': {'resolution_height': 720, 'resolution_width': 1280, 'aspect': 1.78}, '1080i': {'resolution_height': 1080, 'resolution_width': 1920, 'aspect': 1.78}, 'default': {'resolution_height': 0, 'resolution_width': 0, 'aspect': 1}, '480i': {'resolution_height': 480, 'resolution_width': 640, 'aspect': 1.33}, '720p': {'resolution_height': 720, 'resolution_width': 1280, 'aspect': 1.78}, '1080p': {'resolution_height': 1080, 'resolution_width': 1920, 'aspect': 1.78}, '2160p': {'resolution_height': 2160, 'resolution_width': 3840, 'aspect': 1.78}}
scan(folder=None, files=None, release_download=None, simple=False, newer_than=0, return_ignored=True, check_file_date=True, on_found=None)
source_media = {'HD DVD': ['hddvd', 'hd-dvd'], 'DVD': ['dvd'], 'HDTV': ['hdtv'], 'Blu-ray': ['bluray', 'blu-ray', 'brrip', 'br-rip']}
threed_types = {'SBS': ['sbs'], 'Full OU': [('full', 'ou'), ('h', 'ou'), 'fou'], 'Half SBS': [('half', 'sbs'), ('h', 'sbs'), 'hsbs'], 'Full SBS': [('full', 'sbs'), ('f', 'sbs'), 'fsbs'], 'OU': ['ou'], 'Frame Packed': ['mvc', ('complete', 'bluray')], 'Half OU': [('half', 'ou'), ('h', 'ou'), 'hou'], '3D': ['3d']}
couchpotato.core.plugins.subtitle module
class couchpotato.core.plugins.subtitle.Subtitle[source]

Bases: couchpotato.core.plugins.base.Plugin

getLanguages()
searchSingle(group)
services = ['opensubtitles', 'thesubdb', 'subswiki', 'subscenter']
couchpotato.core.plugins.trailer module
class couchpotato.core.plugins.trailer.Trailer[source]

Bases: couchpotato.core.plugins.base.Plugin

searchSingle(message=None, group=None)
Module contents
Submodules
couchpotato.core.database module
class couchpotato.core.database.Database[source]

Bases: object

close(**kwargs)
compact(try_repair=True, **kwargs)
db = None
deleteCorrupted(_id, traceback_error='')
deleteDocument(**kwargs)
getDB()
indexes = None
listDocuments(**kwargs)
migrate()
reindex(**kwargs)
setupIndex(index_name, klass)
startup_compact()
updateDocument(**kwargs)
couchpotato.core.event module
couchpotato.core.event.addEvent(name, handler, priority=100)[source]
couchpotato.core.event.errorHandler(error)[source]
couchpotato.core.event.fireEvent(name, *args, **kwargs)[source]
couchpotato.core.event.fireEventAsync(*args, **kwargs)[source]
couchpotato.core.event.getEvent(name)[source]
couchpotato.core.event.runHandler(name, handler, *args, **kwargs)[source]
couchpotato.core.loader module
class couchpotato.core.loader.Loader[source]

Bases: object

addFromDir(plugin_type, priority, module, dir_name)
addModule(priority, plugin_type, module, name)
addPath(root, base_path, priority, recursive=False)
loadModule(name)
loadPlugins(module, type, name)
loadSettings(module, name, save=True)
preload(root='')
run()
couchpotato.core.logger module
class couchpotato.core.logger.CPLog(context='')[source]

Bases: object

Env = None
addContext(msg, replace_tuple=())
close(*args, **kwargs)
context = ''
critical(msg, replace_tuple=())
debug(msg, replace_tuple=())
error(msg, replace_tuple=())
info(msg, replace_tuple=())
info2(msg, replace_tuple=())
is_develop = False
replace_private = ['api', 'apikey', 'api_key', 'password', 'username', 'h', 'uid', 'key', 'passkey']
safeMessage(msg, replace_tuple=())
setup()
warning(msg, replace_tuple=())
couchpotato.core.settings module
class couchpotato.core.settings.PropertyIndex(*args, **kwargs)[source]

Bases: CodernityDB.hash_index.HashIndex

make_key(key)[source]
make_key_value(data)[source]
class couchpotato.core.settings.Settings[source]

Bases: object

addOptions(section_name, options)
addSection(section)
connectEvents()
databaseSetup()
delete(option='', section='core')
get(option='', section='core', default=None, type=None)
getBool(section, option)
getDirectories(section, option)
getEnabler(section, option)
getFloat(section, option)
getInt(section, option)
getOptions()

Returns dict of UI-readable options

To check, whether the option is readable self.isOptionReadable() is used

getProperty(identifier)
getType(section, option)
getUnicode(section, option)
getValues()
isOptionMeta(section, option)

A helper method for detecting internal-meta options in the ini-file

For a meta options used following names: * section_hidden_internal_meta = (True | False) - for section visibility * <OPTION>_internal_meta = (ro|rw|hidden) - for section visibility

isOptionReadable(section, option)
isOptionWritable(section, option)
isSectionReadable(section)
optionMetaSuffix()
optionReadableCheckAndWarn(section, option)
options = {}
parser()
registerDefaults(section_name, options=None, save=True)
save()
saveView(**kwargs)
sections()
set(section, option, value)
setDefault(section, option, value)
setFile(config_file)
setProperty(identifier, value='')
setType(section, option, type)
types = {}
view(**kwargs)
couchpotato.core.softchroot module
class couchpotato.core.softchroot.SoftChroot[source]

Soft Chroot module

Provides chroot feature for interation with Web-UI. Since it is not real chroot, so the name is SOFT CHROOT. The module prevents access to entire file-system, allowing access only to subdirs of SOFT-CHROOT directory.

abs2chroot(path, force=False)[source]

Converts absolute path to chrooted path

chroot2abs(path)[source]

Converts chrooted path to absolute path

get_chroot()[source]

Returns root in chrooted environment

Raises:
RuntimeError: when SoftChroot is not initialized OR enabled
initialize(chdir)[source]

initialize module, by setting soft-chroot-directory

Sets soft-chroot directory and ‘enabled’-flag

Args:
self (SoftChroot) : self chdir (string) : absolute path to soft-chroot
Raises:
SoftChrootInitError: when chdir doesn’t exist
is_root_abs(abspath)[source]

Checks whether absolute path @abspath is the root in the soft-chrooted environment

is_subdir(abspath)[source]

Checks whether @abspath is subdir (on any level) of soft-chroot

exception couchpotato.core.softchroot.SoftChrootInitError[source]

Bases: exceptions.IOError

Error during soft-chroot initialization

Module contents

Submodules

couchpotato.api module
class couchpotato.api.ApiHandler(application, request, **kwargs)[source]

Bases: tornado.web.RequestHandler

get(*args, **kwargs)[source]
post(*args, **kwargs)
route = None
sendData(result, route)[source]
taskFinished(result, route)[source]
unlock()[source]
class couchpotato.api.NonBlockHandler(application, request, **kwargs)[source]

Bases: tornado.web.RequestHandler

get(*args, **kwargs)
removeStopper()
sendData(response)
stopper = None
couchpotato.api.addApiView(route, func, static=False, docs=None, **kwargs)[source]
couchpotato.api.addNonBlockApiView(route, func_tuple, docs=None, **kwargs)[source]
couchpotato.api.run_async(func)[source]
couchpotato.api.run_handler(*args, **kwargs)[source]
couchpotato.environment module
class couchpotato.environment.Env[source]

Bases: object

static addEvent(*args, **kwargs)
static all()
static doDebug()
static fireEvent(*args, **kwargs)
static get(attr, unicode=False)
static getIdentifier()
static getPermission(setting_type)
static getPid()
static prop(identifier, value=None, default=None)
static set(attr, value)
static setting(attr, section='core', value=None, default='', type=None)
couchpotato.runner module
couchpotato.runner.getOptions(args)[source]
couchpotato.runner.runCouchPotato(options, base_path, args, data_dir=None, log_dir=None, Env=None, desktop=None)[source]

Module contents

class couchpotato.BaseHandler(application, request, **kwargs)[source]

Bases: tornado.web.RequestHandler

get_current_user()
class couchpotato.KeyHandler(application, request, **kwargs)[source]

Bases: tornado.web.RequestHandler

get(*args, **kwargs)
class couchpotato.LoginHandler(application, request, **kwargs)[source]

Bases: couchpotato.BaseHandler

get(*args, **kwargs)
post(*args, **kwargs)
class couchpotato.LogoutHandler(application, request, **kwargs)[source]

Bases: couchpotato.BaseHandler

get(*args, **kwargs)
class couchpotato.WebHandler(application, request, **kwargs)[source]

Bases: couchpotato.BaseHandler

get(*args, **kwargs)
couchpotato.addView(route, func)[source]
couchpotato.apiDocs(*args)[source]
couchpotato.databaseManage(*args)[source]
couchpotato.get_db()[source]
couchpotato.index(*args)[source]
couchpotato.manifest(handler)[source]
couchpotato.page_not_found(rh)[source]
couchpotato.robots(handler)[source]

git

version module