RespectDaylightSavings Error after Portal 10.9.1 Upgrade

2736
12
Jump to solution
12-16-2021 05:20 AM
AndrewKesterton
New Contributor III

Hi Survey123 community, 

Following an upgrade of our ArcGIS Enterprise to ArcGIS Portal/Server 10.9.1, hosted feature services that were created from Survey 123 Connect with a survey start and end time started returning an error on query; 

{"error":{"code":500,"message":"JSONObject[\"respectsDaylightSaving\"] not found.","details":[]}}

This error is only returned for queries with the the start and end times in the outputFields, if manually querying the feature service for different attributes then the data is returned OK. 

In the feature service definition, Survey123 Connect has created the feature service with a time zone defined, and the property: respectDaylightSaving (note the difference from the error, where it is looking for respectsDaylightSaving). 

The timeInfo section of the layer definition in the feature service looks like this;

 

 "timeInfo": {
  "startTimeField": "survey_start_dt",
  "trackIdField": null,
  "endTimeField": "survey_end_dt",
  "timeInterval": 0,
  "timeExtent": [],
  "timeReference": {
   "timeZone": "UTC",
   "respectDaylightSaving": false
  },
  "hasLiveData": false,
  "timeIntervalUnits": "esriTimeUnitsMilliseconds"

 

 

Using the Server Administration API I can change the time zone definition to instead have the property respectsDaylightSaving.  This corrects the error, and all queries return correctly.  The new timeInfo section of the service is below;

 

   "timeInfo": {
    "timeReference": {
     "timeZone": "UTC",
     "respectsDaylightSaving": false
    },
    "timeInterval": 0,
    "timeIntervalUnits": "esriTimeUnitsMilliseconds",
    "hasLiveData": false,
    "trackIdField": null,
    "startTimeField": "survey_start_dt",
    "endTimeField": "survey_end_dt",
    "timeExtent": []
   }

 

 

While that resolves the problem, it isn't ideal to manually edit all services created by Survey123.

Does anyone know which is the correct definition?  Is the bug with ArcGIS Server 10.9.1 in looking for respectsDaylightSaving, or is the bug in Survey123 connect for creating the service with the  respectDaylightSaving property on the time zone?

The only reference I can find is in this ESRI blog post from last year that indicates it should be respectsDaylightSaving.

Recreating the Error

 We are using Survey 123 Connect 3.13.246, and i can recreate the issue by publishing a new service using any template and adding the survey start and end times to the XLSForm;

typenamelabel
startsurvey_start_dtSurvey Start Time
endsurvey_end_dtSurvey End Time

 

Once the survey is published, and the hosted feature service created by Survey123 connect,  if I then submit some records into the new hosted feature service it will start returning the respectdaylightsavings error above. 

Thanks for any help resolving this, I have also submitted a support case for the issue (#02958232).

Andrew

1 Solution

Accepted Solutions
ZacharySutherby
Esri Regular Contributor

Hello @GeoNicole@Javier_Pintos@JakeMatthys

Attached is a notebook that will assist with updating your existing layers that are encountering the issue. 

The notebook loops through each feature service you own in your Portal, then loops through each layer in the feature service, and identifies if `respectDaylightSaving` is present in the layers JSON. If so, it will update the property to `respectsDaylightSaving` (the correct property) and update the service's JSON. 

Thank you,
Zach

View solution in original post

12 Replies
ZacharySutherby
Esri Regular Contributor

Hello @AndrewKesterton

Thank you for reporting this! It seems we have an issue when creating the service definition during survey publishing and 10.9.1 seems to have become more strict on the parameter. 

I've created an issue on our end to correct this behavior when publishing feature services from Survey123 Connect. You are correct including the "s" is correct in "respectsDaylightSaving". Please have the owner of your Support case log a BUG against Survey123 Connect. Unfortunately the workflow you had used for manually updating the definition is the best way I know of other then using the Python API to update it from there.  

Thank you,
Zach
AndrewKesterton
New Contributor III

Hi Zach, 

Thanks for your response, sorry I've taken a bit of time to get back to you after the holiday period. 

I'll update the remaining services through the rest API.  In the meantime tech support have logged BUG-000145620 in case anyone else encounters the same issue and wants to be associated with it. 

Happy new year to all in the Survey 123 space 🙂 

Andrew

 

0 Kudos
JakeMatthys
Occasional Contributor II

We just upgraded from Enterprise 10.9 to 10.9.1 and are affected by this bug as well...

Javier_Pintos
New Contributor III

Hi everyone,

We have some problem after upgrade to ArcGIS Enterprise 10.9.1

Temporally we had edited services definitions by admin page of ArcGIS Server:

https://webadaptor.company.com/server/admin/services/Hosted/service_1234567890abcdefg.FeatureServer/...

Adding "s" in "respectsDaylightSaving".

Now we are testing result.

If there are some patch solving this, please post it.

Thank you!

Javier

0 Kudos
GeoNicole
New Contributor II

We are experiencing the same issue - seems to be with all Survey123 layers. Might be additional complications because most of the impacted layers are in Saskatchewan, being the odd one out for DST. Having a little trouble locating where to do the updates though, as the layers I'm looking at don't have a time definition section in them already! (yes, also working with support, but we went pretty far along the wrong path before looping back to this)

0 Kudos
ZacharySutherby
Esri Regular Contributor

Hello @GeoNicole@Javier_Pintos@JakeMatthys

Attached is a notebook that will assist with updating your existing layers that are encountering the issue. 

The notebook loops through each feature service you own in your Portal, then loops through each layer in the feature service, and identifies if `respectDaylightSaving` is present in the layers JSON. If so, it will update the property to `respectsDaylightSaving` (the correct property) and update the service's JSON. 

Thank you,
Zach
JohnBickmore
New Contributor III

We upgraded to 10.9.1 from 10.8.1 on the weekend. I have 2 surveys which used start and end survey which will not show any attributes. One of the surveys has a nested repeat which has a nested repeat. The nested repeat and the nested nested repeat appear fine but I cannot see the main feature layer attributes. I can export the FGDB and display the features in PRO.

Can you please advise how i get into the server admin API so I can update the json. I am able to see the json and it matches the json in the screenshot above, however I am unable to edit it?

I tried opening the notebook in PRO but recieved an error message. It is only affecting 2 surveys so I am happy to edit the JSON directly.

I am keen to fix this ASAP as this project is just starting to ramp up.

Thank you

Regards

John

 

0 Kudos
K_Wa
by
New Contributor II

Assuming you're logged into the Server Admin with an administrator account you should be able to edit the JSON at Server Admin page --> Hosted --> [Service] --> Click the 'Edit' link in the Support Operations portion at bottom of the page.  

 

Are you saying you can get to that edit page but the JSON isn't editable?

0 Kudos
JohnBickmore
New Contributor III

Hi

I had 2 surveys with this issue. Both had start and end so I could determine the time spent at each site. We were able to edit the JSON for one of them. Just adding the s to respect fixed the survey. When we tried to make the same change to the second survey we were unable to save the JSON. We got an error message when we press save and it does not actually save. the Error message is below. The survey still works and the nested repeat and nested nested repeat features are showing, however the main feature layer does not show any attributes. I am sure we just need to add that S.

The error message looks to be related to a survey question about solar exposure (to determine if solar panels would be a viable power source for telemetry). In the hint collumn for this is the text "direct sunlight during daylight hours". Could the word "daylight" be an issue???

 

Error

  A JSONObject text must begin with '{' at character 1 of 50%)",
        "code": "Good"
       },
       {
        "name": "Medium (25-50%)",
        "code": "Medium"
       },
       {
        "name": "Poor (

Code

  500

 

0 Kudos