-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Harmonize low-level parsers #53
Milestone
Comments
|
Thanks for getting started on this. Please make each of these points a separate PR. |
I have already made the changes for I will make the pull request for these 2 now. |
This was referenced Nov 23, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The goal of readepi is to provide a unified interface to various health information system or common epidemiological databases. A key principle and the challenge is the harmonization of these very different data sources.
This harmony should also visible internally in low-level parsers to 1. facilitate the understanding of the package structure, thus making easier to maintain it and detect potential issues, 2. possibly eventually export these low-level parsers, as discussed in #45.
I see the following sources of inconsistency that should be addressed:
login()
ormake_api_request()
when they only apply to a specific data source. This video from Felienne Hermans, a researcher in software engineering, is a good resource of this topic.readepi/R/read_from_dhis2.R
Lines 39 to 41 in 11aa71e
readepi/R/read_from_dhis2-helpers.R
Line 13 in 11aa71e
assert_credentials(username, password)
, orassert_url()
)list(data)
where others returnlist(data, metadata)
. I understand metadata may be available only in some cases but the return values should be consistent across functions, even if it means returninglist(data = data, metadata = NA)
. This can again be enforced via roxygen's documentation inheritance.do.call(rbind.data.frame, ...)
vsdplyr::bind_rows(...)
;paste(collapse)
vsglue::glue_collapse()
, passing request parameters tohttr::GET()
as a list or directly in the URL, etc.)The text was updated successfully, but these errors were encountered: