Skip to content

Features/update apiv3#5

Merged
bangtranl merged 60 commits intomainfrom
features/update_apiv3
Aug 26, 2025
Merged

Features/update apiv3#5
bangtranl merged 60 commits intomainfrom
features/update_apiv3

Conversation

@a-asil-companioni
Copy link
Copy Markdown
Member

This is the version currently on CRAN. There are certain documentation related changes on the dev branch, but the main branch should likely be what is available on CRAN.

- Note: The base / native pipe operator was introduced in the R 4.1.0 update.
- Remove calls to import the magrittr library or calls to import the pipe specifically.
- Replace existing magrittr pipe calls with the base R pipe.
- This is as opposed to using jsonlite::fromJSON(). Using httr2::resp_body_string() and then fromJSON() is not as clean as just using httr2::resp_body_json(). httr2::resp_body_json() does uses fromJSON() under the hood.

- Some comments were edited or added to reflect the changes in code, particularly regarding the use of as.data.frame() and the expectation that resp_body_json(response, simplifyVector=TRUE)$result will likely be a dataframe.
- The refactoring is such that the codebase becomes more in line with the tidyverse style guide.

Refactor codebase and remove unneeded comments

Refactor edit
Change version from 0.0.3 to 0.1.0
withr is an R library that allows changes to state to be reverted and managed cleanly.

Add withr package to DESCRIPTION file
The large deletion and emphasis on referring to the introduction just means that there's much less repetition and that the changes to the introduction vignette are reflected in what users are likely to read.
Update Roxygen2-generated files
Edit _pkgdown.yml to reflect change in introduction.Rmd
It is not being used.
…ks run.

This is because get_subscription_key() returns an error if it is neither retrievable through the environment variable or through accessing the package encryption key (when in a testthat environment). It does not return, as had been accidentally implied, an empty string "" when neither is available. The commit uses the environment variable that the function relies on directly instead. However, one should take note that if the name of the environment variable is redefined in the function, then the environment variable specified in the logic of the Rmarkdown files should be changed as well.

If the package key should be used in contexts other than that of testthat(), then the logic will need to be revisited given the complications that will introduce. For now, the simpler solution is opted for.

Also, the message shown in the vignette user_guide.Rmd has been removed from README.Rmd, as it should not appear in the output of the README.
It does not seem to rely on web resources, after all; it only tests how it modifies the environment.
Though it may not be used since the package is currently archived. Unclear.
@bangtranl bangtranl merged commit c86fe7c into main Aug 26, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants