Select to view content in your preferred language

Add async parameter to extract_changes the function (FeatureCollection)

348
1
03-28-2025 09:24 AM
Status: Open
Labels (1)
GFlonk
by
Occasional Contributor

The extract_changes function of a FeatureLayerCollection in the Esri Python API (arcgis python library) does not have an "async" parameter that can be used to indicate whether changes should be retrieved asynchronously or not. This setting is needed in combination with "fields_to_compare" and "return_ids_only" to determine which fields of which objects have been changed.

When I look at the source code of the API, I see that the function does not have an "async" parameter and in the "params" dictionary "async" is forced to True. When I manually change this, I get the desired result, however, this is not a sustainable solution. Additionally, this is impossible to modify in a notebook on ArcGIS Online, for example.

async.png
1 Comment
KenGalliher1

According to the /extractChanges parameter list, the returnIdsOnly parameter is what triggers the sync/async response. The function does not have a dedicated async parameter like most other functions.

Extract Changes (Feature Service) | ArcGIS REST APIs | Esri Developer

Using return_ids_only should work when using the Python API as well. I will look into the reasoning behind adding the "async": True option in the Python API. I believe this is misleading and causing confusion.