|
@@ 1853-1879 (lines=27) @@
|
| 1850 |
|
} |
| 1851 |
|
|
| 1852 |
|
|
| 1853 |
|
class PicturesInBoxes(GenericNavigableComic): |
| 1854 |
|
"""Class to retrieve Pictures In Boxes comics.""" |
| 1855 |
|
# Also on https://picturesinboxescomic.tumblr.com |
| 1856 |
|
name = 'picturesinboxes' |
| 1857 |
|
long_name = 'Pictures in Boxes' |
| 1858 |
|
url = 'http://www.picturesinboxes.com' |
| 1859 |
|
get_navi_link = get_a_navi_navinext |
| 1860 |
|
get_first_comic_link = simulate_first_link |
| 1861 |
|
first_url = 'http://www.picturesinboxes.com/2013/10/26/tetris/' |
| 1862 |
|
|
| 1863 |
|
@classmethod |
| 1864 |
|
def get_comic_info(cls, soup, link): |
| 1865 |
|
"""Get information about a particular comics.""" |
| 1866 |
|
title = soup.find('h2', class_='post-title').string |
| 1867 |
|
author = soup.find("span", class_="post-author").find("a").string |
| 1868 |
|
date_str = soup.find('span', class_='post-date').string |
| 1869 |
|
day = string_to_date(date_str, '%B %d, %Y') |
| 1870 |
|
imgs = soup.find('div', class_='comicpane').find_all('img') |
| 1871 |
|
assert imgs |
| 1872 |
|
assert all(i['title'] == i['alt'] == title for i in imgs) |
| 1873 |
|
return { |
| 1874 |
|
'day': day.day, |
| 1875 |
|
'month': day.month, |
| 1876 |
|
'year': day.year, |
| 1877 |
|
'img': [i['src'] for i in imgs], |
| 1878 |
|
'title': title, |
| 1879 |
|
'author': author, |
| 1880 |
|
} |
| 1881 |
|
|
| 1882 |
|
|
|
@@ 2553-2578 (lines=26) @@
|
| 2550 |
|
} |
| 2551 |
|
|
| 2552 |
|
|
| 2553 |
|
class TheAwkwardYeti(GenericNavigableComic): |
| 2554 |
|
"""Class to retrieve The Awkward Yeti comics.""" |
| 2555 |
|
# Also on http://www.gocomics.com/the-awkward-yeti |
| 2556 |
|
# Also on http://larstheyeti.tumblr.com |
| 2557 |
|
# Also on https://tapastic.com/series/TheAwkwardYeti |
| 2558 |
|
name = 'yeti' |
| 2559 |
|
long_name = 'The Awkward Yeti' |
| 2560 |
|
url = 'http://theawkwardyeti.com' |
| 2561 |
|
_categories = ('YETI', ) |
| 2562 |
|
get_first_comic_link = get_a_navi_navifirst |
| 2563 |
|
get_navi_link = get_link_rel_next |
| 2564 |
|
|
| 2565 |
|
@classmethod |
| 2566 |
|
def get_comic_info(cls, soup, link): |
| 2567 |
|
"""Get information about a particular comics.""" |
| 2568 |
|
title = soup.find('h2', class_='post-title').string |
| 2569 |
|
date_str = soup.find("span", class_="post-date").string |
| 2570 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 2571 |
|
imgs = soup.find("div", id="comic").find_all("img") |
| 2572 |
|
assert all(idx > 0 or i['alt'] == i['title'] for idx, i in enumerate(imgs)) |
| 2573 |
|
return { |
| 2574 |
|
'img': [i['src'] for i in imgs], |
| 2575 |
|
'title': title, |
| 2576 |
|
'day': day.day, |
| 2577 |
|
'month': day.month, |
| 2578 |
|
'year': day.year |
| 2579 |
|
} |
| 2580 |
|
|
| 2581 |
|
|
|
@@ 2466-2491 (lines=26) @@
|
| 2463 |
|
} |
| 2464 |
|
|
| 2465 |
|
|
| 2466 |
|
class GerbilWithAJetpack(GenericNavigableComic): |
| 2467 |
|
"""Class to retrieve GerbilWithAJetpack comics.""" |
| 2468 |
|
name = 'gerbil' |
| 2469 |
|
long_name = 'Gerbil With A Jetpack' |
| 2470 |
|
url = 'http://gerbilwithajetpack.com' |
| 2471 |
|
get_first_comic_link = get_a_navi_navifirst |
| 2472 |
|
get_navi_link = get_a_rel_next |
| 2473 |
|
|
| 2474 |
|
@classmethod |
| 2475 |
|
def get_comic_info(cls, soup, link): |
| 2476 |
|
"""Get information about a particular comics.""" |
| 2477 |
|
title = soup.find('h2', class_='post-title').string |
| 2478 |
|
author = soup.find("span", class_="post-author").find("a").string |
| 2479 |
|
date_str = soup.find("span", class_="post-date").string |
| 2480 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 2481 |
|
imgs = soup.find("div", id="comic").find_all("img") |
| 2482 |
|
alt = imgs[0]['alt'] |
| 2483 |
|
assert all(i['alt'] == i['title'] == alt for i in imgs) |
| 2484 |
|
return { |
| 2485 |
|
'img': [i['src'] for i in imgs], |
| 2486 |
|
'title': title, |
| 2487 |
|
'alt': alt, |
| 2488 |
|
'author': author, |
| 2489 |
|
'day': day.day, |
| 2490 |
|
'month': day.month, |
| 2491 |
|
'year': day.year |
| 2492 |
|
} |
| 2493 |
|
|
| 2494 |
|
|
|
@@ 2807-2831 (lines=25) @@
|
| 2804 |
|
first_url = 'http://www.commitstrip.com/en/2012/02/22/interview/' |
| 2805 |
|
|
| 2806 |
|
|
| 2807 |
|
class GenericBoumerie(GenericNavigableComic): |
| 2808 |
|
"""Generic class to retrieve Boumeries comics in different languages.""" |
| 2809 |
|
get_first_comic_link = get_a_navi_navifirst |
| 2810 |
|
get_navi_link = get_link_rel_next |
| 2811 |
|
date_format = NotImplemented |
| 2812 |
|
lang = NotImplemented |
| 2813 |
|
|
| 2814 |
|
@classmethod |
| 2815 |
|
def get_comic_info(cls, soup, link): |
| 2816 |
|
"""Get information about a particular comics.""" |
| 2817 |
|
title = soup.find('h2', class_='post-title').string |
| 2818 |
|
short_url = soup.find('link', rel='shortlink')['href'] |
| 2819 |
|
author = soup.find("span", class_="post-author").find("a").string |
| 2820 |
|
date_str = soup.find('span', class_='post-date').string |
| 2821 |
|
day = string_to_date(date_str, cls.date_format, cls.lang) |
| 2822 |
|
imgs = soup.find('div', id='comic').find_all('img') |
| 2823 |
|
assert all(i['alt'] == i['title'] for i in imgs) |
| 2824 |
|
return { |
| 2825 |
|
'short_url': short_url, |
| 2826 |
|
'img': [i['src'] for i in imgs], |
| 2827 |
|
'title': title, |
| 2828 |
|
'author': author, |
| 2829 |
|
'month': day.month, |
| 2830 |
|
'year': day.year, |
| 2831 |
|
'day': day.day, |
| 2832 |
|
} |
| 2833 |
|
|
| 2834 |
|
|
|
@@ 2495-2519 (lines=25) @@
|
| 2492 |
|
} |
| 2493 |
|
|
| 2494 |
|
|
| 2495 |
|
class EveryDayBlues(GenericDeletedComic, GenericNavigableComic): |
| 2496 |
|
"""Class to retrieve EveryDayBlues Comics.""" |
| 2497 |
|
name = "blues" |
| 2498 |
|
long_name = "Every Day Blues" |
| 2499 |
|
url = "http://everydayblues.net" |
| 2500 |
|
get_first_comic_link = get_a_navi_navifirst |
| 2501 |
|
get_navi_link = get_link_rel_next |
| 2502 |
|
|
| 2503 |
|
@classmethod |
| 2504 |
|
def get_comic_info(cls, soup, link): |
| 2505 |
|
"""Get information about a particular comics.""" |
| 2506 |
|
title = soup.find("h2", class_="post-title").string |
| 2507 |
|
author = soup.find("span", class_="post-author").find("a").string |
| 2508 |
|
date_str = soup.find("span", class_="post-date").string |
| 2509 |
|
day = string_to_date(date_str, "%d. %B %Y", "de_DE.utf8") |
| 2510 |
|
imgs = soup.find("div", id="comic").find_all("img") |
| 2511 |
|
assert all(i['alt'] == i['title'] == title for i in imgs) |
| 2512 |
|
assert len(imgs) <= 1 |
| 2513 |
|
return { |
| 2514 |
|
'img': [i['src'] for i in imgs], |
| 2515 |
|
'title': title, |
| 2516 |
|
'author': author, |
| 2517 |
|
'day': day.day, |
| 2518 |
|
'month': day.month, |
| 2519 |
|
'year': day.year |
| 2520 |
|
} |
| 2521 |
|
|
| 2522 |
|
|
|
@@ 1741-1765 (lines=25) @@
|
| 1738 |
|
} |
| 1739 |
|
|
| 1740 |
|
|
| 1741 |
|
class MouseBearComedy(GenericComicNotWorking): # Website has changed |
| 1742 |
|
"""Class to retrieve Mouse Bear Comedy comics.""" |
| 1743 |
|
# Also on http://mousebearcomedy.tumblr.com |
| 1744 |
|
name = 'mousebear' |
| 1745 |
|
long_name = 'Mouse Bear Comedy' |
| 1746 |
|
url = 'http://www.mousebearcomedy.com' |
| 1747 |
|
get_first_comic_link = get_a_navi_navifirst |
| 1748 |
|
get_navi_link = get_a_navi_comicnavnext_navinext |
| 1749 |
|
|
| 1750 |
|
@classmethod |
| 1751 |
|
def get_comic_info(cls, soup, link): |
| 1752 |
|
"""Get information about a particular comics.""" |
| 1753 |
|
title = soup.find('h2', class_='post-title').string |
| 1754 |
|
author = soup.find("span", class_="post-author").find("a").string |
| 1755 |
|
date_str = soup.find("span", class_="post-date").string |
| 1756 |
|
day = string_to_date(date_str, '%B %d, %Y') |
| 1757 |
|
imgs = soup.find("div", id="comic").find_all("img") |
| 1758 |
|
assert all(i['alt'] == i['title'] == title for i in imgs) |
| 1759 |
|
return { |
| 1760 |
|
'day': day.day, |
| 1761 |
|
'month': day.month, |
| 1762 |
|
'year': day.year, |
| 1763 |
|
'img': [i['src'] for i in imgs], |
| 1764 |
|
'title': title, |
| 1765 |
|
'author': author, |
| 1766 |
|
} |
| 1767 |
|
|
| 1768 |
|
|
|
@@ 1185-1208 (lines=24) @@
|
| 1182 |
|
url = 'http://english.bouletcorp.com' |
| 1183 |
|
|
| 1184 |
|
|
| 1185 |
|
class AmazingSuperPowers(GenericNavigableComic): |
| 1186 |
|
"""Class to retrieve Amazing Super Powers comics.""" |
| 1187 |
|
name = 'asp' |
| 1188 |
|
long_name = 'Amazing Super Powers' |
| 1189 |
|
url = 'http://www.amazingsuperpowers.com' |
| 1190 |
|
get_first_comic_link = get_a_navi_navifirst |
| 1191 |
|
get_navi_link = get_a_navi_navinext |
| 1192 |
|
|
| 1193 |
|
@classmethod |
| 1194 |
|
def get_comic_info(cls, soup, link): |
| 1195 |
|
"""Get information about a particular comics.""" |
| 1196 |
|
author = soup.find("span", class_="post-author").find("a").string |
| 1197 |
|
date_str = soup.find('span', class_='post-date').string |
| 1198 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 1199 |
|
imgs = soup.find('div', id='comic').find_all('img') |
| 1200 |
|
title = ' '.join(i['title'] for i in imgs) |
| 1201 |
|
assert all(i['alt'] == i['title'] for i in imgs) |
| 1202 |
|
return { |
| 1203 |
|
'title': title, |
| 1204 |
|
'author': author, |
| 1205 |
|
'img': [img['src'] for img in imgs], |
| 1206 |
|
'day': day.day, |
| 1207 |
|
'month': day.month, |
| 1208 |
|
'year': day.year |
| 1209 |
|
} |
| 1210 |
|
|
| 1211 |
|
|
|
@@ 702-725 (lines=24) @@
|
| 699 |
|
} |
| 700 |
|
|
| 701 |
|
|
| 702 |
|
class OneOneOneOneComic(GenericComicNotWorking, GenericNavigableComic): |
| 703 |
|
"""Class to retrieve 1111 Comics.""" |
| 704 |
|
# Also on http://comics1111.tumblr.com |
| 705 |
|
# Also on https://tapastic.com/series/1111-Comics |
| 706 |
|
name = '1111' |
| 707 |
|
long_name = '1111 Comics' |
| 708 |
|
url = 'http://www.1111comics.me' |
| 709 |
|
_categories = ('ONEONEONEONE', ) |
| 710 |
|
get_first_comic_link = get_div_navfirst_a |
| 711 |
|
get_navi_link = get_link_rel_next |
| 712 |
|
|
| 713 |
|
@classmethod |
| 714 |
|
def get_comic_info(cls, soup, link): |
| 715 |
|
"""Get information about a particular comics.""" |
| 716 |
|
title = soup.find('h1', class_='comic-title').find('a').string |
| 717 |
|
date_str = soup.find('header', class_='comic-meta entry-meta').find('a').string |
| 718 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 719 |
|
imgs = soup.find_all('meta', property='og:image') |
| 720 |
|
return { |
| 721 |
|
'title': title, |
| 722 |
|
'month': day.month, |
| 723 |
|
'year': day.year, |
| 724 |
|
'day': day.day, |
| 725 |
|
'img': [i['content'] for i in imgs], |
| 726 |
|
} |
| 727 |
|
|
| 728 |
|
|
|
@@ 930-952 (lines=23) @@
|
| 927 |
|
} |
| 928 |
|
|
| 929 |
|
|
| 930 |
|
class TheGentlemanArmchair(GenericNavigableComic): |
| 931 |
|
"""Class to retrieve The Gentleman Armchair comics.""" |
| 932 |
|
name = 'gentlemanarmchair' |
| 933 |
|
long_name = 'The Gentleman Armchair' |
| 934 |
|
url = 'http://thegentlemansarmchair.com' |
| 935 |
|
get_first_comic_link = get_a_navi_navifirst |
| 936 |
|
get_navi_link = get_link_rel_next |
| 937 |
|
|
| 938 |
|
@classmethod |
| 939 |
|
def get_comic_info(cls, soup, link): |
| 940 |
|
"""Get information about a particular comics.""" |
| 941 |
|
title = soup.find('h2', class_='post-title').string |
| 942 |
|
author = soup.find("span", class_="post-author").find("a").string |
| 943 |
|
date_str = soup.find('span', class_='post-date').string |
| 944 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 945 |
|
imgs = soup.find('div', id='comic').find_all('img') |
| 946 |
|
return { |
| 947 |
|
'img': [i['src'] for i in imgs], |
| 948 |
|
'title': title, |
| 949 |
|
'author': author, |
| 950 |
|
'month': day.month, |
| 951 |
|
'year': day.year, |
| 952 |
|
'day': day.day, |
| 953 |
|
} |
| 954 |
|
|
| 955 |
|
|
|
@@ 729-750 (lines=22) @@
|
| 726 |
|
} |
| 727 |
|
|
| 728 |
|
|
| 729 |
|
class AngryAtNothing(GenericDeletedComic, GenericNavigableComic): |
| 730 |
|
"""Class to retrieve Angry at Nothing comics.""" |
| 731 |
|
# Also on http://tapastic.com/series/Comics-yeah-definitely-comics- |
| 732 |
|
# Also on http://angryatnothing.tumblr.com |
| 733 |
|
name = 'angry' |
| 734 |
|
long_name = 'Angry At Nothing' |
| 735 |
|
url = 'http://www.angryatnothing.net' |
| 736 |
|
get_first_comic_link = get_div_navfirst_a |
| 737 |
|
get_navi_link = get_a_rel_next |
| 738 |
|
|
| 739 |
|
@classmethod |
| 740 |
|
def get_comic_info(cls, soup, link): |
| 741 |
|
"""Get information about a particular comics.""" |
| 742 |
|
title = soup.find('h1', class_='comic-title').find('a').string |
| 743 |
|
date_str = soup.find('header', class_='comic-meta entry-meta').find('a').string |
| 744 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 745 |
|
imgs = soup.find_all('meta', property='og:image') |
| 746 |
|
return { |
| 747 |
|
'title': title, |
| 748 |
|
'month': day.month, |
| 749 |
|
'year': day.year, |
| 750 |
|
'day': day.day, |
| 751 |
|
'img': [i['content'] for i in imgs], |
| 752 |
|
} |
| 753 |
|
|
|
@@ 2664-2692 (lines=29) @@
|
| 2661 |
|
} |
| 2662 |
|
|
| 2663 |
|
|
| 2664 |
|
class TalesOfAbsurdity(GenericNavigableComic): |
| 2665 |
|
"""Class to retrieve Tales Of Absurdity comics.""" |
| 2666 |
|
# Also on http://tapastic.com/series/Tales-Of-Absurdity |
| 2667 |
|
# Also on http://talesofabsurdity.tumblr.com |
| 2668 |
|
name = 'absurdity' |
| 2669 |
|
long_name = 'Tales of Absurdity' |
| 2670 |
|
url = 'http://talesofabsurdity.com' |
| 2671 |
|
_categories = ('ABSURDITY', ) |
| 2672 |
|
get_first_comic_link = get_a_navi_navifirst |
| 2673 |
|
get_navi_link = get_a_navi_comicnavnext_navinext |
| 2674 |
|
|
| 2675 |
|
@classmethod |
| 2676 |
|
def get_comic_info(cls, soup, link): |
| 2677 |
|
"""Get information about a particular comics.""" |
| 2678 |
|
title = soup.find('h2', class_='post-title').string |
| 2679 |
|
author = soup.find("span", class_="post-author").find("a").string |
| 2680 |
|
date_str = soup.find("span", class_="post-date").string |
| 2681 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 2682 |
|
imgs = soup.find("div", id="comic").find_all("img") |
| 2683 |
|
assert all(i['alt'] == i['title'] for i in imgs) |
| 2684 |
|
alt = imgs[0]['alt'] if imgs else "" |
| 2685 |
|
return { |
| 2686 |
|
'img': [i['src'] for i in imgs], |
| 2687 |
|
'title': title, |
| 2688 |
|
'alt': alt, |
| 2689 |
|
'author': author, |
| 2690 |
|
'day': day.day, |
| 2691 |
|
'month': day.month, |
| 2692 |
|
'year': day.year |
| 2693 |
|
} |
| 2694 |
|
|
| 2695 |
|
|
|
@@ 2888-2914 (lines=27) @@
|
| 2885 |
|
} |
| 2886 |
|
|
| 2887 |
|
|
| 2888 |
|
class Optipess(GenericNavigableComic): |
| 2889 |
|
"""Class to retrieve Optipess comics.""" |
| 2890 |
|
name = 'optipess' |
| 2891 |
|
long_name = 'Optipess' |
| 2892 |
|
url = 'http://www.optipess.com' |
| 2893 |
|
get_first_comic_link = get_a_navi_navifirst |
| 2894 |
|
get_navi_link = get_link_rel_next |
| 2895 |
|
|
| 2896 |
|
@classmethod |
| 2897 |
|
def get_comic_info(cls, soup, link): |
| 2898 |
|
"""Get information about a particular comics.""" |
| 2899 |
|
title = soup.find('h2', class_='post-title').string |
| 2900 |
|
author = soup.find("span", class_="post-author").find("a").string |
| 2901 |
|
comic = soup.find('div', id='comic') |
| 2902 |
|
imgs = comic.find_all('img') if comic else [] |
| 2903 |
|
alt = imgs[0]['title'] if imgs else "" |
| 2904 |
|
assert all(i['alt'] == i['title'] == alt for i in imgs) |
| 2905 |
|
date_str = soup.find('span', class_='post-date').string |
| 2906 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 2907 |
|
return { |
| 2908 |
|
'title': title, |
| 2909 |
|
'alt': alt, |
| 2910 |
|
'author': author, |
| 2911 |
|
'img': [i['src'] for i in imgs], |
| 2912 |
|
'month': day.month, |
| 2913 |
|
'year': day.year, |
| 2914 |
|
'day': day.day, |
| 2915 |
|
} |
| 2916 |
|
|
| 2917 |
|
|
|
@@ 2634-2660 (lines=27) @@
|
| 2631 |
|
} |
| 2632 |
|
|
| 2633 |
|
|
| 2634 |
|
class LastPlaceComics(GenericNavigableComic): |
| 2635 |
|
"""Class to retrieve Last Place Comics.""" |
| 2636 |
|
name = 'lastplace' |
| 2637 |
|
long_name = 'Last Place Comics' |
| 2638 |
|
url = "http://lastplacecomics.com" |
| 2639 |
|
get_first_comic_link = get_a_comicnavbase_comicnavfirst |
| 2640 |
|
get_navi_link = get_link_rel_next |
| 2641 |
|
|
| 2642 |
|
@classmethod |
| 2643 |
|
def get_comic_info(cls, soup, link): |
| 2644 |
|
"""Get information about a particular comics.""" |
| 2645 |
|
title = soup.find('h2', class_='post-title').string |
| 2646 |
|
author = soup.find("span", class_="post-author").find("a").string |
| 2647 |
|
date_str = soup.find("span", class_="post-date").string |
| 2648 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 2649 |
|
imgs = soup.find("div", id="comic").find_all("img") |
| 2650 |
|
assert all(i['alt'] == i['title'] for i in imgs) |
| 2651 |
|
assert len(imgs) <= 1 |
| 2652 |
|
alt = imgs[0]['alt'] if imgs else "" |
| 2653 |
|
return { |
| 2654 |
|
'img': [i['src'] for i in imgs], |
| 2655 |
|
'title': title, |
| 2656 |
|
'alt': alt, |
| 2657 |
|
'author': author, |
| 2658 |
|
'day': day.day, |
| 2659 |
|
'month': day.month, |
| 2660 |
|
'year': day.year |
| 2661 |
|
} |
| 2662 |
|
|
| 2663 |
|
|
|
@@ 2523-2549 (lines=27) @@
|
| 2520 |
|
} |
| 2521 |
|
|
| 2522 |
|
|
| 2523 |
|
class BiterComics(GenericNavigableComic): |
| 2524 |
|
"""Class to retrieve Biter Comics.""" |
| 2525 |
|
name = "biter" |
| 2526 |
|
long_name = "Biter Comics" |
| 2527 |
|
url = "http://www.bitercomics.com" |
| 2528 |
|
get_first_comic_link = get_a_navi_navifirst |
| 2529 |
|
get_navi_link = get_link_rel_next |
| 2530 |
|
|
| 2531 |
|
@classmethod |
| 2532 |
|
def get_comic_info(cls, soup, link): |
| 2533 |
|
"""Get information about a particular comics.""" |
| 2534 |
|
title = soup.find("h1", class_="entry-title").string |
| 2535 |
|
author = soup.find("span", class_="author vcard").find("a").string |
| 2536 |
|
date_str = soup.find("span", class_="entry-date").string |
| 2537 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 2538 |
|
imgs = soup.find("div", id="comic").find_all("img") |
| 2539 |
|
assert all(i['alt'] == i['title'] for i in imgs) |
| 2540 |
|
assert len(imgs) == 1 |
| 2541 |
|
alt = imgs[0]['alt'] |
| 2542 |
|
return { |
| 2543 |
|
'img': [i['src'] for i in imgs], |
| 2544 |
|
'title': title, |
| 2545 |
|
'alt': alt, |
| 2546 |
|
'author': author, |
| 2547 |
|
'day': day.day, |
| 2548 |
|
'month': day.month, |
| 2549 |
|
'year': day.year |
| 2550 |
|
} |
| 2551 |
|
|
| 2552 |
|
|
|
@@ 1998-2024 (lines=27) @@
|
| 1995 |
|
_categories = ('TUNEYTOONS', ) |
| 1996 |
|
|
| 1997 |
|
|
| 1998 |
|
class CompletelySeriousComics(GenericNavigableComic): |
| 1999 |
|
"""Class to retrieve Completely Serious comics.""" |
| 2000 |
|
name = 'completelyserious' |
| 2001 |
|
long_name = 'Completely Serious Comics' |
| 2002 |
|
url = 'http://completelyseriouscomics.com' |
| 2003 |
|
get_first_comic_link = get_a_navi_navifirst |
| 2004 |
|
get_navi_link = get_a_navi_navinext |
| 2005 |
|
|
| 2006 |
|
@classmethod |
| 2007 |
|
def get_comic_info(cls, soup, link): |
| 2008 |
|
"""Get information about a particular comics.""" |
| 2009 |
|
title = soup.find('h2', class_='post-title').string |
| 2010 |
|
author = soup.find('span', class_='post-author').contents[1].string |
| 2011 |
|
date_str = soup.find('span', class_='post-date').string |
| 2012 |
|
day = string_to_date(date_str, '%B %d, %Y') |
| 2013 |
|
imgs = soup.find('div', class_='comicpane').find_all('img') |
| 2014 |
|
assert imgs |
| 2015 |
|
alt = imgs[0]['title'] |
| 2016 |
|
assert all(i['title'] == i['alt'] == alt for i in imgs) |
| 2017 |
|
return { |
| 2018 |
|
'month': day.month, |
| 2019 |
|
'year': day.year, |
| 2020 |
|
'day': day.day, |
| 2021 |
|
'img': [i['src'] for i in imgs], |
| 2022 |
|
'title': title, |
| 2023 |
|
'alt': alt, |
| 2024 |
|
'author': author, |
| 2025 |
|
} |
| 2026 |
|
|
| 2027 |
|
|
|
@@ 2696-2721 (lines=26) @@
|
| 2693 |
|
} |
| 2694 |
|
|
| 2695 |
|
|
| 2696 |
|
class EndlessOrigami(GenericComicNotWorking, GenericNavigableComic): # Nav not working |
| 2697 |
|
"""Class to retrieve Endless Origami Comics.""" |
| 2698 |
|
name = "origami" |
| 2699 |
|
long_name = "Endless Origami" |
| 2700 |
|
url = "http://endlessorigami.com" |
| 2701 |
|
get_first_comic_link = get_a_navi_navifirst |
| 2702 |
|
get_navi_link = get_link_rel_next |
| 2703 |
|
|
| 2704 |
|
@classmethod |
| 2705 |
|
def get_comic_info(cls, soup, link): |
| 2706 |
|
"""Get information about a particular comics.""" |
| 2707 |
|
title = soup.find('h2', class_='post-title').string |
| 2708 |
|
author = soup.find("span", class_="post-author").find("a").string |
| 2709 |
|
date_str = soup.find("span", class_="post-date").string |
| 2710 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 2711 |
|
imgs = soup.find("div", id="comic").find_all("img") |
| 2712 |
|
assert all(i['alt'] == i['title'] for i in imgs) |
| 2713 |
|
alt = imgs[0]['alt'] if imgs else "" |
| 2714 |
|
return { |
| 2715 |
|
'img': [i['src'] for i in imgs], |
| 2716 |
|
'title': title, |
| 2717 |
|
'alt': alt, |
| 2718 |
|
'author': author, |
| 2719 |
|
'day': day.day, |
| 2720 |
|
'month': day.month, |
| 2721 |
|
'year': day.year |
| 2722 |
|
} |
| 2723 |
|
|
| 2724 |
|
|
|
@@ 2209-2234 (lines=26) @@
|
| 2206 |
|
return reversed(get_soup_at_url(archive_url).find('tbody').find_all('tr')) |
| 2207 |
|
|
| 2208 |
|
|
| 2209 |
|
class HappleTea(GenericNavigableComic): |
| 2210 |
|
"""Class to retrieve Happle Tea Comics.""" |
| 2211 |
|
name = 'happletea' |
| 2212 |
|
long_name = 'Happle Tea' |
| 2213 |
|
url = 'http://www.happletea.com' |
| 2214 |
|
get_first_comic_link = get_a_navi_navifirst |
| 2215 |
|
get_navi_link = get_link_rel_next |
| 2216 |
|
|
| 2217 |
|
@classmethod |
| 2218 |
|
def get_comic_info(cls, soup, link): |
| 2219 |
|
"""Get information about a particular comics.""" |
| 2220 |
|
imgs = soup.find('div', id='comic').find_all('img') |
| 2221 |
|
post = soup.find('div', class_='post-content') |
| 2222 |
|
title = post.find('h2', class_='post-title').string |
| 2223 |
|
author = post.find('a', rel='author').string |
| 2224 |
|
date_str = post.find('span', class_='post-date').string |
| 2225 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 2226 |
|
assert all(i['alt'] == i['title'] for i in imgs) |
| 2227 |
|
return { |
| 2228 |
|
'title': title, |
| 2229 |
|
'img': [i['src'] for i in imgs], |
| 2230 |
|
'alt': ''.join(i['alt'] for i in imgs), |
| 2231 |
|
'month': day.month, |
| 2232 |
|
'year': day.year, |
| 2233 |
|
'day': day.day, |
| 2234 |
|
'author': author, |
| 2235 |
|
} |
| 2236 |
|
|
| 2237 |
|
|
|
@@ 1883-1908 (lines=26) @@
|
| 1880 |
|
} |
| 1881 |
|
|
| 1882 |
|
|
| 1883 |
|
class Penmen(GenericNavigableComic): |
| 1884 |
|
"""Class to retrieve Penmen comics.""" |
| 1885 |
|
name = 'penmen' |
| 1886 |
|
long_name = 'Penmen' |
| 1887 |
|
url = 'http://penmen.com' |
| 1888 |
|
get_navi_link = get_link_rel_next |
| 1889 |
|
get_first_comic_link = simulate_first_link |
| 1890 |
|
first_url = 'http://penmen.com/index.php/2016/09/12/penmen-announces-grin-big-brand-clothing/' |
| 1891 |
|
|
| 1892 |
|
@classmethod |
| 1893 |
|
def get_comic_info(cls, soup, link): |
| 1894 |
|
"""Get information about a particular comics.""" |
| 1895 |
|
title = soup.find('title').string |
| 1896 |
|
imgs = soup.find('div', class_='entry-content').find_all('img') |
| 1897 |
|
short_url = soup.find('link', rel='shortlink')['href'] |
| 1898 |
|
tags = ' '.join(t.string for t in soup.find_all('a', rel='tag')) |
| 1899 |
|
date_str = soup.find('time')['datetime'][:10] |
| 1900 |
|
day = string_to_date(date_str, "%Y-%m-%d") |
| 1901 |
|
return { |
| 1902 |
|
'title': title, |
| 1903 |
|
'short_url': short_url, |
| 1904 |
|
'img': [i['src'] for i in imgs], |
| 1905 |
|
'tags': tags, |
| 1906 |
|
'month': day.month, |
| 1907 |
|
'year': day.year, |
| 1908 |
|
'day': day.day, |
| 1909 |
|
} |
| 1910 |
|
|
| 1911 |
|
|
|
@@ 1824-1849 (lines=26) @@
|
| 1821 |
|
} |
| 1822 |
|
|
| 1823 |
|
|
| 1824 |
|
class SafelyEndangered(GenericNavigableComic): |
| 1825 |
|
"""Class to retrieve Safely Endangered comics.""" |
| 1826 |
|
# Also on http://tumblr.safelyendangered.com |
| 1827 |
|
name = 'endangered' |
| 1828 |
|
long_name = 'Safely Endangered' |
| 1829 |
|
url = 'http://www.safelyendangered.com' |
| 1830 |
|
get_navi_link = get_link_rel_next |
| 1831 |
|
get_first_comic_link = simulate_first_link |
| 1832 |
|
first_url = 'http://www.safelyendangered.com/comic/ignored/' |
| 1833 |
|
|
| 1834 |
|
@classmethod |
| 1835 |
|
def get_comic_info(cls, soup, link): |
| 1836 |
|
"""Get information about a particular comics.""" |
| 1837 |
|
title = soup.find('h2', class_='post-title').string |
| 1838 |
|
date_str = soup.find('span', class_='post-date').string |
| 1839 |
|
day = string_to_date(date_str, '%B %d, %Y') |
| 1840 |
|
imgs = soup.find('div', id='comic').find_all('img') |
| 1841 |
|
alt = imgs[0]['alt'] |
| 1842 |
|
assert all(i['alt'] == i['title'] for i in imgs) |
| 1843 |
|
return { |
| 1844 |
|
'day': day.day, |
| 1845 |
|
'month': day.month, |
| 1846 |
|
'year': day.year, |
| 1847 |
|
'img': [i['src'] for i in imgs], |
| 1848 |
|
'title': title, |
| 1849 |
|
'alt': alt, |
| 1850 |
|
} |
| 1851 |
|
|
| 1852 |
|
|
|
@@ 2365-2389 (lines=25) @@
|
| 2362 |
|
} |
| 2363 |
|
|
| 2364 |
|
|
| 2365 |
|
class LonnieMillsap(GenericNavigableComic): |
| 2366 |
|
"""Class to retrieve Lonnie Millsap's comics.""" |
| 2367 |
|
name = 'millsap' |
| 2368 |
|
long_name = 'Lonnie Millsap' |
| 2369 |
|
url = 'http://www.lonniemillsap.com' |
| 2370 |
|
get_navi_link = get_link_rel_next |
| 2371 |
|
get_first_comic_link = simulate_first_link |
| 2372 |
|
first_url = 'http://www.lonniemillsap.com/?p=42' |
| 2373 |
|
|
| 2374 |
|
@classmethod |
| 2375 |
|
def get_comic_info(cls, soup, link): |
| 2376 |
|
"""Get information about a particular comics.""" |
| 2377 |
|
title = soup.find('h2', class_='post-title').string |
| 2378 |
|
post = soup.find('div', class_='post-content') |
| 2379 |
|
author = post.find("span", class_="post-author").find("a").string |
| 2380 |
|
date_str = post.find("span", class_="post-date").string |
| 2381 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 2382 |
|
imgs = post.find("div", class_="entry").find_all("img") |
| 2383 |
|
return { |
| 2384 |
|
'title': title, |
| 2385 |
|
'author': author, |
| 2386 |
|
'img': [i['src'] for i in imgs], |
| 2387 |
|
'month': day.month, |
| 2388 |
|
'year': day.year, |
| 2389 |
|
'day': day.day, |
| 2390 |
|
} |
| 2391 |
|
|
| 2392 |
|
|
|
@@ 2086-2110 (lines=25) @@
|
| 2083 |
|
} |
| 2084 |
|
|
| 2085 |
|
|
| 2086 |
|
class ChuckleADuck(GenericNavigableComic): |
| 2087 |
|
"""Class to retrieve Chuckle-A-Duck comics.""" |
| 2088 |
|
name = 'chuckleaduck' |
| 2089 |
|
long_name = 'Chuckle-A-duck' |
| 2090 |
|
url = 'http://chuckleaduck.com' |
| 2091 |
|
get_first_comic_link = get_div_navfirst_a |
| 2092 |
|
get_navi_link = get_link_rel_next |
| 2093 |
|
|
| 2094 |
|
@classmethod |
| 2095 |
|
def get_comic_info(cls, soup, link): |
| 2096 |
|
"""Get information about a particular comics.""" |
| 2097 |
|
date_str = soup.find('span', class_='post-date').string |
| 2098 |
|
day = string_to_date(remove_st_nd_rd_th_from_date(date_str), "%B %d, %Y") |
| 2099 |
|
author = soup.find('span', class_='post-author').string |
| 2100 |
|
div = soup.find('div', id='comic') |
| 2101 |
|
imgs = div.find_all('img') if div else [] |
| 2102 |
|
title = imgs[0]['title'] if imgs else "" |
| 2103 |
|
assert all(i['title'] == i['alt'] == title for i in imgs) |
| 2104 |
|
return { |
| 2105 |
|
'month': day.month, |
| 2106 |
|
'year': day.year, |
| 2107 |
|
'day': day.day, |
| 2108 |
|
'img': [i['src'] for i in imgs], |
| 2109 |
|
'title': title, |
| 2110 |
|
'author': author, |
| 2111 |
|
} |
| 2112 |
|
|
| 2113 |
|
|
|
@@ 3173-3196 (lines=24) @@
|
| 3170 |
|
} |
| 3171 |
|
|
| 3172 |
|
|
| 3173 |
|
class ManVersusManatee(GenericNavigableComic): |
| 3174 |
|
url = 'http://manvsmanatee.com' |
| 3175 |
|
name = 'manvsmanatee' |
| 3176 |
|
long_name = 'Man Versus Manatee' |
| 3177 |
|
get_first_comic_link = get_a_comicnavbase_comicnavfirst |
| 3178 |
|
get_navi_link = get_a_comicnavbase_comicnavnext |
| 3179 |
|
|
| 3180 |
|
@classmethod |
| 3181 |
|
def get_comic_info(cls, soup, link): |
| 3182 |
|
"""Get information about a particular comics.""" |
| 3183 |
|
title = soup.find('h2', class_='post-title').string |
| 3184 |
|
imgs = soup.find('div', id='comic').find_all('img') |
| 3185 |
|
date_str = soup.find('span', class_='post-date').string |
| 3186 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 3187 |
|
return { |
| 3188 |
|
'img': [i['src'] for i in imgs], |
| 3189 |
|
'title': title, |
| 3190 |
|
'month': day.month, |
| 3191 |
|
'year': day.year, |
| 3192 |
|
'day': day.day, |
| 3193 |
|
} |
| 3194 |
|
|
| 3195 |
|
|
| 3196 |
|
class Ubertool(GenericNavigableComic): |
| 3197 |
|
"""Class to retrieve Ubertool comics.""" |
| 3198 |
|
# Also on https://ubertool.tumblr.com |
| 3199 |
|
# Also on https://tapastic.com/series/ubertool |
|
@@ 676-698 (lines=23) @@
|
| 673 |
|
} |
| 674 |
|
|
| 675 |
|
|
| 676 |
|
class PenelopeBagieu(GenericNavigableComic): |
| 677 |
|
"""Class to retrieve comics from Penelope Bagieu's blog.""" |
| 678 |
|
name = 'bagieu' |
| 679 |
|
long_name = 'Ma vie est tout a fait fascinante (Bagieu)' |
| 680 |
|
url = 'http://www.penelope-jolicoeur.com' |
| 681 |
|
_categories = ('FRANCAIS', ) |
| 682 |
|
get_navi_link = get_link_rel_next |
| 683 |
|
get_first_comic_link = simulate_first_link |
| 684 |
|
first_url = 'http://www.penelope-jolicoeur.com/2007/02/ma-vie-mon-oeuv.html' |
| 685 |
|
|
| 686 |
|
@classmethod |
| 687 |
|
def get_comic_info(cls, soup, link): |
| 688 |
|
"""Get information about a particular comics.""" |
| 689 |
|
date_str = soup.find('h2', class_='date-header').string |
| 690 |
|
day = string_to_date(date_str, "%A %d %B %Y", "fr_FR.utf8") |
| 691 |
|
imgs = soup.find('div', class_='entry-body').find_all('img') |
| 692 |
|
title = soup.find('h3', class_='entry-header').string |
| 693 |
|
return { |
| 694 |
|
'title': title, |
| 695 |
|
'img': [i['src'] for i in imgs], |
| 696 |
|
'month': day.month, |
| 697 |
|
'year': day.year, |
| 698 |
|
'day': day.day, |
| 699 |
|
} |
| 700 |
|
|
| 701 |
|
|
|
@@ 3446-3466 (lines=21) @@
|
| 3443 |
|
def get_navi_link(cls, last_soup, next_): |
| 3444 |
|
"""Get link to next or previous comic.""" |
| 3445 |
|
return last_soup.find('a', id='Blog1_blog-pager-newer-link' if next_ else 'Blog1_blog-pager-older-link') |
| 3446 |
|
|
| 3447 |
|
|
| 3448 |
|
class TuMourrasMoinsBete(GenericBlogspotComic): |
| 3449 |
|
"""Class to retrieve Tu Mourras Moins Bete comics.""" |
| 3450 |
|
name = 'mourrasmoinsbete' |
| 3451 |
|
long_name = 'Tu Mourras Moins Bete' |
| 3452 |
|
url = 'http://tumourrasmoinsbete.blogspot.fr' |
| 3453 |
|
_categories = ('FRANCAIS', ) |
| 3454 |
|
first_url = 'http://tumourrasmoinsbete.blogspot.fr/2008/06/essai.html' |
| 3455 |
|
|
| 3456 |
|
@classmethod |
| 3457 |
|
def get_comic_info(cls, soup, link): |
| 3458 |
|
"""Get information about a particular comics.""" |
| 3459 |
|
title = soup.find('title').string |
| 3460 |
|
imgs = soup.find('div', itemprop='description articleBody').find_all('img') |
| 3461 |
|
author = soup.find('span', itemprop='author').string |
| 3462 |
|
return { |
| 3463 |
|
'img': [i['src'] for i in imgs], |
| 3464 |
|
'author': author, |
| 3465 |
|
'title': title, |
| 3466 |
|
} |
| 3467 |
|
|
| 3468 |
|
|
| 3469 |
|
class Octopuns(GenericBlogspotComic): |
|
@@ 1694-1714 (lines=21) @@
|
| 1691 |
|
} |
| 1692 |
|
|
| 1693 |
|
|
| 1694 |
|
class WarehouseComic(GenericNavigableComic): |
| 1695 |
|
"""Class to retrieve Warehouse Comic comics.""" |
| 1696 |
|
name = 'warehouse' |
| 1697 |
|
long_name = 'Warehouse Comic' |
| 1698 |
|
url = 'http://warehousecomic.com' |
| 1699 |
|
get_first_comic_link = get_a_navi_navifirst |
| 1700 |
|
get_navi_link = get_link_rel_next |
| 1701 |
|
|
| 1702 |
|
@classmethod |
| 1703 |
|
def get_comic_info(cls, soup, link): |
| 1704 |
|
"""Get information about a particular comics.""" |
| 1705 |
|
title = soup.find('h2', class_='post-title').string |
| 1706 |
|
date_str = soup.find('span', class_='post-date').string |
| 1707 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 1708 |
|
imgs = soup.find('div', id='comic').find_all('img') |
| 1709 |
|
return { |
| 1710 |
|
'img': [i['src'] for i in imgs], |
| 1711 |
|
'title': title, |
| 1712 |
|
'day': day.day, |
| 1713 |
|
'month': day.month, |
| 1714 |
|
'year': day.year, |
| 1715 |
|
} |
| 1716 |
|
|
| 1717 |
|
|
|
@@ 1212-1238 (lines=27) @@
|
| 1209 |
|
} |
| 1210 |
|
|
| 1211 |
|
|
| 1212 |
|
class ToonHole(GenericNavigableComic): |
| 1213 |
|
"""Class to retrieve Toon Holes comics.""" |
| 1214 |
|
# Also on http://tapastic.com/series/TOONHOLE |
| 1215 |
|
name = 'toonhole' |
| 1216 |
|
long_name = 'Toon Hole' |
| 1217 |
|
url = 'http://www.toonhole.com' |
| 1218 |
|
get_first_comic_link = get_a_comicnavbase_comicnavfirst |
| 1219 |
|
get_navi_link = get_a_comicnavbase_comicnavnext |
| 1220 |
|
|
| 1221 |
|
@classmethod |
| 1222 |
|
def get_comic_info(cls, soup, link): |
| 1223 |
|
"""Get information about a particular comics.""" |
| 1224 |
|
date_str = soup.find('div', class_='entry-meta').contents[0].strip() |
| 1225 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 1226 |
|
imgs = soup.find('div', id='comic').find_all('img') |
| 1227 |
|
if imgs: |
| 1228 |
|
img = imgs[0] |
| 1229 |
|
title = img['alt'] |
| 1230 |
|
assert img['title'] == title |
| 1231 |
|
else: |
| 1232 |
|
title = "" |
| 1233 |
|
return { |
| 1234 |
|
'title': title, |
| 1235 |
|
'month': day.month, |
| 1236 |
|
'year': day.year, |
| 1237 |
|
'day': day.day, |
| 1238 |
|
'img': [convert_iri_to_plain_ascii_uri(i['src']) for i in imgs], |
| 1239 |
|
} |
| 1240 |
|
|
| 1241 |
|
|
|
@@ 3173-3192 (lines=20) @@
|
| 3170 |
|
} |
| 3171 |
|
|
| 3172 |
|
|
| 3173 |
|
class ManVersusManatee(GenericNavigableComic): |
| 3174 |
|
url = 'http://manvsmanatee.com' |
| 3175 |
|
name = 'manvsmanatee' |
| 3176 |
|
long_name = 'Man Versus Manatee' |
| 3177 |
|
get_first_comic_link = get_a_comicnavbase_comicnavfirst |
| 3178 |
|
get_navi_link = get_a_comicnavbase_comicnavnext |
| 3179 |
|
|
| 3180 |
|
@classmethod |
| 3181 |
|
def get_comic_info(cls, soup, link): |
| 3182 |
|
"""Get information about a particular comics.""" |
| 3183 |
|
title = soup.find('h2', class_='post-title').string |
| 3184 |
|
imgs = soup.find('div', id='comic').find_all('img') |
| 3185 |
|
date_str = soup.find('span', class_='post-date').string |
| 3186 |
|
day = string_to_date(date_str, "%B %d, %Y") |
| 3187 |
|
return { |
| 3188 |
|
'img': [i['src'] for i in imgs], |
| 3189 |
|
'title': title, |
| 3190 |
|
'month': day.month, |
| 3191 |
|
'year': day.year, |
| 3192 |
|
'day': day.day, |
| 3193 |
|
} |
| 3194 |
|
|
| 3195 |
|
|