ipeaGIT / gtfs2gps

Convert GTFS data into a data.table with GPS-like records in R
https://ipeagit.github.io/gtfs2gps/
Other
71 stars 10 forks source link

CRAN errors #227

Closed rsbivand closed 2 years ago

rsbivand commented 2 years ago

During checks against forthcomimg PROJ and GDAL new versions, the package failed: 00check.log The problem is in:

> test_check("gtfs2gps")
[ FAIL 2 | WARN 0 | SKIP 0 | PASS 186 ]

══ Failed tests ════════════════════════════════════════════════════════════════
── Failure (test_gtfs2gps.R:19:5): gtfs2gps ────────────────────────────────────
sum(poa_gps$dist) not equal to 516072.7.
Attributes: < Modes: list, NULL >
Attributes: < Lengths: 2, 0 >
Attributes: < names for target but not for current >
Attributes: < current is not list-like >
target is units, current is numeric
── Failure (test_gtfs2gps.R:63:5): gtfs2gps ────────────────────────────────────
sum(poa_gps$dist) not equal to 516072.
Attributes: < Modes: list, NULL >
Attributes: < Lengths: 2, 0 >
Attributes: < names for target but not for current >
Attributes: < current is not list-like >
target is units, current is numeric

[ FAIL 2 | WARN 0 | SKIP 0 | PASS 186 ]

I see:

> sum(poa_gps$dist)
516072.7 [m]
> all.equal(sum(poa_gps$dist), 516072.7)
[1] "Attributes: < Modes: list, NULL >"                   
[2] "Attributes: < Lengths: 2, 0 >"                       
[3] "Attributes: < names for target but not for current >"
[4] "Attributes: < current is not list-like >"            
[5] "target is units, current is numeric"                 

so the distance sum is now a units object, not a standard numeric.

pedro-andrade-inpe commented 2 years ago

@rsbivand thanks for the feedback. We are going to submit a new version in the next days.