diff --git a/README.rst b/README.rst index 4dbd5b5..c8e1388 100644 --- a/README.rst +++ b/README.rst @@ -29,7 +29,7 @@ .. |downloads| image:: https://pepy.tech/badge/instaloader/month :alt: PyPI Download Count - :target: https://pepy.tech/project/instaloader/month + :target: https://pepy.tech/project/instaloader .. badges-end @@ -84,7 +84,9 @@ To later **update your local copy** of that profiles, you may run instaloader --fast-update profile [profile ...] If ``--fast-update`` is given, Instaloader stops when arriving at the -first already-downloaded picture. When updating profiles, Instaloader +first already-downloaded picture. + +When updating profiles, Instaloader automatically **detects profile name changes** and renames the target directory accordingly. diff --git a/docs/cli-options.rst b/docs/cli-options.rst index d5413a0..a353872 100644 --- a/docs/cli-options.rst +++ b/docs/cli-options.rst @@ -220,12 +220,20 @@ How to Download used to save the information to resume an interrupted download. The default prefix is ``iterator``. - Resuming an interrupted download is supported for most, but not all targets. + Resuming an interrupted download is supported for the following targets: + - Profile posts, + - Profile IGTV posts (:option:`--igtv`), + - Profile tagged posts (:option:`--tagged`), + - Saved posts (``:saved``). + + This feature is enabled by default for targets where it is supported; + :option:`--resume-prefix` only changes the name of the iterator files. + + To turn this feature off, use :option:`--no-resume`. + JSON files with resume information are always compressed, regardless of :option:`--no-compress-json`. - This feature is turned off entirely with :option:`--no-resume`. - .. versionadded:: 4.5 .. option:: --no-resume diff --git a/instaloader/__init__.py b/instaloader/__init__.py index 15d438f..2badb88 100644 --- a/instaloader/__init__.py +++ b/instaloader/__init__.py @@ -1,7 +1,7 @@ """Download pictures (or videos) along with their captions and other metadata from Instagram.""" -__version__ = '4.6.1' +__version__ = '4.6.2' try: diff --git a/instaloader/instaloader.py b/instaloader/instaloader.py index e502121..a910588 100644 --- a/instaloader/instaloader.py +++ b/instaloader/instaloader.py @@ -599,15 +599,15 @@ class Instaloader: suffix = None if self.download_pictures and (not sidecar_node.is_video or self.download_video_thumbnails): # pylint:disable=cell-var-from-loop - filename = self.__prepare_filename(filename_template, lambda: sidecar_node.display_url) + sidecar_filename = self.__prepare_filename(filename_template, lambda: sidecar_node.display_url) # Download sidecar picture or video thumbnail (--no-pictures implies --no-video-thumbnails) - downloaded &= self.download_pic(filename=filename, url=sidecar_node.display_url, + downloaded &= self.download_pic(filename=sidecar_filename, url=sidecar_node.display_url, mtime=post.date_local, filename_suffix=suffix) if sidecar_node.is_video and self.download_videos: # pylint:disable=cell-var-from-loop - filename = self.__prepare_filename(filename_template, lambda: sidecar_node.video_url) + sidecar_filename = self.__prepare_filename(filename_template, lambda: sidecar_node.video_url) # Download sidecar video if desired - downloaded &= self.download_pic(filename=filename, url=sidecar_node.video_url, + downloaded &= self.download_pic(filename=sidecar_filename, url=sidecar_node.video_url, mtime=post.date_local, filename_suffix=suffix) else: downloaded = False diff --git a/instaloader/structures.py b/instaloader/structures.py index 3604f65..e2dab9f 100644 --- a/instaloader/structures.py +++ b/instaloader/structures.py @@ -296,7 +296,7 @@ class Post: end = len(edges)-1 if start < 0: start = len(edges)-1 - if any(self.get_is_videos()[start:(end+1)]): + if any(edge['node']['is_video'] and 'video_url' not in edge['node'] for edge in edges): # video_url is only present in full metadata, issue #558. edges = self._full_metadata['edge_sidecar_to_children']['edges'] for idx, edge in enumerate(edges): @@ -854,7 +854,7 @@ class Profile: self._obtain_metadata() return NodeIterator( self._context, - '472f257a40c653c64c666ce877d59d2b', + '003056d32c2554def87228bc3fd9668a', lambda d: d['data']['user']['edge_owner_to_timeline_media'], lambda n: Post(self._context, n, self), {'id': self.userid},