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: 2 additions & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,5 @@ rsconnect/
^\.commitlintrc\.yml$
^[.]?air[.]toml$
^\.vscode$
\.venv
\.husky
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,4 @@ inst/doc
*.swp
.Rproj.user
config-uat-rsc.yml
.venv/
18 changes: 0 additions & 18 deletions .gitlab-ci.yml

This file was deleted.

4 changes: 3 additions & 1 deletion .lintr
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
linters: linters_with_defaults(
assignment_linter = NULL,
line_length_linter(100),
pipe_consistency_linter = NULL,
undesirable_operator_linter(
modify_defaults(
default_undesirable_operators,
Expand All @@ -9,5 +10,6 @@ linters: linters_with_defaults(
)
)
exclusions: list(
"^cache/"
"^cache/",
"inst/extdata/render_quarto/observable/"
)
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Type: Package
Package: audit.base
Title: Base package for Posit Checks
Version: 0.6.22
Version: 0.6.23
Authors@R:
person("Jumping", "Rivers", , "info@jumpingrivers.com", role = c("aut", "cre"))
Description: Base package for sharing classes between posit audit
Expand Down Expand Up @@ -32,4 +32,4 @@ Remotes:
Config/testthat/edition: 3
Encoding: UTF-8
LazyData: true
RoxygenNote: 7.3.2
RoxygenNote: 7.3.3
3 changes: 3 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# audit.base 0.6.23 _2026-01-30_
- chore: Update quarto, requirements.txt and software versions

# audit.base 0.6.22 _2025-07-21_
- chore: Use air for formatting
- chore: Update requirements.txt for python example
Expand Down
2 changes: 1 addition & 1 deletion R/check.R
Original file line number Diff line number Diff line change
Expand Up @@ -29,5 +29,5 @@ init_r6_check = function(export, dir, file, pkg_name) {
} else {
obj = NULL
}
return(obj)
obj
}
5 changes: 1 addition & 4 deletions R/check_sys_deps.R
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,6 @@
check_sys_deps = function(os_release, installed_libs, debug_level = 0:2) {
debug_level = get_debug_level(debug_level)
cli::cli_h2("Systems Libraries")
cli::cli_alert_info(
"This may take a few minutes as we are deploying a plumber API onto Connect"
)
# Clean up response
pkg_look_up = get_os_sys_deps(os_release)

Expand All @@ -28,7 +25,7 @@ check_sys_deps = function(os_release, installed_libs, debug_level = 0:2) {
cli::cli_alert_info("Missing sys_libs: {sys_libs}")
cli::cli_alert_info("Note: this is not necessarily a bad thing")
}
return(missing_libs)
missing_libs
}

# Contents of /etc/os-release
Expand Down
5 changes: 2 additions & 3 deletions R/config.R
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,7 @@ create_config = function(file, pkg_name) {
yaml_file = file.path(dir, file)
if (type == "error" && file.exists(yaml_file)) {
cli::cli_abort(
"Config file already exists.
Either delete or change the `type` argument."
"Config file already exists. Either delete or change the `type` argument."
)
}

Expand All @@ -32,7 +31,7 @@ create_config = function(file, pkg_name) {
new_config = merge_configs(new_config, existing_config)
}
yaml::write_yaml(new_config, file = yaml_file)
return(invisible(new_config))
invisible(new_config)
}
}
create_config_list = function(dir, file, default, pkg_name) {
Expand Down
1 change: 1 addition & 0 deletions R/get_latest_versions_remote.R
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ get_latest_versions_remote = function() {
"1.4.557",
"1.5.57",
"1.6.43",
"1.7.34",
stringr::str_remove(q$name, "^v")
)

Expand Down
4 changes: 4 additions & 0 deletions R/get_pkg_requirements.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ get_pkg_requirements = function(
"{repo_id}/sysreqs?all=true&distribution={distribution}&release={release}"
) # nolint
url = glue::glue("{base_url}{config_url}")
cli::cli_alert_info(
"Connecting to {url} for system requirements"
)

res = httr::GET(url)
r = httr::content(res)

Expand Down
7 changes: 3 additions & 4 deletions R/posit_versions.R
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ get_posit_versions = function(
versions = readr::read_csv(fname, comment = "#", col_types = c("c", "c"))
}
versions = dplyr::arrange(versions, dplyr::desc(.data$version))
return(versions)
versions
}

#' Audit Posit Server
Expand Down Expand Up @@ -67,10 +67,9 @@ audit_posit_version = function(
} else {
cli::cli_alert_info("Posit {type} is up to date")
}
return(invisible(NULL))
invisible(NULL)
}


lookup_version = function(posit_version, type) {
versions = get_posit_versions(type = type)
version_as_date = version_to_date(posit_version)
Expand All @@ -92,7 +91,7 @@ lookup_version = function(posit_version, type) {
)
row_number = which(versions$version == posit_version)[1]
}
return(row_number)
row_number
}

version_to_date = function(version) {
Expand Down
4 changes: 2 additions & 2 deletions R/r6-base_check.R
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ base_check = R6::R6Class(
return(FALSE)
}
group = config[[private$group]]
return(isFALSE(group[[private$short]]))
isFALSE(group[[private$short]])
},
checker = function(check) {
self$start_logger()
Expand All @@ -77,7 +77,7 @@ base_check = R6::R6Class(
has_passed = !inherits(res, "try-error") && isTRUE(res)
}
self$stop_logger(has_passed)
return(invisible(self))
invisible(self)
}
)
)
5 changes: 2 additions & 3 deletions R/r6-logger.R
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@ logger = R6::R6Class(
)

msg_function(passed)

return(invisible(self))
invisible(self)
},
#' @description Retrieve the log
#' @return Check log
Expand All @@ -51,5 +50,5 @@ msg_function = function(has_passed) {
} else {
cli::cli_alert_danger("Check finished")
}
return(invisible(NULL))
invisible(NULL)
}
4 changes: 2 additions & 2 deletions R/software-versions.R
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ print_colour_versions = function(installed) {
row = installed[i, ]
print_colour_version(row)
}
return(invisible(NULL))
invisible(NULL)
}

print_colour_version = function(row) {
Expand All @@ -50,7 +50,7 @@ print_colour_version = function(row) {
"{software_name}: Latest version installed v{row$installed_version}"
)
}
return(invisible(NULL))
invisible(NULL)
}

# Returns X.Y from X.Y.Z
Expand Down
13 changes: 13 additions & 0 deletions inst/extdata/versions/connect.csv
Original file line number Diff line number Diff line change
@@ -1,4 +1,17 @@
version,cve
2026.01.1,
2026.01.0,
2025.12.1,
2025.12.0,
2025.11.0,
2025.10.0,
2025.09.1,
2025.09.0,CVE-2025-47906
2025.09.0,CVE-2025-47907
2025.09.0,CVE-2025-47906
2025.09.0,CVE-2025-47907
2025.07.0,CVE-2025-4674
2025.07.0,CVE-2025-4674
2025.06.0,CVE-2025-4673
2025.06.0,CVE-2025-0913
2025.06.0,CVE-2025-22874
Expand Down
4 changes: 3 additions & 1 deletion inst/extdata/versions/drivers.csv
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# https://docs.posit.co/pro-drivers/documentation/
version,cve
2026.01.0
2025.07.0
2025.03.0,
2024.03.0,
2023.12.1,
2023.05.0,
2022.11.0,
2021.10.0,

15 changes: 8 additions & 7 deletions inst/extdata/versions/software.csv
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
software,version
python,3.13.5
python,3.12.11
python,3.11.13
python,3.10.18
python,3.9.23
quarto,1.7.32
python,3.13.9
python,3.12.12
python,3.11.14
python,3.10.19
python,3.9.25
quarto,1.8.27
quarto,1.7.34
quarto,1.6.43
quarto,1.5.57
quarto,1.4.557
quarto,1.3.450
quarto,1.2.475
quarto,1.1.189
quarto,1.0.38
r,4.5.1
r,4.5.2
r,4.4.3
r,4.3.3
r,4.2.3
Expand Down
4 changes: 4 additions & 0 deletions inst/extdata/versions/workbench.csv
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
version,cve
2026.01.0,
2025.09.2,
2025.09.1,
2025.09.0,
2025.05.1,
2025.05.0,
2024.12.1,
Expand Down