New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

ampdup

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ampdup

A type-hinted async python mpd client library.

  • 0.12.0
  • PyPI
  • Socket score

Maintainers
1

ampdup

A type-hinted async python mpd client library.

Summary

ampdup is an async/await based MPD library.

It is fully type-hinted and MPD responses are typed as well, so it is able to play nicely with mypy and autocompletion such as what is provided by jedi.

Examples

First a basic usage example. make() returns a connected client as a context manager that handles disconnection automatically.

async def main():
    async with MPDClient.make('localhost', 6600) as m:
        await m.play()

The IdleClient class provides the idle() function. Since ampdup is async/await-based this loop can easily run concurrently with other operations.

async def observe_state():
    async with IdleClient.make('localhost', 6600) as i:
        while True:
            changed = await i.idle()
            handle_changes(changed)

Todo

  • Support command lists.
  • Support connecting through Unix socket.
  • Support the more obscure MPD features such as partitions.

Keywords

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc