-
Notifications
You must be signed in to change notification settings - Fork 0
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
Get Package info #6
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## feat/1-export-manifests #6 +/- ##
============================================================
+ Coverage 76.05% 86.41% +10.36%
============================================================
Files 2 4 +2
Lines 71 162 +91
============================================================
+ Hits 54 140 +86
- Misses 17 22 +5 ☔ View full report in Codecov by Sentry. |
I just reviewed |
Now accepts a single list/vector and returns a nested list
warning only emitted if package loaded with pkgload, which does not happen with R CMD CHECK
this interferes with CI systems that may install the package multiple times
@cjyetman, @jdhoffa Made a number of changes since last review, but I think the big thing that's still missing on this block is the git info for local/dev packages, and I haven't written any of that yet, so I'd like to get this merged into the bigger tracking branch. structural changes since last review:
|
NIT: Should we be more specific about what we mean by Here it is defined as something different from what is idiosyncratic in R. Here, however, Should we rename the flag as (I don't mean to start a whole big discussion on what "dev version" should mean, just flagging that it may be confusing to users, or even to us down the road, as to what we are referring to when we use that term) devtools::load_all("/Users/jdhoffa/github/pacta.workflow.utils")
#> ℹ Loading pacta.workflow.utils
out <- pacta.workflow.utils:::get_package_info(
packagelist = c(
"pacta.workflow.utils",
"r2dii.data",
"dplyr"
)
)
#> Warning in get_individual_package_info(x): Identifying development packages may
#> not be accurate.
#> Warning in get_individual_package_info(x): Multiple installations of package
#> found.
#> Warning in get_individual_package_info(x): Multiple installations of package
#> found.
out$pacta.workflow.utils$version
#> [1] "DEV 0.0.0.9002"
out$pacta.workflow.utils$dev_version
#> [1] TRUE
out$r2dii.data$version
#> [1] "0.4.1.9000"
out$r2dii.data$dev_version
#> [1] FALSE
out$dplyr$version
#> [1] "1.1.4"
out$dplyr$dev_version
#> [1] FALSE Created on 2024-03-26 with reprex v2.1.0 |
@jdhoffa if we renamed it to something like I'd stay away from |
Yeah that's exactly my point actually! I think |
@jdhoffa easy change. done. I think I like this clarity better. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That was my only comment, this looks absolutely awesome man seriously!
Thank you
Leave it to @cjyetman who may have more useful feedback as he engages with the manifest
outputs more frequently.
get_r_session_info <- function() { | ||
return( | ||
list( | ||
R.version = utils::sessionInfo()[["R.version"]], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$R.version$nickname
[1] "Eye Holes"
🤣
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LOL
logger::log_threshold(logger::FATAL) | ||
logger::log_layout(logger::layout_simple) | ||
|
||
test_that("get_single_file_metadata processes CSV tables correctly", { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
seems like this test name/message is out of sync with reality
This PR is a checkpoint PR, and should be considered as part of a larger work in progress, mostly containing the get_package_info and related functions.
I'm opening this as a targeted PR, so that this bit can be evaluated in isolation, since the tests for this section can get kind of gnarly.
Requests to reviewers:
Note that a lot of the "weirdness" in the tests (making use of a lot of
expect_match
vsexpect_identical
, or the heavy use of for example) is related to either having the tests run on the CI machines, or run on Windows, or because I don't actually want to break.liPaths()
on my local machine 😆