Closed gmoigneu closed 2 years ago
Hi @gmoigneu,
thanks for using our client.
I've prepared PR #101. If you would like to use dev version of client then install client via:
composer require influxdata/influxdb-client-php:fix/response-with-new-line
Regards
Oh that's amazing @bednar ! Thank you so much for this. I confirm it works flawlessly.
Without the PR, I got it to work with a regex to circumvent the issue:
|> map(fn: (r) => ({
r with
msg: regexp.replaceAllString(r: /(\r\n|\r|\n)/, v: r["http.msg"], t: "")
})
)
Steps to reproduce:
Expected behavior:
The response should escape weird characters in a field and not detect them as end of line.
Actual behavior:
The parser detects "\n" as end of line:
We end up with a row that has less array values than the headers. Triggering an exception on
parseRecord()
:Specifications: