Private GIT

Skip to content
Snippets Groups Projects
Commit ac15eb75 authored by Russell Heilling's avatar Russell Heilling Committed by miigotu
Browse files

Update Scenetime provider after api change

The browse_API.php endpoint is no longer available, and the browse.php
page has a slightly different format.  This update switches to
browse.php and only looks for torrent rows within the <div id="torrenttable">
element rather than the entire page.
parent 7a05f902
No related branches found
No related tags found
No related merge requests found
......@@ -46,7 +46,7 @@ class SceneTimeProvider(TorrentProvider): # pylint: disable=too-many-instance-a
self.urls = {'base_url': 'https://www.scenetime.com',
'login': 'https://www.scenetime.com/takelogin.php',
'detail': 'https://www.scenetime.com/details.php?id=%s',
'apisearch': 'https://www.scenetime.com/browse_API.php',
'apisearch': 'https://www.scenetime.com/browse.php',
'download': 'https://www.scenetime.com/download.php/%s/%s'}
self.url = self.urls['base_url']
......@@ -100,7 +100,7 @@ class SceneTimeProvider(TorrentProvider): # pylint: disable=too-many-instance-a
continue
with BS4Parser(data, 'html5lib') as html:
torrent_rows = html.findAll('tr')
torrent_rows = html.find(id='torrenttable').findAll('tr')
# Continue only if one Release is found
if len(torrent_rows) < 2:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment