Show deprecation warning for Data Packages created with previous versions of frictionless#294
Show deprecation warning for Data Packages created with previous versions of frictionless#294peterdesmet wants to merge 6 commits intomainfrom
Conversation
Rather, create a valid package and remove the element to test
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #294 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 23 23
Lines 658 667 +9
=========================================
+ Hits 658 667 +9 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
All functions should work on older packages, that is currently not the case:
library(frictionless)
p <- movepub::o_assen
p
#> Warning: `package$directory` was deprecated in frictionless 1.3.0.
#> ℹ This Data Package was created with an older version of frictionless. Read or
#> create it again to avoid this warning.
#> ℹ The deprecated feature was likely used in the frictionless package.
#> Please report the issue at
#> <https://github.com/frictionlessdata/frictionless-r/issues>.
#> This warning is displayed once per session.
#> Call `lifecycle::last_lifecycle_warnings()` to see where this warning was
#> generated.
#> A Data Package with 2 resources:
#> • reference-data
#> • gps
#> For more information, see <https://doi.org/10.5281/zenodo.10053903>.
#> Use `unclass()` to print the Data Package as a list.
resource_names(p)
#> [1] "reference-data" "gps"
read_resource(p, "reference-data")
#> Error in `purrr::map_chr()` at frictionless-r/R/resource.R:60:7:
#> ℹ In index: 1.
#> Caused by error in `check_path()`:
#> ! Can't find file at 'O_ASSEN-reference-data.csv'.
write_package(p, "o_assen")
#> Error in `purrr::map_chr()` at frictionless-r/R/resource.R:60:7:
#> ℹ In index: 1.
#> Caused by error in `check_path()`:
#> ! Can't find file at 'O_ASSEN-reference-data.csv'.
add_resource(p, "iris", iris)
#> A Data Package with 3 resources:
#> • reference-data
#> • gps
#> • iris
#> For more information, see <https://doi.org/10.5281/zenodo.10053903>.
#> Use `unclass()` to print the Data Package as a list.
create_package(p)
#> A Data Package with 2 resources:
#> • reference-data
#> • gps
#> For more information, see <https://doi.org/10.5281/zenodo.10053903>.
#> Use `unclass()` to print the Data Package as a list.Created on 2026-04-13 with reprex v2.1.1 |
|
@sannegovaert @PietrH we have two options when a user has stored a Data Package object (e.g. as an rda) created with an older version of frictionless. Which one do you prefer? Option 1
or: Option 2
The decision also has future implications: with frictionless v2, we might want to upconvert other aspects. The question is whether this should be done by |
Fix #293.
@sannegovaert this should resolve issues you had with
river_telemetryando_assenwhile frictionless 1.2.1.9000 was loaded.You can test with: