def _row_to_torrent(self, row): torrent = Torrent() torrent_name_tag = row.find(class_='detName') torrent.name = torrent_name_tag.find(class_='detLink').text torrent.magnet_link = torrent_name_tag.find_next_sibling('a').get('href') tds = row.find_all('td') torrent.seeders = int(tds[2].text) torrent.leechers = int(tds[3].text) return torrent
def _row_to_torrent(self, row): torrent = Torrent() torrent.name = row.find(class_='torrentname').find_all('a')[1].text torrent.magnet_link = row.find(name='a', class_='imagnet').get('href') torrent.torrent_link = row.find(name='a', class_='idownload').get('href') tds = row.find_all('td') torrent.seeders = int(tds[4].text) torrent.leechers = int(tds[5].text) return torrent
def _row_to_torrent(self, row): torrent = Torrent() torrent_name_tag = row.find(class_='detName') description = row.find(class_='detDesc').text torrent.name = torrent_name_tag.find(class_='detLink').text torrent.magnet_link = torrent_name_tag.find_next_sibling('a').get('href') tds = row.find_all('td') torrent.seeders = int(tds[2].text) torrent.leechers = int(tds[3].text) torrent.size = ' '.join(self.size_regex.search(description).groups()) return torrent
def _row_to_torrent(self, row): torrent = Torrent() torrent_name_tag = row.find(class_='detName') description = row.find(class_='detDesc').text torrent.name = torrent_name_tag.find(class_='detLink').text torrent.magnet_link = torrent_name_tag.find_next_sibling('a').get( 'href') tds = row.find_all('td') torrent.seeders = int(tds[2].text) torrent.leechers = int(tds[3].text) torrent.size = ' '.join(self.size_regex.search(description).groups()) return torrent