Python script to download Instagram livestreams and replays.
Mike L 8908a5aec6 Support two-factor login | 3 years ago | |
---|---|---|
.github | 4 years ago | |
pyinstalive | 3 years ago | |
.gitignore | 5 years ago | |
FAQ.md | 4 years ago | |
LICENSE | 7 years ago | |
MOREHELP.md | 4 years ago | |
README.md | 4 years ago | |
requirements.txt | 3 years ago | |
setup.py | 4 years ago |
Active development for this script has ended. Issues will no longer be looked into and no more updates will be made.
This Python script enables you to download any ongoing Instagram livestreams as well as any available replays. It is based on another script that has now been discontinued.
PyInstaLive is capable of downloading:
pyinstalive
to generate a default configuration file.pyinstalive -d "<live-username>"
to start downloading a livestream or replay.Make sure all tools are accessible via command line (added to your PATH if on Windows, use Google).
*Tip — To install PyInstaLive with the latest commit changes, remove the version tag from the install command (e.g. @3.2.4).*
Run the following command in your command line (might need to be run as administrator on Windows):
pip install git+https://github.com/dvingerh/PyInstaLive.git@3.2.4
To update PyInstaLive to the latest version (currently 3.2.4) run the following command:
pip install git+https://github.com/dvingerh/PyInstaLive.git@3.2.4 --upgrade
If you want to install a specific version of PyInstaLive when for example the newest version contains a bug, you can specify a different version tag in the install command:
pip install git+https://github.com/dvingerh/PyInstaLive.git@2.2.0
Use the version number you want after the @ symbol (e.g @2.2.0).
Make sure there is a configuration file called pyinstalive.ini
in the directory you want to run PyInstaLive from.
PyInstaLive will automatically generate a default configuration file for you to edit if one is not present already.
Here is an example of a valid configuration file:
[pyinstalive]
username = johndoe
password = grapefruits
download_path =
download_lives = True
download_replays = True
download_comments = true
show_cookie_expiry = True
log_to_file = True
ffmpeg_path =
run_at_start =
run_at_finish =
use_locks = True
clear_temp_files = False
do_heartbeat = True
proxy =
skip_merge = False
pyinstalive -u "johndoe" -p "grapefruits" -d "janedoe"
You can omit the username
and password
arguments if you have specified these in the configuration file:
pyinstalive -d "janedoe"
Below is an example of PyInstaLive's output after downloading a livestream:
> pyinstalive -d "janedoe"
---------------------------------------------------------------------------
[I] PYINSTALIVE (SCRIPT V3.2.4 - PYTHON V3.6.3) - 01-02-2019 06:56:29 PM
---------------------------------------------------------------------------
[I] Successfully logged into account: johndoe
---------------------------------------------------------------------------
[I] Getting info for 'janedoe' successful.
---------------------------------------------------------------------------
[I] Livestream available, starting download.
---------------------------------------------------------------------------
[I] Username : janedoe
[I] Viewers : 335 watching
[I] Airing time : 2 minutes and 8 seconds
[I] Status : Active
---------------------------------------------------------------------------
[I] Downloading livestream, press [CTRL+C] to abort.
---------------------------------------------------------------------------
[I] The livestream has been ended by the user.
---------------------------------------------------------------------------
[I] Airtime duration : 3 minutes and 13 seconds
[I] Download duration : 1 minutes and 7 seconds
[I] Missing (approx.) : 2 minutes and 6 seconds
---------------------------------------------------------------------------
[I] Waiting for comment downloader to finish.
[I] Successfully saved 19 comments.
---------------------------------------------------------------------------
[I] Merging downloaded files into video.
[I] Successfully merged downloaded files into video.
---------------------------------------------------------------------------
[I] There are no available replays.
---------------------------------------------------------------------------
I have not much time to extensively test the changes I make to the code, so when you do encounter a problem please open an issue and try using an older version of PyInstaLive in the meantime.
Python 2 cannot save most unicode characters in comments such as emojis if it's not built from source using the --enable-unicode=ucs4
argument. Read more about this here. This should probably not affect pre-installed Python 2 installations on Linux-based systems such as Ubuntu or Debian.
You can find a list of frequently asked questions here.
You can find a list of available commands and an explanation of the configuration file here.
If you would like to report a bug or ask a question please open an issue.