From e0456c6e3b33fe0e999f6296dc7d9c120a00007e Mon Sep 17 00:00:00 2001 From: Alex Rossell Hayes <44556601+rossellhayes@users.noreply.github.com> Date: Wed, 15 Mar 2023 19:13:54 -0700 Subject: [PATCH] Release learnr 0.11.3 (#769) Co-authored-by: Garrick Aden-Buie --- DESCRIPTION | 4 ++- NEWS.md | 6 ++-- cran-comments.md | 9 ++++- package.json | 6 ++-- revdep/README.md | 77 +++++++++++++++++++++++++++++++++-------- revdep/cran.md | 7 ++++ vignettes/multilang.Rmd | 10 +++--- 7 files changed, 92 insertions(+), 27 deletions(-) create mode 100644 revdep/cran.md diff --git a/DESCRIPTION b/DESCRIPTION index c8fa9184b..aa16ff6bd 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,7 +1,7 @@ Type: Package Package: learnr Title: Interactive Tutorials for R -Version: 0.11.2.9000 +Version: 0.11.3 Authors@R: c( person("Garrick", "Aden-Buie", , "garrick@posit.co", role = c("aut", "cre"), comment = c(ORCID = "0000-0002-7111-0077")), @@ -56,6 +56,7 @@ Imports: utils, withr Suggests: + bslib, callr, DBI (>= 0.4-1), httpuv, @@ -64,6 +65,7 @@ Suggests: RSQLite, rstudioapi (>= 0.11), shinytest2, + sortable, testthat (>= 3.0.3) VignetteBuilder: knitr diff --git a/NEWS.md b/NEWS.md index 5f3882ef4..08b268a5d 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,10 +1,10 @@ -# learnr (development version) +# learnr 0.11.3 - Fixed an issue that prevented authors from using symbols, such as `T` or a variable, as the value of the `exercise` chunk option, which caused tutorials with chunks with `exercise = T` to fail to render (thanks @cknotz #757, #758). - The embedded Ace editor used in learnr exercises now defaults to a tab width of 2, aligning with the Tidyverse style guide (#761). -- Add a fallback to generate a comprehensible English feedback message for code that fails to parse because it contains non-ASCII characters. Previously, if i18next was unavailable, the feedback would contain uninterpolated i18next markup. Now the feedback is pre-interpolated so students will always see a comprehensible message (#765). +- learnr now pre-renders (in English) the feedback message it provides when non-ASCII characters are included in submitted unparsable R code. This makes the feedback useful even if learnr's in-browser translations aren't available (#765). # learnr 0.11.2 @@ -187,7 +187,7 @@ This is a maintenance release that adjusts an example and several tests for CRAN - Many of the HTML dependencies used by learnr have been updated to more recent versions (#655). learnr now uses: - [Ace](https://ace.c9.io/) version [1.10.1](https://github.com/ajaxorg/ace/blob/ff3dd698/CHANGELOG.md) - [clipboard.js](https://clipboardjs.com/) version [2.0.10](https://github.com/zenorocha/clipboard.js/releases) - - [Bootbox](http://bootboxjs.com/) version [5.5.2](https://github.com/makeusabrew/bootbox/blob/master/CHANGELOG.md) + - [Bootbox](https://bootboxjs.com/) version [5.5.2](https://github.com/bootboxjs/bootbox/blob/HEAD/CHANGELOG.md) - [i18next](https://www.i18next.com/) version [21.6.10](https://github.com/i18next/i18next/blob/master/CHANGELOG.md) - learnr’s knitr hooks are now set by the `learnr::tutorial` R Markdown format. They are also registered for any tutorials run by `run_tutorial()` (thanks @czucca #598, #599). diff --git a/cran-comments.md b/cran-comments.md index 75cd1c64b..085302edd 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,5 +1,12 @@ +This is a patch release containing a few small bug fixes and minor features. + ## R CMD check results 0 errors | 0 warnings | 0 notes -This is a maintenance release to fix a failing test in non-UTF-8 compatible environments. +## revdepcheck results + +We checked 14 reverse dependencies (13 from CRAN + 1 from Bioconductor), comparing R CMD check results across CRAN and dev versions of this package. + + * We saw 0 new problems + * We failed to check 0 packages diff --git a/package.json b/package.json index 44fbf8e75..2e53632ae 100644 --- a/package.json +++ b/package.json @@ -9,9 +9,9 @@ "build:esbuild": "node learnr-js/build.js", "lint": "standard --fix learnr-js", "copy": "npm run copy:clipboard && npm run copy:bootbox && npm run copy:i18next", - "copy:clipboard": "cpy 'node_modules/clipboard/dist/clipboard.min.js' inst/lib/clipboardjs", - "copy:bootbox": "cpy 'node_modules/bootbox/dist/bootbox.min.js' inst/lib/bootbox", - "copy:i18next": "cpy 'node_modules/i18next/i18next.min.js' inst/lib/i18next" + "copy:clipboard": "cpy 'clipboard.min.js' ../../../inst/lib/clipboardjs --cwd node_modules/clipboard/dist/", + "copy:bootbox": "cpy 'bootbox.min.js' ../../../inst/lib/bootbox --cwd node_modules/bootbox/dist/", + "copy:i18next": "cpy 'i18next.min.js' ../../inst/lib/i18next --cwd node_modules/i18next/" }, "devDependencies": { "@babel/cli": "^7.16.8", diff --git a/revdep/README.md b/revdep/README.md index 2d7b635d9..12037c1a6 100644 --- a/revdep/README.md +++ b/revdep/README.md @@ -1,22 +1,71 @@ # Platform -|field |value | -|:--------|:----------------------------| -|version |R version 3.6.1 (2019-07-05) | -|os |macOS Catalina 10.15.2 | -|system |x86_64, darwin15.6.0 | -|ui |X11 | -|language |(EN) | -|collate |en_US.UTF-8 | -|ctype |en_US.UTF-8 | -|tz |America/New_York | -|date |2020-02-12 | +|field |value | +|:--------|:------------------------------| +|version |R version 4.2.2 (2022-10-31) | +|os |macOS Ventura 13.2 | +|system |aarch64, darwin20 | +|ui |X11 | +|language |(EN) | +|collate |en_US.UTF-8 | +|ctype |en_US.UTF-8 | +|tz |America/New_York | +|date |2023-03-14 | +|pandoc |3.1 @ /opt/homebrew/bin/pandoc | # Dependencies -|package |old |new |Δ | -|:-------|:------|:------|:--| -|learnr |0.10.0 |0.10.1 |* | +|package |old |new |Δ | +|:-----------|:---------|:---------|:--| +|learnr |0.11.2 |0.11.3 |* | +|backports |1.4.1 |1.4.1 | | +|base64enc |0.1-3 |0.1-3 | | +|bslib |0.4.2 |0.4.2 | | +|cachem |1.0.7 |1.0.7 | | +|checkmate |2.1.0 |2.1.0 | | +|cli |3.6.0 |3.6.0 | | +|commonmark |1.8.1 |1.8.1 | | +|crayon |1.5.2 |1.5.2 | | +|curl |5.0.0 |5.0.0 | | +|digest |0.6.31 |0.6.31 | | +|ellipsis |0.3.2 |0.3.2 | | +|evaluate |0.20 |0.20 | | +|fastmap |1.1.1 |1.1.1 | | +|fontawesome |0.5.0 |0.5.0 | | +|fs |1.6.1 |1.6.1 | | +|glue |1.6.2 |1.6.2 | | +|highr |0.10 |0.10 | | +|htmltools |0.5.4 |0.5.4 | | +|htmlwidgets |1.6.1 |1.6.1 | | +|httpuv |1.6.9 |1.6.9 | | +|jquerylib |0.1.4 |0.1.4 | | +|jsonlite |1.8.4 |1.8.4 | | +|knitr |1.42 |1.42 | | +|later |1.3.0 |1.3.0 | | +|lifecycle |1.0.3 |1.0.3 | | +|magrittr |2.0.3 |2.0.3 | | +|markdown |1.5 |1.5 | | +|memoise |2.0.1 |2.0.1 | | +|mime |0.12 |0.12 | | +|promises |1.2.0.1 |1.2.0.1 | | +|R6 |2.5.1 |2.5.1 | | +|rappdirs |0.3.3 |0.3.3 | | +|Rcpp |1.0.10 |1.0.10 | | +|renv |0.17.0-40 |0.17.0-49 |* | +|rlang |1.0.6 |1.0.6 | | +|rmarkdown |2.20 |2.20 | | +|rprojroot |2.0.3 |2.0.3 | | +|sass |0.4.5 |0.4.5 | | +|shiny |1.7.4 |1.7.4 | | +|sourcetools |0.1.7-1 |0.1.7-1 | | +|stringi |1.7.12 |1.7.12 | | +|stringr |1.5.0 |1.5.0 | | +|tinytex |0.44 |0.44 | | +|vctrs |0.5.2 |0.5.2 | | +|withr |2.5.0 |2.5.0 | | +|xfun |0.37 |0.37 | | +|xtable |1.8-4 |1.8-4 | | +|yaml |2.3.7 |2.3.7 | | # Revdeps diff --git a/revdep/cran.md b/revdep/cran.md new file mode 100644 index 000000000..87c263002 --- /dev/null +++ b/revdep/cran.md @@ -0,0 +1,7 @@ +## revdepcheck results + +We checked 14 reverse dependencies (13 from CRAN + 1 from Bioconductor), comparing R CMD check results across CRAN and dev versions of this package. + + * We saw 0 new problems + * We failed to check 0 packages + diff --git a/vignettes/multilang.Rmd b/vignettes/multilang.Rmd index 287050550..91bc19824 100644 --- a/vignettes/multilang.Rmd +++ b/vignettes/multilang.Rmd @@ -20,9 +20,9 @@ knitr::opts_chunk$set( ## Language codes and names borrowed from BootBox # library(rvest) -# read_html("http://bootboxjs.com/documentation.html#bb-locales") %>% -# html_table() %>% -# .[[6]] %>% +# read_html("https://bootboxjs.com/v5.x/documentation.html") %>% +# html_table() %>% +# .[[6]] %>% # {dplyr::bind_rows(.[, 1:2], .[, 3:4])} languages <- c("Arabic","Bulgarian","Czech", @@ -65,7 +65,7 @@ bb_langs_code <- paste0("`", names(languages), "`") To change the language of the UI element, you can use the following parameter in your YAML: - output: + output: learnr::tutorial: language: fr @@ -209,7 +209,7 @@ language: custom_language.json Complete translations are provided by the internal function `i18n_translations()`. To contribute a complete translation for a language not currently provided by learnr, please submit a pull request to [github.com/rstudio/learnr](https://github.com/rstudio/learnr) updating the list in `data-raw/i18n_translations.yml`, following the format described in that file. -Note that for the language to be available inside the alert boxes of learnr, you'll need to set the language to one of the [language codes used by bootbox](http://bootboxjs.com/documentation.html#bb-locales)[^1]. +Note that for the language to be available inside the alert boxes of learnr, you'll need to set the language to one of the [language codes used by bootbox](https://bootboxjs.com/v5.x/documentation.html)[^1]. If your language is not available for `bootbox`, then the buttons will default to English. [^1]: `r knitr::combine_words(bb_langs_code, and = " or ")`