You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Okay, let's analyze your package files to see if they're ready for CRAN. I will focus on the items that are commonly checked by CRAN.
General Observations:
Functionality: The package seems to do what it says and it provides 2 main functions get_bible_verse and find_bible_verse.
Testing: You've included test files using the testthat framework, which is great. They include mock responses.
Documentation: You have a README.md, which is good.
Specific Issues:
README.md:
Install Instructions:
You have two installation instructions: from GitHub and from CRAN. When submitting, you should adjust your README to focus mainly on installing from CRAN since this will be your main way of installing once the package is accepted in CRAN. You could keep the GitHub installation for development purposes, but make CRAN the primary one.
The CRAN install instruction is in a code chunk, but it doesn't need to be: install.packages("biblegatewayr") is enough.
Examples:
The examples should avoid cat(), but rather print the output normally since cat adds extra output in the console and make the examples to be more difficult to read.
The examples in the Readme could be more concise. The output should be hidden, this is not really required, since the tests already checks for the expected behaviour.
You could add more versions to test, for example, English versions.
You have an example using NTV, that should be placed in \donttest{} since there are some locale considerations to take in to account.
Main Components:
This section is good to have, but could be more concise, there is no need to point to the help documentation, since it's assumed that the users will explore it with ?.
DESCRIPTION File:
Title:"Access Bible Verses from BibleGateway" is descriptive and uses title case, which is good.
Description: The description is well-written. I suggest adding software and package names in single quotes, e.g., 'get_bible_verse', 'find_bible_verse'.
Authors@R:
Good job using person(), including roles (aut, cre, cph) and ORCID.
License: You've correctly declared MIT + file LICENSE.
Imports: You've correctly declared packages such as httr2 and rvest.
URL: You have a secondary URL to your package website, this is great.
BugReports: You have a link to the issues page in GitHub, that's great.
R Code Files (find_bible_verse.R and get_bible_verse.R)
Roxygen Comments:
You used @examplesIf interactive(), that's good, but keep in mind that this can lead to inconsistencies when building the package documentation in different environments.
You are missing @returns in both functions.
You have correctly documented all the parameters with @param.
Function Logic:
Both functions use httr2 and rvest correctly, performing HTTP requests and parsing HTML content.
You have a good error management strategy using tryCatch.
In general, the functions have very good formatting and good comments.
In get_bible_verse function, the logic to split and format the output is quite complex, that could lead to unexpected behaviours, consider to simplify this.
test Files:
You have successfully implemented tests in a separate directory.
You're using httr2::with_mocked_responses to mock responses, which is best practice.
The tests are comprehensive, testing for success, failure and error scenarios.
Test are well structured and with good organization.
Recommendations Before CRAN Submission:
README.md:
Revise the install instructions, prioritize CRAN installation and simplify the instructions.
Remove cat from the examples.
Hide output of examples.
Add \donttest to NTV example, or any other example that is using a non-english version.
Add English version examples.
Simplify "Main components" section.
DESCRIPTION File:
Put all software and package names in single quotes in the description section. For example, 'get_bible_verse', 'find_bible_verse'.
R Code Files
Add @returns tag for every exported function in roxygen comments.
In get_bible_verse function, try to simplify the logic used to format the text output.
Extra Checks:
Check for the noSuggests and check results using devtools::check(args = c('--no-manual', '--no-vignettes', '--no-build-vignettes')) as it could reveal hidden issues.
Check for url_check() and fix all urls if required.
Additional steps:
cran-comments.md: add this file, and specify that this is a new submission and that all the checks passed.
NEWS.md: add this file, explaining the new features and changes you did in this version.
Summary:
Your package is in very good shape for a first CRAN submission.
By addressing the points mentioned above, you will have an higher chance of being approved in the first try.
Remember to run devtools::check(remote = TRUE, manual = TRUE) and devtools::check_win_devel() before submitting.
If you have more questions or would like to review again, please do not hesitate to ask.
The text was updated successfully, but these errors were encountered:
Okay, let's analyze your package files to see if they're ready for CRAN. I will focus on the items that are commonly checked by CRAN.
General Observations:
get_bible_verse
andfind_bible_verse
.testthat
framework, which is great. They include mock responses.README.md
, which is good.Specific Issues:
README.md
:Install Instructions:
install.packages("biblegatewayr")
is enough.Examples:
cat()
, but rather print the output normally sincecat
adds extra output in the console and make the examples to be more difficult to read.NTV
, that should be placed in\donttest{}
since there are some locale considerations to take in to account.Main Components:
?
.DESCRIPTION
File:"Access Bible Verses from BibleGateway"
is descriptive and uses title case, which is good.'get_bible_verse'
,'find_bible_verse'
.person()
, including roles (aut
,cre
,cph
) and ORCID.MIT + file LICENSE
.httr2
andrvest
.testthat (>= 3.0.0)
.R
Code Files (find_bible_verse.R
andget_bible_verse.R
)@examplesIf interactive()
, that's good, but keep in mind that this can lead to inconsistencies when building the package documentation in different environments.@returns
in both functions.@param
.httr2
andrvest
correctly, performing HTTP requests and parsing HTML content.tryCatch
.get_bible_verse
function, the logic to split and format the output is quite complex, that could lead to unexpected behaviours, consider to simplify this.test
Files:httr2::with_mocked_responses
to mock responses, which is best practice.Recommendations Before CRAN Submission:
README.md
:cat
from the examples.\donttest
toNTV
example, or any other example that is using a non-english version.DESCRIPTION
File:'get_bible_verse'
,'find_bible_verse'
.R Code Files
@returns
tag for every exported function in roxygen comments.get_bible_verse
function, try to simplify the logic used to format the text output.Extra Checks:
noSuggests
and check results usingdevtools::check(args = c('--no-manual', '--no-vignettes', '--no-build-vignettes'))
as it could reveal hidden issues.url_check()
and fix all urls if required.Additional steps:
cran-comments.md
: add this file, and specify that this is a new submission and that all the checks passed.NEWS.md
: add this file, explaining the new features and changes you did in this version.Summary:
Your package is in very good shape for a first CRAN submission.
By addressing the points mentioned above, you will have an higher chance of being approved in the first try.
Remember to run
devtools::check(remote = TRUE, manual = TRUE)
anddevtools::check_win_devel()
before submitting.If you have more questions or would like to review again, please do not hesitate to ask.
The text was updated successfully, but these errors were encountered: