Design and provide convenience wrapper for getting all submission data
- Dominant language
- Python
- Stars
- 39
- Forks
- 26
- Avg merge
- 22h 46m
- Merged PRs (30d)
- 1
Description
Currently `client.submissions.get_table` has [an interface](https://github.com/getodk/pyodk/blob/master/pyodk/endpoints/submissions.py#L108) that closely matches the backend API and it returns a dictionary that matches the structure of the raw JSON.
Some high-level things to consider for the parameters:
- make it easier to specify a date range to filter submissions by
- make it easier to specify a list of review states to include
- unify json and csv downloads -- they're not very different from a user perspective
- pull media if a path to store it is specified
- add the `Submissions.` prefix for repeats (see [repeats example](https://github.com/getodk/pyodk/blob/master/examples/working-with-repeats.ipynb))
Ideally the result could use type information in some way. Some ideas we've discussed:
- provide a companion endpoint to get types and document how to get that into `pandas`
- return `json['value']`: that would be the naturally-expected json structure
- return a normalized and typed `pandas` dataframe (downside: lib depends on `pandas`)
- deserialize into dynamically generated classes (downside: complex, and is it really what people want?)
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with client.submissions.get_table in pyodk/endpoints/submissions.py and review the working-with-repeats.ipynb example. First resolve which parameter and result design is wanted among the listed alternatives; done means an agreed convenience wrapper covers the selected submission filtering, download, media, repeat, and typing requirements.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- api, data
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100