telefonicaid/fiware-sth-comet

Incorrect Response format when filetype=csv is used with hLimit and hOffset

Madhu-NEC opened this issue · 3 comments

When filetype=csv parameter is used in combination with hLimit and hOffset, API returns response in json format not in csv format.
Ideally, the response of API should be in csv format if filetype=csv is used.
For instance,
(http://localhost:8666/STH/v1/contextEntities/type/Room/id/Room1/attributes/temperature?hLimit=10&hOffset=0&filetype=csv) API returns response in JSON format.

I looks like a new bug in the filetype=csv functionality, similar to the one you discovered in #532. Maybe you could have a look and propose a fix in a PR, as you did with that issue?

Thanks!

Hi @fgalan,
As per my investigation, there is typo error for filetype in case of hLimit and hOffset. At this line, filetype is mentioned as "cvs" but it should be "csv".
I have raised the PR for the same.

Fixed in PR #540. Thanks!