Synthèse
Controls whether information about the operation of geoprocessing tools is written to an external log file.
Discussion
In a script, history logging is enabled by default. To disable history logging, use arcpy.SetLogHistory(False).
To limit the duration of history logging, use the LogHistory class as a context manager or decorator.
To control whether geoprocessing tool input and output datasets' metadata is updated, use the SetLogMetadata function.
Syntaxe
SetLogHistory (log_history)
| Paramètre | Explication | Type de données |
log_history | Specifies whether geoprocessing history logging is enabled.
| Boolean |
Exemple de code
Disable history logging, if enabled.
import arcpy
if arcpy.GetLogHistory():
arcpy.SetLogHistory(False)Rubriques connexes
Vous avez un commentaire à formuler concernant cette rubrique ?