Skip to main content

StatsHouse client library for Python

Project description

statshouse

StatsHouse client library for Python. Requires Python 3.7+.

Installation

$ python -m pip install statshouse

Usage

import statshouse

statshouse.value("processing_time", {"subsystem": "foo", "protocol": "bar"}, 0.239)  # using named tags
statshouse.value("processing_time", ["foo", "bar"], 0.239)  # same, assuming `subsystem` and `protocol` are tags #1 and #2

statshouse exposes top-level functions which work with a local StatsHouse agent. Address of the agent is configured with --statshouse-addr command-line flag or STATSHOUSE_ADDR environment variable, and defaults to 127.0.0.1:13337. Additionally, --statshouse-env command-line flag or STATSHOUSE_ENV environment variable can be used to specify the env tag value for all metrics (empty by default).

Development

Install PDM, then:

$ pdm sync
$ pdm run fmt
$ pdm run lint
$ pdm run test

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

statshouse-0.2.1.tar.gz (8.1 kB view details)

Uploaded Source

Built Distribution

statshouse-0.2.1-py3-none-any.whl (8.7 kB view details)

Uploaded Python 3

File details

Details for the file statshouse-0.2.1.tar.gz.

File metadata

  • Download URL: statshouse-0.2.1.tar.gz
  • Upload date:
  • Size: 8.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: pdm/2.6.1 CPython/3.8.10

File hashes

Hashes for statshouse-0.2.1.tar.gz
Algorithm Hash digest
SHA256 d02fab137e66cfe4af1f511b6396816654e168165ae764e9e26e1168623ac679
MD5 d076c67ff6f1bee0a17966b5ee8a8620
BLAKE2b-256 83c84987d655545c87c642c2e71b175ac985044314ac668c04872363031896ce

See more details on using hashes here.

File details

Details for the file statshouse-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: statshouse-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 8.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: pdm/2.6.1 CPython/3.8.10

File hashes

Hashes for statshouse-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 d9cb00ca7183155657a0059ddaf5a81f97f43b5616734becde1dc4b0ca3f4b86
MD5 2725ce720d47a5349a32e077f690cdaa
BLAKE2b-256 f98f3e39874bd77749409c60aa659b85fd571e06cf94c5512cde04e16dbfc165

See more details on using hashes here.

Supported by

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