JMXQuery
JMXQuery copied to clipboard
Python27 support
Python 2.7 tests passing:
`(venv)$ python --version Python 2.7.16 (venv)$ nosetests -v tests/test_JMXQuery.py tests.test_JMXQuery.test_wildcard_query ... ok tests.test_JMXQuery.test_kafka_plugin ... ok This test is to check that we don't get any threading issues as the module will be ... ok
Ran 3 tests in 9.018s
OK `
Python 3.6 tests passing:
`(venv)$ source ../venv3/bin/activate (venv3)$ python --version Python 3.7.3 (venv3)$ nosetests -v tests/test_JMXQuery.py tests.test_JMXQuery.test_wildcard_query ... ok tests.test_JMXQuery.test_kafka_plugin ... ok This test is to check that we don't get any threading issues as the module will be ... ok
Ran 3 tests in 8.689s
OK `
fixes issue #15
Updated with the recommendations, except for two things.
-
The builtin subprocess module in python 2.7 doesn't include a timeout option or the run() method call, which this uses.
-
enum appears to be included in the python 2.7 standard library.
I found that nosetests swallows any print statements by default, except if you use the '-s' or '--nocapture' option. The following gist shows the results of the tests.
https://gist.github.com/chorejasbob/890137b096ffae50dc86158d60c0c062