diff --git a/DESCRIPTION b/DESCRIPTION index 56ef935f5..a95e98318 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -118,5 +118,5 @@ Collate: 'zzz.R' Config/rextendr/version: 0.3.1 VignetteBuilder: knitr -Config/polars/LibVersion: 0.39.0 -Config/polars/RustToolchainVersion: nightly-2024-03-28 +Config/polars/LibVersion: 0.39.1 +Config/polars/RustToolchainVersion: nightly-2024-04-15 diff --git a/R/expr__array.R b/R/expr__array.R index 7c36f4778..35d5ffaca 100644 --- a/R/expr__array.R +++ b/R/expr__array.R @@ -18,15 +18,13 @@ ExprArr_sum = function() .pr$Expr$arr_sum(self) #' @return Expr #' @inherit ExprStr_to_titlecase details #' @aliases arr_max -#' @examplesIf polars_info()$features$nightly +#' @examples #' df = pl$DataFrame( #' values = list(c(1, 2), c(3, 4), c(5, 6)), #' schema = list(values = pl$Array(pl$Float64, 2)) #' ) #' df$with_columns(max = pl$col("values")$arr$max()) ExprArr_max = function() { - check_feature("nightly", "in $arr$max():") - .pr$Expr$arr_max(self) } @@ -38,15 +36,13 @@ ExprArr_max = function() { #' @inherit ExprStr_to_titlecase details #' @return Expr #' @aliases arr_min -#' @examplesIf polars_info()$features$nightly +#' @examples #' df = pl$DataFrame( #' values = list(c(1, 2), c(3, 4), c(5, 6)), #' schema = list(values = pl$Array(pl$Float64, 2)) #' ) #' df$with_columns(min = pl$col("values")$arr$min()) ExprArr_min = function() { - check_feature("nightly", "in $arr$min():") - .pr$Expr$arr_min(self) } diff --git a/src/rust/Cargo.lock b/src/rust/Cargo.lock index 7a27f782f..85f787bf4 100644 --- a/src/rust/Cargo.lock +++ b/src/rust/Cargo.lock @@ -1354,8 +1354,8 @@ dependencies = [ [[package]] name = "polars" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "getrandom", "polars-arrow", @@ -1374,8 +1374,8 @@ dependencies = [ [[package]] name = "polars-arrow" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "ahash", "atoi", @@ -1421,8 +1421,8 @@ dependencies = [ [[package]] name = "polars-compute" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "bytemuck", "either", @@ -1436,8 +1436,8 @@ dependencies = [ [[package]] name = "polars-core" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "ahash", "bitflags 2.4.2", @@ -1470,8 +1470,8 @@ dependencies = [ [[package]] name = "polars-error" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "avro-schema", "polars-arrow-format", @@ -1482,8 +1482,8 @@ dependencies = [ [[package]] name = "polars-io" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "ahash", "async-trait", @@ -1523,8 +1523,8 @@ dependencies = [ [[package]] name = "polars-json" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "ahash", "chrono", @@ -1543,8 +1543,8 @@ dependencies = [ [[package]] name = "polars-lazy" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "ahash", "bitflags 2.4.2", @@ -1566,8 +1566,8 @@ dependencies = [ [[package]] name = "polars-ops" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "ahash", "aho-corasick", @@ -1602,8 +1602,8 @@ dependencies = [ [[package]] name = "polars-parquet" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "ahash", "async-stream", @@ -1627,8 +1627,8 @@ dependencies = [ [[package]] name = "polars-pipe" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "crossbeam-channel", "crossbeam-queue", @@ -1651,8 +1651,8 @@ dependencies = [ [[package]] name = "polars-plan" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "ahash", "bytemuck", @@ -1680,8 +1680,8 @@ dependencies = [ [[package]] name = "polars-row" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "bytemuck", "polars-arrow", @@ -1691,8 +1691,8 @@ dependencies = [ [[package]] name = "polars-sql" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "hex", "polars-arrow", @@ -1708,8 +1708,8 @@ dependencies = [ [[package]] name = "polars-time" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "atoi", "chrono", @@ -1728,8 +1728,8 @@ dependencies = [ [[package]] name = "polars-utils" -version = "0.39.0" -source = "git+https://github.com/pola-rs/polars.git?rev=37c630320da0d0d3270d283cdafbf6b8402de069#37c630320da0d0d3270d283cdafbf6b8402de069" +version = "0.39.1" +source = "git+https://github.com/pola-rs/polars.git?rev=5e6854171b4883418c9dbc5dd20f1bb10a23f98f#5e6854171b4883418c9dbc5dd20f1bb10a23f98f" dependencies = [ "ahash", "bytemuck", @@ -1781,7 +1781,7 @@ dependencies = [ [[package]] name = "r-polars" -version = "0.39.0" +version = "0.39.1" dependencies = [ "either", "extendr-api", diff --git a/src/rust/Cargo.toml b/src/rust/Cargo.toml index b9bcd0d39..8d16b5f14 100644 --- a/src/rust/Cargo.toml +++ b/src/rust/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "r-polars" -version = "0.39.0" +version = "0.39.1" edition = "2021" rust-version = "1.76.0" publish = false @@ -52,8 +52,8 @@ serde_json = "*" smartstring = "1.0.1" state = "0.6.0" thiserror = "1.0.58" -polars-core = { git = "https://github.com/pola-rs/polars.git", rev = "37c630320da0d0d3270d283cdafbf6b8402de069", default-features = false } -polars-lazy = { git = "https://github.com/pola-rs/polars.git", rev = "37c630320da0d0d3270d283cdafbf6b8402de069", default-features = false } +polars-core = { git = "https://github.com/pola-rs/polars.git", rev = "5e6854171b4883418c9dbc5dd20f1bb10a23f98f", default-features = false } +polars-lazy = { git = "https://github.com/pola-rs/polars.git", rev = "5e6854171b4883418c9dbc5dd20f1bb10a23f98f", default-features = false } either = "1" #features copied from node-polars @@ -93,6 +93,7 @@ features = [ "extract_groups", "extract_jsonpath", "ewma", + "ewma_by", "find_many", "fmt", "interpolate", @@ -154,4 +155,4 @@ features = [ "zip_with", ] git = "https://github.com/pola-rs/polars.git" -rev = "37c630320da0d0d3270d283cdafbf6b8402de069" +rev = "5e6854171b4883418c9dbc5dd20f1bb10a23f98f" diff --git a/tests/testthat/test-expr_array.R b/tests/testthat/test-expr_array.R index 1600561a7..513a0e253 100644 --- a/tests/testthat/test-expr_array.R +++ b/tests/testthat/test-expr_array.R @@ -17,42 +17,8 @@ test_that("arr$sum", { ) }) -# TODO: reenable if the upstream issue is fixed -# test_that("arr$max and arr$min", { -# skip_if_not(polars_info()$features$nightly) - -# df = pl$DataFrame( -# ints = list(1:2, c(1L, NA_integer_), c(NA_integer_, NA_integer_)), -# floats = list(c(1, 2), c(1, NA_real_), c(NA_real_, NA_real_)), -# schema = list( -# ints = pl$Array(pl$Int32, 2), -# floats = pl$Array(pl$Float32, 2) -# ) -# ) -# # max --- -# expect_identical( -# df$select(pl$col("ints")$arr$max())$to_list(), -# list(ints = c(2L, 1L, NA_integer_)) -# ) -# expect_identical( -# df$select(pl$col("floats")$arr$max())$to_list(), -# list(floats = c(2, 1, NA_real_)) -# ) - -# # min --- -# expect_identical( -# df$select(pl$col("ints")$arr$min())$to_list(), -# list(ints = c(1L, 1L, NA_integer_)) -# ) -# expect_identical( -# df$select(pl$col("floats")$arr$min())$to_list(), -# list(floats = c(1, 1, NA_real_)) -# ) -# }) - -test_that("arr$max and arr$min error if the nightly feature is false", { - skip_if(polars_info()$features$nightly) +test_that("arr$max and arr$min", { df = pl$DataFrame( ints = list(1:2, c(1L, NA_integer_), c(NA_integer_, NA_integer_)), floats = list(c(1, 2), c(1, NA_real_), c(NA_real_, NA_real_)), @@ -62,13 +28,23 @@ test_that("arr$max and arr$min error if the nightly feature is false", { ) ) # max --- - expect_grepl_error( - df$select(pl$col("ints")$arr$max())$to_list() + expect_identical( + df$select(pl$col("ints")$arr$max())$to_list(), + list(ints = c(2L, 1L, NA_integer_)) + ) + expect_identical( + df$select(pl$col("floats")$arr$max())$to_list(), + list(floats = c(2, 1, NA_real_)) ) # min --- - expect_grepl_error( - df$select(pl$col("ints")$arr$min())$to_list() + expect_identical( + df$select(pl$col("ints")$arr$min())$to_list(), + list(ints = c(1L, 1L, NA_integer_)) + ) + expect_identical( + df$select(pl$col("floats")$arr$min())$to_list(), + list(floats = c(1, 1, NA_real_)) ) }) diff --git a/tools/lib-sums.tsv b/tools/lib-sums.tsv deleted file mode 100644 index cb69a0822..000000000 --- a/tools/lib-sums.tsv +++ /dev/null @@ -1,6 +0,0 @@ -url sha256sum -https://github.com/pola-rs/r-polars/releases/download/lib-v0.39.0/libr_polars-0.39.0-aarch64-apple-darwin.tar.gz 43568dcce4a819c191ea27ec5db6559ccbe12df6edf8359a4299f0c25a8885bc -https://github.com/pola-rs/r-polars/releases/download/lib-v0.39.0/libr_polars-0.39.0-aarch64-unknown-linux-gnu.tar.gz 5e443a902b1a982534e6c42fd3898ef8095cebe05d577286648d6ce63b3adc30 -https://github.com/pola-rs/r-polars/releases/download/lib-v0.39.0/libr_polars-0.39.0-x86_64-apple-darwin.tar.gz 2b1d3b2b981ffedcb2781778105ca6d013b6382555eb53d0a476ed4b721aff42 -https://github.com/pola-rs/r-polars/releases/download/lib-v0.39.0/libr_polars-0.39.0-x86_64-pc-windows-gnu.tar.gz f3f21c17617f5e5688d04c843069a40998cf2fdc34dfa17cc18a171b003fe2b0 -https://github.com/pola-rs/r-polars/releases/download/lib-v0.39.0/libr_polars-0.39.0-x86_64-unknown-linux-gnu.tar.gz 2b3c1a8257f348a8fe28e30a2c7438ef01faf8ce87f2217748d0d12b696a6034