[gdal-dev] Strange behavior opening CSVs

Simon Eves simon.eves at omnisci.com
Tue Nov 9 10:49:09 PST 2021


That makes sense. Thanks. Our plan is to trap CSV files before invoking the
GDAL identification.

The second part does seem like a bug, though.

On Mon, Nov 8, 2021 at 11:47 PM Rahkonen Jukka (MML) <
jukka.rahkonen at maanmittauslaitos.fi> wrote:

> Hi,
>
>
>
> The trial with gdalinfo makes GDAL to try XYZ
> https://gdal.org/drivers/raster/xyz.html?highlight=xyz. It is not a bad
> guess at all. Ogrinfo tries CSV and finds the x, y, and val fields. I can’t
> say anything about the second part.
>
>
>
> -Jukka Rahkonen-
>
>
>
> *Lähettäjä:* gdal-dev <gdal-dev-bounces at lists.osgeo.org> *Puolesta *Simon
> Eves
> *Lähetetty:* tiistai 9. marraskuuta 2021 2.21
> *Vastaanottaja:* gdal dev <gdal-dev at lists.osgeo.org>
> *Aihe:* [gdal-dev] Strange behavior opening CSVs
>
>
>
> I am currently implementing a better file identifier, and during the
> course of development, I unintentionally let GDAL try to GDALOpenEx() the
> attached trivial CSV file.
>
>
>
> First, it reported "Ungridded dataset: At line 3, change of Y direction"
> (as a warning to the registered error-handler) and the returned
> OGRDataSource* was null.
>
>
>
> When I tried again, it then claimed that I was trying to open the same
> file recursively. implying that it had, in fact, opened it, even though it
> never returned a valid handle, so I wouldn't have been able to close it
> again even if I'd wanted to.
>
>
>
> I can reproduce the first part with gdalinfo.
>
>
>
> This is with GDAL 3.2.2 on Ubuntu 20.04 with GCC 9.
>
>
>
> I'll poke at the GDAL code myself when I have a bit more time.
>
>
>
> --
>
> <http://www.omnisci.com/>
>
> *Simon Eves*
>
> Senior Graphics Engineer, Rendering Group
> 100 Montgomery St (5th Floor), San Francisco, CA 94104, USA
>
> Email: simon.eves at omnisci.com | Cell:
>
> +1 (415) 902-1996
>
>
>


-- 
<http://www.omnisci.com/>
Simon Eves
Senior Graphics Engineer, Rendering Group
100 Montgomery St (5th Floor), San Francisco, CA 94104, USA


Email: simon.eves at omnisci.com | Cell:  +1 (415) 902-1996
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20211109/9c61c262/attachment.html>


More information about the gdal-dev mailing list