Select to view content in your preferred language

Survey publishing hangs on "Updating survey form package"

2233
23
02-08-2024 01:57 PM
FOMELC01
Occasional Contributor

I have two surveys which hang regularly when I republish them. They seem to be OK when I update them on my phone, but I have to be concerned that there may be some unseen problem that will affect data collection. I don't want to give the survey out to my volunteers if there will be a problem with the data. I have not renamed the survey files or made any major changes. One survey is just a new version of an older survey with a couple new modules added, but I'm not trying to add those modules to the old survey. I'm creating an all new survey with those new modules.

Both surveys seem to consistently hang on republishing. 

0 Kudos
23 Replies
ChristopherCounsell
MVP Regular Contributor

The main historical cause for this is as others are described - there is a disconnect between the local and published content. This typically occurs when:

  • Content is renamed, deleted, moved or changed ownership of
  • This includes the items (form, layers) and the folder (if moving, you need to put the same
  • The local content has been modified outside of Connect (e.g. the survey file folder and contents like the .iteminfo...)

If you have the original XLSForm it's an easy fix:

  1. Create a new survey 
    • From file > target existing .xlsx; OR
    • Targeting the existing service, then replacing the .xlsx form in the new survey folder.
  2. Ensure the submission URL and survey is OK
  3. Unshare old survey, share new survey

You'll lose the connection between the survey and the feature layer it created, making it harder to add fields on republish, but otherwise Survey123 doesn't care. It'll submit the request against the target URL.

However there are other reasons that your survey may be having issues:

  • XLSForm design flaws - can you please share it?
  • Survey123 versions - can you please share the XLSForm and the version of Survey123 Connect you are using?
  • Reference content design issues - TPK too big, media/content issues
    • You can try uploading the TPK separately and linking it, instead of publishing with the survey

 Providing the Survey123 Connect logs from the time of publishing may also help.

Without this info we'll be stuck guessing. Survey123 is 'developer' territory for what can go wrong, it's hard to debug with limited info.

 

0 Kudos
FOMELC01
Occasional Contributor

The larger, more complex of the two surveys just published successfully (157 row XLSForm, 114mb of files), which rather surprised me. The smaller survey failed yesterday when I tried to publish.

Regarding the failed survey:

None of the content or folder has been renamed, deleted, moved or changed in ownership, except the .iteminfo file whose name was changed as suggested by others who've had issues with republishing.

I have attached the XLSForm and log file. I had to change .log to .txt to get it to send. My Survey123 Connect version is 3.19.104.

The TPK is 116mb and is the same one that was in the survey that just published successfully.

As I said earlier, the survey appears to have published successfully, despite having hung. I left it hanging overnight in case it would eventually resolve itself, but it didn't.

Because it appears to have successfully published despite hanging, I may just go with it and hope there are no problems with the data collected. On the other hand, I may try your suggestion to create a new survey from the XLSForm.

Thanks for your response.

 

0 Kudos
DougBrowning
MVP Esteemed Contributor

That is a pretty big file.  I have had some luck doing this.  Take out everything from the media folder and publish.  Then add the media back in and publish again.

Hope that does it

0 Kudos
FOMELC01
Occasional Contributor

Interesting idea. I'll give it a shot. Thanks.

0 Kudos
abureaux
MVP Frequent Contributor

I would love to publish this to test, but you have capitals in your name field and Enterprise doesn't like that 😞

I will have to leave this up to someone in AGO.

0 Kudos
FOMELC01
Occasional Contributor

I appreciate you taking a look.

0 Kudos
ChristopherCounsell
MVP Regular Contributor

Looking at the logs there's a 504 gateway timeout in response to the addItem. Is d7e408eb2fb842d993490220d0bcc620 the survey form or the .tpk? That's when it fails

Looking at your XLSForm:

  • The name of one of your repeats is 'Area'
  • The name of one of your fields is 'Comment'

Both of these are reserved keywords and should NOT be used. It'll give you a warning trying to build a survey using it. Some keywords will break Survey123 and it may not let you publish. Others will publish from Survey123 OK but give you a 500 error from the server. Other times it'll work fine until you reach a database that doesn't support it. They include a lot of general reserved words.

There's a good chance that this is the cause of your server error on publish. You need to fix this. It'll require your Hosted Feature Layer and survey to be republished. I'd recommend starting a new survey then migrating the existing data after (append in ArcGIS Pro with 'maintain globalids' and 'maintain attachments' should work fine).

We could suspect the .tpk but they can go up to 3gb apparently without issues. And I see they also publish OK.

 

FOMELC01
Occasional Contributor

Thanks! I appreciate your help.

I assume d7e408eb2fb842d993490220d0bcc620 is a number assigned to the survey by AGO, but I don't know. It could be the number assigned to the feature layer, but I deleted the survey and tried publishing it again, so I can't look to see if that's the case.

I'll change the 'Area' repeat to 'Polygon' and the 'Comment' field to 'Notes'.

I've used a "Comment' field in my surveys for miscellaneous text notes since 2017 without problems or warnings, but I can make that change. Is there a reference for these reserved keywords you can refer me to, so I can avoid these conflicts?

0 Kudos
DougBrowning
MVP Esteemed Contributor

Yes it is built into the excel sheet in Connect.

DougBrowning_0-1707751543261.png

 

FOMELC01
Occasional Contributor

Thanks!