Not a regular Python user, so LMK if I have a bad version or something easy.
Getting a syntax error no matter what options I try:
# es2csv -u localhost:9200 -i 'logstash-2016-1*' -r '{"query": {"range":{"timestamp":{"gte":"2016-12-02 00:00:00","lte":"now","time_zone":"-08:00"}}}}' -o out.csv -f '@timestamp,_type,host,vhost,method,urlpath,origparams'
Traceback (most recent call last):
File "/usr/bin/es2csv", line 7, in <module>
from es2csv import main
File "/usr/lib/python2.6/dist-packages/es2csv.py", line 211
out = {field: hit[field] for field in META_FIELDS} if self.opts.meta_fields else {}
^
SyntaxError: invalid syntax
Python:
Python 2.6.9 (unknown, Sep 1 2016, 23:34:36)
[GCC 4.8.3 20140911 (Red Hat 4.8.3-9)] on linux2
Not a regular Python user, so LMK if I have a bad version or something easy.
Getting a syntax error no matter what options I try:
Python: