vklochan/python-logstash

AttributeError: module 'logstash' has no attribute 'LogstashHandler'

yuseferi opened this issue · 6 comments

my Logstash is up and running in my system but when I wanted to test you sample code faced with

AttributeError: module 'logstash' has no attribute 'LogstashHandler'

while I've installed logstash package in my system.

python version : 3.6

Are you trying extends the LogstashHandler or something like this? LogstashHandler is just a variable to address to UDPLogstashHandler for default.

nav1n commented

I had this same issue, you might be using the old logstash package, you can try:
pip uninstall logstash
pip install python-logstash

Looks like the issue was resolved.
In case of any problems, please reopen this issue.

JJ commented

I had exactly the same problem running the example on the main Pypi page. python-logstash version is 0.4.6, the mentioned logstash is not installed. I have tested it with two Python versions. 3.9 and 3.8.6

@JJ had the same issue after accidentally installing the old package. Uninstalling both and reinstalling the new one solved my issue

pip uninstall logstash
pip uninstall python-logstash

pip install python-logstash

it is not working for me