Skip to content
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

Address cli bug in spacetime_constructor #50

Closed
wants to merge 6 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
Package: sfdep
Title: Spatial Dependence for Simple Features

Version: 0.2.4
Authors@R: c(
person("Josiah", "Parry", , "[email protected]", role = c("aut"),
comment = c(ORCID = "0000-0001-9910-865X")),
person("Dexter", "Locke", 'H', "[email protected]", role = c("aut", "cre"),
comment = c(ORCID = "0000-0003-2704-9720"))
)

Description: An interface to 'spdep' to integrate with 'sf' objects and the 'tidyverse'.
License: GPL-3
URL: https://sfdep.josiahparry.com, https://github.com/josiahparry/sfdep
Expand Down
6 changes: 5 additions & 1 deletion NEWS.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# sfdep 0.2.5

- updated spacetime_constructor to comply with updates to the cli package. No user-facing changes
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this needs to be under a new version heading since 0.2.4 is released on CRAN. This bug is not in version 0.2.4.

Can you increment the version using usethis::use_version("dev")? Then move this note under the new version heading it will make?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

usethis::use_version("dev") puts "development up top, not the numbers, so I manually put in 0.2.5. Which do you prefer?


# sfdep 0.2.4

- Dexter Locke is now the maintainer of sfdep
- Dexter Locke [@DHLocke] is now the maintainer of sfdep
- Address failing CRAN checks h/t [@rsbivand](https://github.com/rsbivand) <https://github.com/JosiahParry/sfdep/pull/43>
- Address bug in local Gi/* statistics

Expand Down
4 changes: 2 additions & 2 deletions R/spacetime-constructor.R
Original file line number Diff line number Diff line change
Expand Up @@ -176,8 +176,8 @@ validate_spacetime <- function(.data, .geometry, .loc_col, .time_col) {
if (!identical(.data_loc_class, .geo_loc_class)) {
cli::cli_abort(
c("Differing class types for {.var .loc_col}.",
i = "{.var .data}: {.cls {.data_loc_class}}",
"i" = "{.var .geometry}: {.cls {.geo_loc_class}}.")
i = "{.var .data}: {.cls {(.data_loc_class)}}",
"i" = "{.var .geometry}: {.cls {(.geo_loc_class)}}.")
)
}

Expand Down
7 changes: 2 additions & 5 deletions cran-comments.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
## R CMD check results

0 errors | 0 warnings | 0 note
Package was archived yesterday, 2023-01-09, despite efforts to address outstanding issues.

* This release removes myself (Josiah Parry) as the maintainer and makes
Dexter Locke the new maintainer of sfdep.
* CRAN has been notified of this in previous correspondence via email
* Addresses failing noSuggests checks
Latest submission failed the recursive `noSuggest` check. An example using an imported package (sf) failed because the imported function (sf::read_sf) used a suggested package (tibble suggested by sf). All instances of `sf::read_sf()` have been changed to `sf::st_read()` which, I believe, does not use any suggested packages.
Comment on lines -3 to +5
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please revert changes to reflect what is currently on the main branch.

12 changes: 12 additions & 0 deletions tests/testthat/test-spacetime-constructor_cli_update_patch.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
test_that("local_g_perm", {
df_fp <- system.file("extdata", "bos-ecometric.csv", package = "sfdep")
geo_fp <- system.file("extdata", "bos-ecometric.geojson", package = "sfdep")

# read in data
df <- read.csv(
df_fp, colClasses = c("numeric", "character", "integer", "double", "Date")
)

geo <- sf::st_read(geo_fp)
expect_error(spacetime(df, geo, ".region_id", "year"))
})
Loading