Skip to main content

Update package m3u8downloader to use aiohttp download m3u8 url

Project description

Update package m3u8downloader to use aiohttp to speed up download m3u8 url

Support disguised as img (png/jpg/jpeg) to decode into ts file

aiom3u8downloader base on package m3u8downloader (https://pypi.org/project/m3u8downloader, version: 0.10.1)

ffmpeg is used to convert the downloaded fragments into final mp4 video file.

Installation

To install aiom3u8downloader, simply:

$ sudo apt install -y ffmpeg
# python version >= python3.6
$ pip install aiom3u8downloader

Quick Start

Example command line usage:

aiodownloadm3u8 -o ~/Downloads/foo.mp4 https://example.com/path/to/foo.m3u8

If ~/.local/bin is not in $PATH, you can use full path:

~/.local/bin/aiodownloadm3u8 -o ~/Downloads/foo.mp4 https://example.com/path/to/foo.m3u8

Here is built-in command line help:

usage: aiom3u8downloader [-h] [--version] [--debug] --output OUTPUT
                           [--tempdir TEMPDIR] [--limit_conn LIMIT_CONN]
                           [--auto_rename] URL

download video at m3u8 url

positional arguments:
  URL                   the m3u8 url

optional arguments:
  -h, --help                  show this help message and exit
  --version                   show program's version number and exit
  --debug                     enable debug log
  --output OUTPUT, -o OUTPUT
                              output video filename, e.g. ~/Downloads/foo.mp4
  --tempdir TEMPDIR           temp dir, used to store .ts files before combing them into mp4
  --limit_conn LIMIT_CONN, -conn LIMIT_CONN
                              limit amount of simultaneously opened connections
  --auto_rename, -ar          auto rename when output file name already exists

Limitations

This tool only parses minimum m3u8 extensions for selecting media playlist from master playlist, downloading key and fragments from media playlist. If a m3u8 file doesn’t download correctly, it’s probably some new extension was added to the HLS spec which this tool isn’t aware of.

ChangeLog

  • v0.0.1

    • use aiohttp download m3u8 url

  • v1.0.3

    • remove multiprocessing package

    • release to pypi

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

aiom3u8downloader-1.0.3.tar.gz (22.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

aiom3u8downloader-1.0.3-py3-none-any.whl (23.3 kB view details)

Uploaded Python 3

File details

Details for the file aiom3u8downloader-1.0.3.tar.gz.

File metadata

  • Download URL: aiom3u8downloader-1.0.3.tar.gz
  • Upload date:
  • Size: 22.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.6

File hashes

Hashes for aiom3u8downloader-1.0.3.tar.gz
Algorithm Hash digest
SHA256 d190507fb7d18d423888527d834aa99850aa2ccc33b96d13ed83095c47cb7d4b
MD5 83a6f4500a79ca2969bfac94c6facd5f
BLAKE2b-256 118dff09358cad0bb249790f7c69596fee40cc1b09bbce818a49a6f8e0982439

See more details on using hashes here.

File details

Details for the file aiom3u8downloader-1.0.3-py3-none-any.whl.

File metadata

File hashes

Hashes for aiom3u8downloader-1.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 20422acdfefec80af0d6b4cd9fdca8f0b4d4bba623761081ca7a0dbab3e93d8d
MD5 a89957e9eb509e8ef16a4a3ba13a15ed
BLAKE2b-256 217172405fb6d82a2e3fe5cec93c51ba01e06d5782a021a249c98aaa3c499a32

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page