paleolimbot commented on code in PR #12817:
URL: https://github.com/apache/arrow/pull/12817#discussion_r854017179
##########
r/tests/testthat/test-backwards-compatibility.R:
##########
@@ -112,10 +112,36 @@ for (comp in c("lz4", "uncompressed", "zstd")) {
# not maintained and the embedded tibble's attributes are read in a wrong
# order. Since this is prior to 1.0.0 punting on checking the attributes
# though classes are always checked, so that must be removed before
checking.
- example_with_metadata_sans_special_class <- example_with_metadata
+ example_with_metadata_sans_special_class <- old_example_with_metadata
example_with_metadata_sans_special_class$a <-
unclass(example_with_metadata_sans_special_class$a)
expect_equal(df, example_with_metadata_sans_special_class, ignore_attr =
TRUE)
})
}
+test_that("sfc columns written by arrow <= 7.0.0 can be re-read", {
+ # nolint start
+ # df <- data.frame(x = I(list(structure(1, foo = "bar"), structure(2, baz =
"qux"))))
+ # class(df$x) <- c("sfc_MULTIPOLYGON", "sfc", "list")
+ # withr::with_options(
+ # list("arrow.preserve_row_level_metadata" = TRUE), {
Review Comment:
It isn't...maybe a better name for the file would be 6.0.0? I wanted to keep
this test to make sure that if somebody had written files this way that they
could be read back in again (since it seems like that's our general policy),
but if row-level metadata was never enabled by default then maybe we don't need
this test?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]