question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Offline capability for "query parameter" authentication

See original GitHub issue

Hi dear Enketo team,

in the Enketo configuration docs it says under the heading “query parameter to pass to submission”:

Specifies the name of a query parameter that will be copied from an Enketo URL to the submission and formList requests. […] Does not apply to offline-capable webforms.

Source: https://enketo.github.io/enketo-express/tutorial-10-configure.html#query-parameter-to-pass-to-submission

Why does this not apply for Offline forms? I can actually make this work with ODK Central’s public links which - to my understanding - use this query parameter. To enable the Enketo Offline-mode, I change the /single/ part of the URL to /x/. No errors occur and I can successfully submit (first to queue, then to server).

What is the reason that this is not officially considered as working, and what would be needed to have it working officially?

Thanks!

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
lognaturelcommented, Sep 8, 2021

We’ve had ODK users make extensive use of offline public links so it’s definitely a combination of features that support should be maintained for and that we know works. It’s probably not how Central will eventually surface offline links if it ever does but the intent is to maintain that functionality. Thanks for following up, @vituslehner!

@eyelidlessness I think risks are more something that clients of Enketo (e.g. Central) should address in the context of their particular usage. For example, Central docs could say a little bit more about the mechanics of public links and their implications. In that case, the links are intended to be public so the token is more of a marker of uniqueness rather than a true secret.

1reaction
MartijnRcommented, Aug 31, 2021

Hi @vituslehner,

This dates back to the old days when Enketo was using ApplicationCache and a hack that abused the URL fragment identifier (#). Now that we’ve switched to ServiceWorkers, this restriction no longer applies, and it appears according to your findings that this magically started working.

Closing to continue here: https://github.com/enketo/enketo-express/issues/228

Read more comments on GitHub >

github_iconTop Results From Across the Web

Access data offline | Firestore - Firebase
Query offline data​​ Querying works with offline persistence. You can retrieve the results of queries with either a direct get or by listening,...
Read more >
adding query parameter to authorization_uri creates ... - GitHub
When creating the authorization uri to login with google, there is the option to add a query parameter in order to get back...
Read more >
OpenID API Request Samples for Offline Validation
The following are examples of OpenID Connect REST API requests to authenticate the end user or perform offline transaction signing when the HID...
Read more >
Prepare feature services for offline use—ArcGIS Server
When a read-only ArcGIS Server feature service (only query and sync are enabled) contains versioned data, no version is created when you take...
Read more >
Configure data items in offline mode
In the Offline Properties area, define offline mode query conditions for the data item to conform to. Create conditions using the Condition ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found