Perfmetrics

Latest version: v4.0.0

Safety actively analyzes 630169 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 2 of 3

3.0.0

==================

- Drop support for EOL Python 2.6, 3.2, 3.3 and 3.4.

- Add support for Python 3.5, 3.6, and 3.7.

- Compile the performance-sensitive parts with Cython, leading to a
10-30% speed improvement. See
https://github.com/zodb/perfmetrics/issues/17.

- Caution: Metric names are enforced to be native strings (as a result
of Cython compilation); they've always had to be ASCII-only but
previously Unicode was allowed on Python 2. This is usually
automatically the case when used as a decorator. On Python 2 using
``from __future__ import unicode_literals`` can cause problems
(raising TypeError) when manually constructing ``Metric`` objects. A
quick workaround is to set the environment variable
``PERFMETRICS_PURE_PYTHON`` before importing perfmetrics.

- Make decorated functions and methods configurable at runtime, not
just compile time. See
https://github.com/zodb/perfmetrics/issues/11.

- Include support for testing applications instrumented with
perfmetrics in ``perfmetrics.testing``. This was previously released
externally as ``nti.fakestatsd``. See https://github.com/zodb/perfmetrics/issues/9.

- Read the ``PERFMETRICS_DISABLE_DECORATOR`` environment variable when
``perfmetrics`` is imported, and if it is set, make the decorators ``metric``,
``metricmethod``, ``Metric(...)`` and ``MetricMod(...)`` return
the function unchanged. This can be helpful for certain kinds of
introspection tests. See https://github.com/zodb/perfmetrics/issues/15

2.0

================

- Added the ``MetricMod`` decorator, which changes the name of
metrics in a given context. For example, ``MetricMod('xyz.%s')``
adds a prefix.

- Removed the "gauge suffix" feature. It was unnecessarily confusing.

- Timing metrics produced by ``metric``, ``metricmethod``, and
``Metric`` now have a ".t" suffix by default to avoid naming
conflicts.

1.0

================

- Added 'perfmetrics.tween' and 'perfmetrics.wsgi' stats for measuring
request timing and counts.

0.9.5

==================

- Added an optional Pyramid tween and a similar WSGI filter app
that sets up the Statsd client for each request.

0.9.4

==================

- Optimized the use of reduced sample rates.

0.9.3

==================

- Support the ``STATSD_URI`` environment variable.

Page 2 of 3

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.