skillfed

lomond

Websocket Client Library

lomond v0.3.3 937.5K downloads/30d#4,690 on PyPI244
Permissive license Active released

What it is and what it does

Lomond is a WebSocket client that wraps raw WebSocket connections into an event-driven interface. Instead of managing threads or callbacks, you construct a WebSocket object and iterate over it, receiving event objects for each connection state change and incoming message. The library handles the WebSocket handshake and protocol details internally, yielding events like Connecting, Connected, Ready, Binary, Text, Poll, Closed, and Disconnected as the connection progresses.

The package depends only on six for Python 2/3 compatibility and is designed for straightforward, synchronous WebSocket consumption. It's useful when you want to read from a WebSocket in a simple loop without concurrent connection management, though the gap between the latest release (2018) and current date means you should verify compatibility with modern Python versions before relying on it for new projects.

Use it for:

  • Build a simple WebSocket client that polls a server and processes incoming text or binary messages in a single event loop
  • Connect to public echo or test WebSocket servers to verify connectivity or debug protocol behavior
  • Implement a basic real-time data consumer that receives updates from a WebSocket and processes them sequentially
  • Create a command-line tool that maintains a persistent WebSocket connection and reacts to server events

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Lomond is a WebSocket client library that converts WebSocket connections into an event stream, allowing you to iterate over connection and message events without threads or callbacks.

Yes, if you need a lightweight, event-driven WebSocket client for Python and are comfortable with a library whose latest release is from 2018. The active repository and permissive license are positive signals, but verify Python version compatibility for your target environment before committing to it in new projects. For modern applications, consider whether a more recently maintained alternative better suits your needs.

Install

lomond on PyPI

pip

pip install lomond

uv

uv add lomond

poetry

poetry add lomond

Installing lomond

Before you install

Low install friction with a single lightweight dependency (six). The package is marked as active with recent repository activity (last commit 2026-07-06), though the latest PyPI release dates to 2018-09-21.

License in practice

Licensed under a permissive BSD license, allowing commercial and private use with minimal restrictions.

Quickstart

from lomond import WebSocket

websocket = WebSocket('wss://echo.websocket.org')
for event in websocket:
    if event.name == 'text':
        print(event.text)
    elif event.name == 'poll':
        websocket.send_text('message')

Verify before relying

  • Current Python version support: classifiers list 2.7, 3.3–3.6, but requires_python is unspecified and latest release is from 2018
  • Whether repository activity since 2018 includes bug fixes or is maintenance-only

Package facts

License not declared (permissive)
Python support not specified
Install friction low — pure-Python wheel
Runtime dependencies 1 — six
Maintenance actively maintained — 2,884 days since the last release
Last repo commit
First released
Downloads 937,485/month — #4,690 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: lomond-0.3.3-py2.py3-none-any.whl

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: BSD LicenseProgramming Language :: PythonProgramming Language :: Python :: 2.7Programming Language :: Python :: 3.3Programming Language :: Python :: 3.4Programming Language :: Python :: 3.5Programming Language :: Python :: 3.6Topic :: Internet

Tags

websocket client libraryevent-driven websocketwebsocket connection streamingpython websocket eventsws wss clientwebsocket without threadswebsocket event iteration
websocket-clientevent-drivennetworking

More Internet packages