Is this a form you previously used with ODK Collect? The web preview is provided by Enketo which may not support features that this form uses. I think that's especially likely seeing simprints in the formId. Please try making a draft submission with Collect (more in the docs).
Yes, the form works in ODK Collect when uploaded on Aggregate server. I tried removing some functions like pulldata and the simprints, still getting the same error
Can you see previews or test forms for any other forms on your server?
As @Grzesiek2010 says, if other forms work, it would be helpful to see this specific form. If it's not sensitive, you can attach it to this post. If it is sensitive, you could direct message it to a member of the core team such as me or @Grzesiek2010. We would only use it to troubleshoot the error and then discard it.
Alternately, sharing the link to the draft page that shows the error message would be helpful. It should start with https://mlw.mw/-/. What I'd like to look at is whether there are any errors in the JavaScript console that could give us hints. You can also try this yourself -- on most browsers you can right click on the screen, select Inspect at the bottom of the menu and then find the Console tab.
Glad it's now working! If anyone else experiences this error, please share either the link to a failing draft page or errors in the JavaScript console. It seems like Enketo was not able to make successful requests to Central.
Thanks for sharing this information, @Chakshu_Gautam. Are you able to view other previews on that server? Does that form have a lot of logic?
The 504 error makes me think that the web form transformer is not able to process the form in a timely manner. You might be able to address this by increasing the CPU and RAM on your server. It's possible that a server restart would temporarily help because it would reset resource usage. However, that is likely not a long term solution.
These are the steps I followed post your suggestion. Increased the virtual cores from 1-4 and RAM from 2-8 GB. Docker restarts auto due to the service that central adds so didn't restart manually. The form that I am using is off the shelf - Survey on Household Characteristics.
On the docker logs, the Nginx logs show that it waits for quite some time before giving a 504.
Would it be possible for you to share the form? You can either attach it to a response here or if it's sensitive, you can send me a private message. Have you tried a small form with minimal logic? The most likely explanation is that there's something in the form structure that the preview engine (Enketo) cannot process in a timely manner. Unfortunately, you may not be able to use web previews with this form for now. Have you tried it on ODK Collect? You can use the testing tab to scan a temporary barcode and make test submissions.
Hey @LN, we've recently setup ODK Central. While ODK forms are working fine on a mobile app, web-forms through Enketo are not working. Attaching the form and sharing a screenshot of the error. Any solution around this?
Thanks for this, @Sandeep_Prabhu1! Did you experience this same issue and fix it by making sure your host doesn't have a firewall? Given how small the forms @Chakshu_Gautam and @Aayush_Kedia have shared are, an internal networking issue does seem a lot more likely than a true form transformation issue. Did you both follow the instructions @Sandeep_Prabhu1 references here? Are you on a host other than Digital Ocean that could have some other kind of internal firewall?