diff --git a/CHANGELOG.md b/CHANGELOG.md index dbb6fc00..5921c98b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,7 @@ # Changelog +## Unreleased + ## 1.13.2 - 2020-03-14 ### Additions - [furaffinity] extract more metadata diff --git a/docs/supportedsites.rst b/docs/supportedsites.rst index a4004798..f29102ec 100644 --- a/docs/supportedsites.rst +++ b/docs/supportedsites.rst @@ -146,7 +146,7 @@ Turboimagehost https://www.turboimagehost.com/ individual Images .. |flickr-C| replace:: Albums, Favorites, Galleries, Groups, individual Images, Search Results, User Profiles .. |hentaifoundry-C| replace:: Favorites, individual Images, Popular Images, Recent Images, Scraps, User Profiles .. |imgur-C| replace:: Albums, Favorites, Galleries, individual Images, Subreddits, User Profiles -.. |instagram-C| replace:: Channels, individual Images, Stories, Tag-Searches, User Profiles +.. |instagram-C| replace:: Channels, individual Images, Saved Posts, Stories, Tag-Searches, User Profiles .. |newgrounds-C| replace:: Art, Audio, Favorites, individual Images, Media Files, Movies, User Profiles .. |nijie-C| replace:: Doujin, Favorites, individual Images, User Profiles .. |pixiv-C| replace:: Favorites, Follows, pixiv.me Links, Rankings, Search Results, User Profiles, individual Images diff --git a/gallery_dl/extractor/instagram.py b/gallery_dl/extractor/instagram.py index 5c8004ea..c6ca3f3f 100644 --- a/gallery_dl/extractor/instagram.py +++ b/gallery_dl/extractor/instagram.py @@ -12,6 +12,7 @@ from .common import Extractor, Message from .. import text, exception from ..cache import cache +import itertools import json @@ -413,6 +414,7 @@ class InstagramSavedExtractor(InstagramExtractor): pattern = (r"(?:https?://)?(?:www\.)?instagram\.com" r"/(?!p/|explore/|directory/|accounts/|stories/|tv/)" r"([^/?&#]+)/saved") + test = ("https://www.instagram.com/instagram/saved/",) def __init__(self, match): InstagramExtractor.__init__(self, match) @@ -459,10 +461,7 @@ class InstagramUserExtractor(InstagramExtractor): url = '{}/{}/'.format(self.root, self.username) shared_data = self._extract_shared_data(url) - if self.config('highlights'): - yield from self._extract_story_highlights(shared_data) - - yield from self._extract_page(shared_data, { + instagrams = self._extract_page(shared_data, { 'page': 'ProfilePage', 'node': 'user', 'node_id': 'id', @@ -471,6 +470,14 @@ class InstagramUserExtractor(InstagramExtractor): 'query_hash': 'f2405b236d85e8296cf30347c9f08c2a', }) + if self.config('highlights'): + instagrams = itertools.chain( + self._extract_story_highlights(shared_data), + instagrams, + ) + + return instagrams + class InstagramChannelExtractor(InstagramExtractor): """Extractor for ProfilePage channel""" diff --git a/gallery_dl/version.py b/gallery_dl/version.py index 9171f158..9db3736b 100644 --- a/gallery_dl/version.py +++ b/gallery_dl/version.py @@ -6,4 +6,4 @@ # it under the terms of the GNU General Public License version 2 as # published by the Free Software Foundation. -__version__ = "1.13.2" +__version__ = "1.13.3-dev" diff --git a/scripts/supportedsites.py b/scripts/supportedsites.py index cf054503..77e340e3 100755 --- a/scripts/supportedsites.py +++ b/scripts/supportedsites.py @@ -109,6 +109,9 @@ SUBCATEGORY_MAP = { "deviantart": { "stash": "Sta.sh", }, + "instagram": { + "saved": "Saved Posts", + }, "newgrounds": { "art" : "Art", "audio": "Audio",