Skip to main content

Danmu for humans.

Project description

danmu-abc

获取哔哩哔哩直播斗鱼直播虎牙直播以及 个人项目 YjMonitor 自定义的弹幕推送,详细可见 examples 部分。可选用 websocket 协议与 tcp 协议,其中 websocket 协议使用了 aiohttp 的 api。

接口:

  1. run_forever 是程序核心,使用一个 while 循环实现掉线的自动重连(掉线后,close 掉现在的连接,重开一个新的)。每次的连接分三步,建立并 OAUTH(即 _one_hello)心跳接受部分启动并永久执行直到异常或主动关闭、异常或主动关闭后的清理工作。清理完后,重新开启新的连接。
  2. close_and_clean 用于永久地关闭连接。
  3. pause 用于暂停连接,暂停后,连接是断开的。直到 resume 唤醒。

版权问题:

  1. 本代码 fork 自 blivedm,由于与原作者一些观点不同,并未走向一致,后由于一些原因,在于原作者协商后切断 fork 关系。LICENSE 也进行相应变动。

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

danmu_abc-0.1.5.tar.gz (5.6 kB view details)

Uploaded Source

Built Distribution

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

danmu_abc-0.1.5-py3-none-any.whl (6.8 kB view details)

Uploaded Python 3

File details

Details for the file danmu_abc-0.1.5.tar.gz.

File metadata

  • Download URL: danmu_abc-0.1.5.tar.gz
  • Upload date:
  • Size: 5.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.56.2 CPython/3.9.1

File hashes

Hashes for danmu_abc-0.1.5.tar.gz
Algorithm Hash digest
SHA256 57e489d7b55f238e2c0b2ddf4167ea2d6a20072402901469bcf0feaa5cf7f14a
MD5 ac19b04521414f6703fa519e4b2dd934
BLAKE2b-256 b202a4ac238154f0dd17f7fa0266b8781f4db1dcf938b9a10e83c6aa6d30ee3e

See more details on using hashes here.

File details

Details for the file danmu_abc-0.1.5-py3-none-any.whl.

File metadata

  • Download URL: danmu_abc-0.1.5-py3-none-any.whl
  • Upload date:
  • Size: 6.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.56.2 CPython/3.9.1

File hashes

Hashes for danmu_abc-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 359c5eda0c92bfc437342be84a19d3129994c409fcd36978b0d032cb92e943ae
MD5 0c95fb41b6057a5864881468e47173f9
BLAKE2b-256 17ed154b9c82b9fde89771b036a75e24d57874bfec4a0ec2cf0b3a0825ae19c8

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