[QGIS-Developer] gdal2xyz.bat not accepting -b any band number

Alexandre Neto senhor.neto at gmail.com
Thu Jun 23 17:29:25 PDT 2022


I am testing the GDAL tools on QGIS 3.22.8 on Windows. When running
gdal2xyz with a single band raster I am getting the following error:

C:\Users\testing_user>gdal2xyz.bat -b 1
C:/Users/testing_user/Desktop/gdal_commands_test/mdt_clipped.tif OUTPUT.csv
usage: gdal2xyz.py [-h] [-skip] [-srcwin xoff yoff xsize ysize] [-b band
[band ...]] [-allbands] [-csv] [-skipnodata]
                   [-srcnodata [SRC_NODATA ...]] [-dstnodata [DST_NODATA
...]]
                   src_dataset dst_dataset
gdal2xyz.py: error: argument -b/-band/--band: invalid int value:
'C:/Users/testing_user/Desktop/gdal_commands_test/mdt_clipped.tif'

If I remove the -b option it works.

Windows Is now on GDAL 3.5.0. On my linux machine that still uses GDAL
3.0.4 it works fine.

Bug report? In here or in GDAL?

Alexandre Neto
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20220624/21825562/attachment.htm>


More information about the QGIS-Developer mailing list