I was having the same and saw that you tried passing the same parameters to the request url. I took a look the the URL more carefully and noticed and unwanted character in my URL: https://services2.arcgis.com/fJJEXNgxjn0dpNsi/arcgis/rest/services/service_20dc5e3eab3f4efab8fde88f6027911b/FeatureServer/0/query?f=pjson&where=1=1&outFields=*&outStatistics=[{'onStatisticField': u'CreationDate', 'statisticType': 'max', 'outStatisticFieldName': 'lasteditdate'}]&token This u is what was causing my problem. In order to fix this I went back getMaxDate() function and changed statfield to a string: def getMaxDate(url, statfield, outfield, token):
stats = [{"onStatisticField": str(statfield), "statisticType": "max", "outStatisticFieldName": outfield}]
Hope this helps.
... View more