Bug in vector to raster tool
Hornbydd opened this issue · 3 comments
When I run the vector Polygon to Raster tool as shown below it crashes with the error:
PolygonsToRaster National_Nature_Reserves_England nnr_name C:\Scratch\test.tif true 10 #
Start Time: Tue Feb 25 23:37:33 2020
Running script VectorPolygonsToRaster...Traceback (most recent call last):
File "", line 2671, in execute
File "c:\program files (x86)\arcgis\desktop10.6\arcpy\arcpy_init_.py", line 1260, in Describe
return gp.describe(value, data_type)
File "c:\program files (x86)\arcgis\desktop10.6\arcpy\arcpy\geoprocessing_base.py", line 376, in describe
self._gp.Describe(*gp_fixargs(args, True)))
AttributeError: Object: Error in parsing arguments for DescribeFailed to execute (VectorPolygonsToRaster).
Failed at Tue Feb 25 23:37:33 2020 (Elapsed Time: 0.03 seconds)
On looking at the code at line 2671 the line:
desc = arcpy.Describe(base)
Implies that the parameter base
is not actually an optional parameter, code needs modifying to resolve this, I am unsure how you are passing in "nothing" into the WBT when base is nothing?
wbt.vector_polygons_to_raster(i=i, field=field, output=output, nodata=nodata, cell_size=cell_size, base=base)
I can also replicate this error in the vector line and vector point to raster tools. Same issue when base raster is nothing.
@Hornbydd Thanks for reporting! I just committed code to fix this bug. Please re-download the toolbox and try again.
Can confirm that bug is fixed, allows tool to execute.