From 0e20356c7f0b482f80aa660a128fba4be8417a6d Mon Sep 17 00:00:00 2001 From: Pawel Rucki <12943682+pawelru@users.noreply.github.com> Date: Thu, 1 Feb 2024 15:05:18 +0100 Subject: [PATCH 1/3] register teal.logger handlers; replace few loggers with base --- .pre-commit-config.yaml | 1 - DESCRIPTION | 3 +-- R/tm_g_gh_boxplot.R | 2 +- R/tm_g_gh_correlationplot.R | 2 +- R/tm_g_gh_density_distribution_plot.R | 2 +- R/tm_g_gh_lineplot.R | 2 +- R/tm_g_gh_scatterplot.R | 2 +- R/tm_g_gh_spaghettiplot.R | 2 +- R/zzz.R | 1 + 9 files changed, 8 insertions(+), 9 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 9ff0944a..56a381c2 100755 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -22,7 +22,6 @@ repos: - glue - grDevices - lifecycle - - logger - magrittr - methods - bioc::MultiAssayExperiment diff --git a/DESCRIPTION b/DESCRIPTION index 6e513200..a2045f92 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -39,14 +39,13 @@ Imports: ggplot2, grDevices, lifecycle, - logger (>= 0.2.0), methods, rlang, shinyjs, shinyvalidate, stats, teal.code (>= 0.4.1.9009), - teal.logger (>= 0.1.1), + teal.logger (>= 0.1.3.9010), teal.reporter (>= 0.2.0), teal.widgets (>= 0.4.0), tidyr diff --git a/R/tm_g_gh_boxplot.R b/R/tm_g_gh_boxplot.R index 24d8e6d4..bc7e76b0 100644 --- a/R/tm_g_gh_boxplot.R +++ b/R/tm_g_gh_boxplot.R @@ -169,7 +169,7 @@ tm_g_gh_boxplot <- function(label, alpha = c(0.8, 0.0, 1.0), pre_output = NULL, post_output = NULL) { - logger::log_info("Initializing tm_g_gh_boxplot") + message("Initializing tm_g_gh_boxplot") checkmate::assert_string(label) checkmate::assert_string(dataname) checkmate::assert_string(param_var) diff --git a/R/tm_g_gh_correlationplot.R b/R/tm_g_gh_correlationplot.R index 3697abb1..a37ff74f 100644 --- a/R/tm_g_gh_correlationplot.R +++ b/R/tm_g_gh_correlationplot.R @@ -219,7 +219,7 @@ tm_g_gh_correlationplot <- function(label, reg_text_size = c(3, 3, 10), pre_output = NULL, post_output = NULL) { - logger::log_info("Initializing tm_g_gh_correlationplot") + message("Initializing tm_g_gh_correlationplot") checkmate::assert_class(xaxis_param, "choices_selected") checkmate::assert_class(yaxis_param, "choices_selected") checkmate::assert_class(xaxis_var, "choices_selected") diff --git a/R/tm_g_gh_density_distribution_plot.R b/R/tm_g_gh_density_distribution_plot.R index 424e801f..dcba2e48 100644 --- a/R/tm_g_gh_density_distribution_plot.R +++ b/R/tm_g_gh_density_distribution_plot.R @@ -131,7 +131,7 @@ tm_g_gh_density_distribution_plot <- function(label, # nolint rotate_xlab = FALSE, pre_output = NULL, post_output = NULL) { - logger::log_info("Initializing tm_g_gh_density_distribution_plot") + message("Initializing tm_g_gh_density_distribution_plot") checkmate::assert_string(label) checkmate::assert_string(dataname) checkmate::assert_string(param_var) diff --git a/R/tm_g_gh_lineplot.R b/R/tm_g_gh_lineplot.R index 64717ec5..ea67bd25 100644 --- a/R/tm_g_gh_lineplot.R +++ b/R/tm_g_gh_lineplot.R @@ -157,7 +157,7 @@ tm_g_gh_lineplot <- function(label, count_threshold = 0, table_font_size = c(12, 4, 20), plot_relative_height_value = 1000) { - logger::log_info("Initializing tm_g_gh_lineplot") + message("Initializing tm_g_gh_lineplot") checkmate::assert_class(param, "choices_selected") checkmate::assert_class(xaxis_var, "choices_selected") checkmate::assert_class(yaxis_var, "choices_selected") diff --git a/R/tm_g_gh_scatterplot.R b/R/tm_g_gh_scatterplot.R index 3d38120f..ac4b72dc 100644 --- a/R/tm_g_gh_scatterplot.R +++ b/R/tm_g_gh_scatterplot.R @@ -145,7 +145,7 @@ tm_g_gh_scatterplot <- function(label, details = "You should use teal.goshawk::tm_g_gh_correlationplot instead of teal.goshawk::tm_g_gh_scatterplot" ) - logger::log_info("Initializing tm_g_gh_scatterplot") + message("Initializing tm_g_gh_scatterplot") checkmate::assert_class(param, "choices_selected") checkmate::assert_class(xaxis_var, "choices_selected") checkmate::assert_class(yaxis_var, "choices_selected") diff --git a/R/tm_g_gh_spaghettiplot.R b/R/tm_g_gh_spaghettiplot.R index 6458fb0b..06c47af9 100644 --- a/R/tm_g_gh_spaghettiplot.R +++ b/R/tm_g_gh_spaghettiplot.R @@ -186,7 +186,7 @@ tm_g_gh_spaghettiplot <- function(label, hline_vars_labels = hline_vars, pre_output = NULL, post_output = NULL) { - logger::log_info("Initializing tm_g_gh_spaghettiplot") + message("Initializing tm_g_gh_spaghettiplot") checkmate::assert_class(param, "choices_selected") checkmate::assert_class(xaxis_var, "choices_selected") checkmate::assert_class(yaxis_var, "choices_selected") diff --git a/R/zzz.R b/R/zzz.R index 5e5f1b6e..e225bcae 100644 --- a/R/zzz.R +++ b/R/zzz.R @@ -1,3 +1,4 @@ .onLoad <- function(libname, pkgname) { # nolint teal.logger::register_logger(namespace = "teal.goshawk") + teal.logger::register_handlers("teal.goshawk") } From bdc4d5df7e4a1136177602d110b32802fa5d8617 Mon Sep 17 00:00:00 2001 From: Pawel Rucki <12943682+pawelru@users.noreply.github.com> Date: Mon, 11 Mar 2024 15:03:47 +0100 Subject: [PATCH 2/3] Update DESCRIPTION Signed-off-by: Pawel Rucki <12943682+pawelru@users.noreply.github.com> --- DESCRIPTION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DESCRIPTION b/DESCRIPTION index a2045f92..1cc27a06 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -45,7 +45,7 @@ Imports: shinyvalidate, stats, teal.code (>= 0.4.1.9009), - teal.logger (>= 0.1.3.9010), + teal.logger (>= 0.1.3.9011), teal.reporter (>= 0.2.0), teal.widgets (>= 0.4.0), tidyr From 76b9f4650c6c775c0029b10d027236c5ccb65ae1 Mon Sep 17 00:00:00 2001 From: Pawel Rucki <12943682+pawelru@users.noreply.github.com> Date: Wed, 20 Mar 2024 15:14:20 +0100 Subject: [PATCH 3/3] Update DESCRIPTION Signed-off-by: Pawel Rucki <12943682+pawelru@users.noreply.github.com> --- DESCRIPTION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DESCRIPTION b/DESCRIPTION index 766caac9..0911106e 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -48,7 +48,7 @@ Imports: shinyvalidate, stats, teal.code (>= 0.4.1.9009), - teal.logger (>= 0.1.3.9011), + teal.logger (>= 0.1.3.9013), teal.reporter (>= 0.2.0), teal.widgets (>= 0.4.0), tidyr