summaryrefslogtreecommitdiff
path: root/statsd
Commit message (Collapse)AuthorAgeFilesLines
* pyupgrade: Modernize syntax for Python >= 3.7Christian Clauss2022-12-034-11/+11
|
* Release v4.0.1James Socol2022-11-061-1/+1
| | | | The trove classifiers for Python versions was bothering me too much.
* Bump version to v4.0.0James Socol2022-11-051-1/+1
|
* Fix timing decorator for async functionsJames Socol2022-11-052-8/+38
| | | | | | | | | Well I sat on this for long enough that it got easier: async/await is no longer a syntax error in any supported version of Python. That meant that it was relatively straightforward to apply @nkonin's proposed patch from #119. Fixes #119.
* Remove __future__ importsJames Socol2022-11-059-15/+0
| | | | | | All of the features from __future__ that were in this library have been in Python since 3.0. Now that Python 2 is no longer supported, we no longer need them.
* Replace nose with nose2James Socol2022-11-051-4/+5
| | | | | | | Nose stopped getting updates around 2015. Nose2 is is the continued evolution of that project. Ultimately, this library's test suite is simple enough to move toward pure unittest, but that will require a larger refactor to wrap everything in unittest.TestCase.
* Add `close()` method to UDP clientJeremy Lainé2020-10-082-0/+9
| | | | | | Unlike its stream counterpart, the UDP client does not have a "close()" method. This means there is no public API to clean up the socket, resulting in a `ResourceWarning`.
* Fix regex string escape in testshintofbasil2018-11-161-1/+1
|
* Refactor client module into packageJames Socol2018-08-226-304/+303
| | | | | | | | | | | | The client module just broke 300 lines and had a lot of functionality in it. This breaks the single file up into a package and reduces a decent amount of duplication. Makes a few related changes: - Replaces old Python __future__ imports with new ones - Removes __all__ in favor of fewer imports - Refactors common stream code into StreamClientBase - Renames TCPPipeline to StreamPipeline for consistency (this is not a public class name)
* Introduce UnixSocketStatsClient class.Mateusz Moneta2018-08-213-1/+95
| | | | New client for handling sending stats through Unix domains sockets.
* Simplify timer decoratorJames Socol2018-08-211-2/+1
|
* Add timedelta support to Client.timingGijs van der Voort2018-08-212-1/+21
| | | | | Allow passing datetime.timedelta objects directly to StatsClient.timing(), automatically converting to milliseconds.
* Fix minor nits, spelling and unused importsfix-nitsJames Socol2018-08-211-1/+1
|
* Remove dependency on ABCMeta.James Socol2018-08-211-11/+3
| | | | | | | | | | | | | | StatsClientBase and PipelineBase are not intended to be public APIs, and the syntax for metaclasses introduces some complexity between Python 2 and 3. Since ABCMeta and abc.abstractmethod were only being used to guarantee that internal subclasses implemented these methods correctly, and there's no external behavioral issues on Python 3, where the metaclass has been ignored for years, let's remove the metaclass and rely on NotImplementedError() and the test suite as a backstop. Fixes #106.
* Skip IPv6 resolution testJames Socol2018-08-211-0/+2
| | | | | | | | | | | | | | | Since early June[1], IPv6 loopback address resolution has been flaky on TravisCI. It seems that it should have been flaky even earlier, or there's something strange going on. For now, skip the test. We can come back to diagnosing once master is (otherwise) passing. This failure first started on Python 2.6, but quickly spread to all versions. It appears to pass occasionally, but not on any consistent version. Lately it seems to fail more or less all the time, though on the latest cron build, it did pass on Pypy[2]. [1]: https://travis-ci.org/jsocol/pystatsd/builds/387167216 [2]: https://travis-ci.org/jsocol/pystatsd/builds/417687774
* Bug: Fix timer decorator with partial functions (#85)Mathieu Leplatre2017-08-302-2/+22
|
* Bug: Fix time shifts for python 3.3 and above.Sam Pegler2017-07-111-5/+12
|
* fix assert_called_once() callsLogan Rosen2015-11-211-3/+2
|
* Version 3.2.1James Socol2015-10-221-1/+1
|
* Don't break compatibility with code that uses ordered args instead ofIan Moore2015-10-221-4/+4
| | | kwargs
* Version 3.2v3.2James Socol2015-10-191-1/+1
|
* Future-proof float formattingJames Socol2015-10-191-1/+1
|
* Updated statsd client to allow less than 1 ms timingStephen Bunn2015-09-012-16/+15
|
* Ignore RuntimeErrors together with socket errorsJakub Stasiak2015-08-031-1/+1
| | | | | | | | | | When Python's standard library is patched with Eventlet the exception raised when two threads access the same socket simultaneously is RuntimeError and I think it makes sense to include it here. The downside is it may start ignoring too wide variety of exceptions but on the other hand I can't think of any other RuntimeErrors that can be raised here.
* Run flake8 on travis.James Socol2015-03-261-4/+0
|
* Handle IPv6 in default clientsJames Socol2015-03-263-2/+7
|
* Make IPv6 opt-in an explicit choice.James Socol2015-03-262-13/+41
|
* Version 3.1James Socol2015-03-181-1/+1
|
* Add TCPStatsClient and TCPPipelineMauro Stettler2015-03-173-4/+306
|
* Refactor tests to allow for multiple protocolsMauro Stettler2015-03-171-207/+388
|
* refactor StatsClient and Pipeline into base classesMauro Stettler2015-03-171-16/+50
|
* add ipv6 supportkeras2014-10-012-2/+9
|
* Optimize Pipeline by using a dequeDavid Blewett2014-08-121-4/+5
| | | | | | | | | This section of code is going to be pretty hot; it's best to optimize it as much as possible. It might be worth it to switch to a list for the data variable as well, and use '\n'.join(data) (vs. string concatenation). From: https://docs.python.org/2/library/collections.html#collections.deque "Though list objects support similar operations, they are optimized for fast fixed-length operations and incur O(n) memory movement costs for pop(0) and insert(0, v) operations which change both the size and position of the underlying data representation."
* Version 3.0.1v3.0.1James Socol2014-07-271-1/+1
|
* Made Timer.__call__ thread-safeBlake Caldwell2014-07-272-16/+36
|
* Version 3.0James Socol2014-05-091-1/+1
|
* Update test envs and trove classifiersJames Socol2014-05-091-1/+1
|
* Move default instances out of __init__.pyJames Socol2014-05-094-37/+35
|
* Version 2.1.2v2.1.2James Socol2014-01-071-1/+1
|
* Close gaps in client coverage.James Socol2014-01-071-0/+27
|
* Handle negative absolute gauges.James Socol2014-01-072-2/+37
| | | | | | | | - For negative absolute gauge values, zero out the gauge first, since StatsD can't distinguish it from a delta. - Add tests. - Patch via Ben Gilbert (https://github.com/bgilbert) - Fixes #40.
* Version 2.1.1v2.1.1James Socol2014-01-031-1/+1
|
* Fix timers used as decorators.James Socol2014-01-032-1/+6
|
* Do versioning simpler.v2.1James Socol2014-01-032-3/+2
|
* Version 2.1.James Socol2014-01-032-2/+3
|
* Guard against empty- or double- sending.James Socol2014-01-032-0/+25
|
* Rename some tests for clarityJames Socol2014-01-031-4/+4
|
* Give timers manual start/stop methods.James Socol2014-01-033-11/+63
|
* Merge pull request #38 from aleasoluciones/masterJames Socol2013-11-251-24/+16
|\ | | | | Small refactor to StatsClient
| * Refactor StatsClientGuillermo Pascual2013-11-191-24/+16
| |