[Solved] Arcpy: RuntimeError: ERROR 999998: Unexpected Error.

Summarize the reasons why individuals encounter such errors when using arcpy to batch process raster data:

1. Because the supporting python of ArcGIS is 2.7, sometimes the file name is read in some hexadecimal codes with many slashes, resulting in the wrong naming of the output file name and unable to output

Solution: carefully check whether the input and output file names are correct

2. There are many files with different suffixes (for example, raster data also has files with .DBF suffix) in addition to the files that can be seen in ArcMap, so it is inevitable to make mistakes when reading in and reading out some suffix files in batch processing.

Solution: when batch processing, sort out the folders in advance, and put all kinds of or similar data together. Don’t mix them.

Read More: