Skip to content
Merged
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: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: checked
Title: Systematically Run R CMD Checks
Version: 0.2.7
Version: 0.2.8
Authors@R:
c(
person(
Expand Down
5 changes: 5 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# checked 0.2.8

* Unify notes, warnings and errors are internally stored when generating
results (R4.5 compatibility)

# checked 0.2.7

* Fix a bug where wrong lib.loc was used to derive whether a package has already
Expand Down
24 changes: 19 additions & 5 deletions R/results.R
Original file line number Diff line number Diff line change
Expand Up @@ -98,11 +98,13 @@ results.revdep_check_task_spec <- function(x, y, output, ...) {
structure(
lapply(CHECK_ISSUES_TYPES, function(i) {
new_i <- structure(
new[[i]],
# If no issues identified, object is an empty list instead of a character
# vector. Changing it to empty character for consistency.
if (is.list(new[[i]])) character(0) else new[[i]],
names = get_issue_header(new[[i]])
)
old_i <- structure(
old[[i]],
if (is.list(old[[i]])) character(0) else old[[i]],
names = get_issue_header(old[[i]])
)

Expand Down Expand Up @@ -373,10 +375,22 @@ print.potential_issues <- function(x, ...) {
}

strip_details_from_issue <- function(x) {
x <- gsub("See(.*?)for details", "See <path> for details", "", x)
gsub("[[:space:]]", "", x)
x <- gsub(
x = x,
pattern = "See(.*?)for details",
replacement = "See <path> for details"
)
gsub(
x = x,
pattern = "[[:space:]]",
replacement = ""
)
}

collapse_new_lines <- function(x) {
gsub("(\\n\\s*){2,}", "\n\n", x)
gsub(
x = x,
pattern = "(\\n\\s*){2,}",
replacement = "\n\n",
)
}
2 changes: 1 addition & 1 deletion R/task_graph.R
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ task_graph_sort <- function(g) {

# use only strong dependencies to prioritize by topology (leafs first)
strong_edges <- igraph::E(g)[igraph::E(g)$type %in% DEP_STRONG]
g_strong <- igraph::subgraph.edges(g, strong_edges, delete.vertices = FALSE)
g_strong <- igraph::subgraph_from_edges(g, strong_edges, delete.vertices = FALSE)
topo <- igraph::topo_sort(g_strong, mode = "in")
priority_topo <- integer(length(g))
priority_topo[match(topo$name, igraph::V(g)$name)] <- rev(seq_along(topo))
Expand Down
Loading