Closed bj8798 closed 4 years ago
@bj8798 thanks for reporting the bug, can you try upgrading to the latest SDK? If that doesn't work, please open a PR if you've got a working fix
This issue was reported on a version of the Python SDK that did not include support for Python 3 and hasn't had activity since - if this issue can be reproed on 1.6.6+, I'll reopen
Faced this issue while using splunklib with pyhton 3 lib version: 1.6.0 platform: Linux(centos) framework version: Python 3.7.2 Splunk version: 8.0.0 (build: 7f1fa0caa96a)
The error is coming when some of the data is coming in bytes format, following is the trace of the error.
In below code snippet, it is trying to concat bytes with str, so that it is throwing an error. Issues I can identify is,
value = repr(value).encode('utf-8', errors='backslashreplace')
is converting incoming data in bytes formatconcat performed in line
sv += value+ '\n'
, which will try to concat string and bytes.I changed above code like this to make it work, though I am not sure about decoding format. could you please look into it?