Skip to main content

kymoscope-collector

Site collector for Kymoscope. It runs on one host in a plant (normally the DMZ), reads an OPC UA server, a folder of logger files or your own Python source, encrypts the data and publishes it as Kymoscope streams. Outbound connections only; the disk buffer holds ciphertext.

Install

pip install kymoscope-collector              # core: OPC UA, CSV files, Python sources
pip install "kymoscope-collector[files]"     # + Parquet, TDMS and MF4 files
pip install "kymoscope-collector[windows]"   # + Windows service

Requires Python 3.10 to 3.13 (python.org or your distribution; the Microsoft Store Python cannot host the Windows service and service install refuses it).

  • Docker: ghcr.io/javijur/kymoscope-collector (mount a folder with collector.yaml at /data). The container runs as uid 10001, so give it the folder: sudo chown -R 10001:10001 /srv/kymoscope (or use --user). It stops with a clear message when /data is not writable.
  • Linux (systemd): sudo useradd --system --no-create-home --shell /usr/sbin/nologin kymoscope, then copy the unit file to /etc/systemd/system/. It ships in the package at <site-packages>/kymoscope_collector/packaging/kymoscope-collector.service (and in the repository at packages/collector/packaging/). Uncomment ReadWritePaths= for any folder a files source writes to (ProtectSystem=strict).
  • Windows service: runs as LocalSystem by default. For a dedicated account: sc config KymoscopeCollector obj= .\kymoscope password= ..., plus the "Log on as a service" right (sc config doesn't grant it), read access to the Python installation and the venv (so not a Python installed under C:\Users), modify rights on state_dir and on every watched folder (its done and failed folders too), and read access to state_dir\pki\own\key.pem if it already exists (it is private to the account that created it and doesn't inherit: icacls ...\pki\own\key.pem /grant kymoscope:R). The service restarts itself after any failure.

Before installing (for the plant's IT)

  • Application control (WDAC, AppLocker, Smart App Control): the service host pythonservice.exe from pywin32 is not code-signed (python.exe is). If unsigned binaries are blocked, allow it by path or hash, use Docker or WSL, or wait for the signed installer.
  • Outbound TCP 443 to Kymoscope, directly or through an HTTP proxy (below). Nothing inbound.
  • Python 3.10 to 3.13, installed for all users if the service runs under a dedicated account. Not the Microsoft Store Python.

Updating

pip can't replace files while the service runs (WinError 32), so stop it first:

kymoscope-collector service stop --config C:\ProgramData\Kymoscope\collector.yaml
pip install -U "kymoscope-collector[windows]"
kymoscope-collector service start --config C:\ProgramData\Kymoscope\collector.yaml

Docker: docker pull ghcr.io/javijur/kymoscope-collector, then remove and recreate the container with the same options. systemd: systemctl stop kymoscope-collector, pip install -U kymoscope-collector in the unit's environment, systemctl start kymoscope-collector. The buffer and certificates in state_dir survive the update.

Proxy

proxy: env:KYMOSCOPE_PROXY      # http://host:port or http://user:password@host:port (percent-encode @ : \)
no_proxy: [historian.plant.local]

Both the HTTPS calls and the relay WebSocket tunnel through it (HTTP CONNECT, Basic auth); OPC UA never does. A Windows service doesn't see a user's Windows proxy settings, so set it here. The log never shows the credentials.

Code-signed installers are coming.

Quick start (no plant needed)

kymoscope-collector simulate                                   # demo OPC UA server on port 4840
kymoscope-collector browse --url opc.tcp://localhost:4840 --out tags.csv
kymoscope-collector run --config collector.yaml

A minimal collector.yaml:

api_key: env:KYMOSCOPE_API_KEY
sources:
  - name: Demo plant
    type: opcua
    url: opc.tcp://localhost:4840
    security: None
    allow_insecure: true      # demo server only
    tags: tags.csv

Notes:

  • Unknown keys in collector.yaml are an error that lists the valid ones; a password with security: None is allowed but logged as a warning.
  • Editing tags.csv reconnects the source, so its tags have a short gap.
  • One OPC UA source handles about 2,000 tags reporting at distinct millisecond times per second. Split larger tag lists into several type: opcua sources with different tags files.
  • The enumeration labels are not sent. Blocks wait in a memory queue bounded by buffer.memory_mb (default 256) while a stream cannot register; the oldest are dropped and counted in <source>.queue_dropped.
  • The private key state_dir/pki/own/key.pem is created owner-only (0600; on Windows user, SYSTEM and Administrators).

Other commands: cert (show or renew the collector's certificate), service install|remove|start|stop (Windows), discover --config collector.yaml --source NAME --out tags.csv (the tags a configured source offers) and backfill --config collector.yaml --source NAME --from 2026-10-01T00:00:00Z --to 2026-10-02T00:00:00Z (a time range of a source's history sent into its stream, marked historical, for sources that keep history).

Source types

Each sources entry has a type. Install the extra for the types you use; extras combine (pip install "kymoscope-collector[mqtt,sql]").

type Reads pip extra
opcua OPC UA servers (with history backfill) core
opcda OPC DA (Classic) servers, Windows only opcda (+ windows)
mqtt MQTT brokers, Unified Namespace, Sparkplug B mqtt
modbus Modbus TCP / RTU, SunSpec inverters modbus
sql Databases; AVEVA Historian, IP.21 and Timescale presets (validate on your system) sql
rest REST APIs; Canary and Proficy presets (validate on your system) rest
webhook Receives pushed JSON webhook
files CSV (core), Parquet, TDMS, MF4 files for non-CSV
python Your own adapter class core

Anything else: expose it as OPC UA or MQTT with a gateway (Kepware, Ignition Edge, Matrikon, Node-RED, Telegraf...). discover and backfill (above) work with any source type that supports them.

Documentation

  • Install, collector.yaml reference, certificates, security, health, troubleshooting, and "Which source do I use?": https://kymoscope.com/docs/collector
  • Per source: /docs/collector-opcda, -opcua-history, -mqtt, -modbus, -sql, -rest, and /docs/collector-gateways for protocols the collector does not read natively.

Metadata

Release files for kymoscope-collector 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for kymoscope-collector 0.2.0
File Size Uploaded Provenance Actions
kymoscope_collector-0.2.0.tar.gz 156.5 kB With provenance Details for kymoscope_collector-0.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for kymoscope-collector 0.2.0
File Interpreter ABI Platform Actions
kymoscope_collector-0.2.0-py3-none-any.whl Python 3 none any Details for kymoscope_collector-0.2.0-py3-none-any.whl

Total release size: 272.3 kB

Release files / kymoscope_collector-0.2.0.tar.gz

Download URL kymoscope_collector-0.2.0.tar.gz
Size 156.5 kB
Tags Source
SHA-256 checksum
How to use checksums
d336edd4891f683dd67d5f2c70d33c347c3b78c994b1ae4e7c671cce59be509f
BLAKE2b-256 checksum
How to use checksums
2549984749e6eabafcec131857b7715df6f1b4a6fdaf24c7a951f0e63dd95ab4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Release files / kymoscope_collector-0.2.0-py3-none-any.whl

Download URL kymoscope_collector-0.2.0-py3-none-any.whl
Size 115.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5241b4fcef65be656b3263a90ff519b35a38ffde6acc9f917dbe2196be5ad825
BLAKE2b-256 checksum
How to use checksums
89c3e95c946e0e21bc284c2e7456dae8d3d32b83f05d492326b57c1aff433514
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

Security for kymoscope-collector 0.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for kymoscope_collector-0.2.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 24, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page