Running examples in ‘gtfs2gps-Ex.R’ failed
The error most likely occurred in:

> ### Name: adjust_speed
> ### Title: Adjust the speeds of a gps-like table created with 'gtfs2gps'
> ### Aliases: adjust_speed
> 
> ### ** Examples
> 
> library(magrittr)
> poa <- read_gtfs(system.file("extdata/poa.zip", package="gtfs2gps")) %>%
+   gtfstools::filter_by_shape_id("T2-1") %>%
+   gtfstools::filter_by_weekday(c("monday", "wednesday")) %>%
+   filter_single_trip()
Unzipped the following files to /tmp/Rtmpe6HYEi/working_dir/Rtmpln8D25/gtfsio:
  * agency.txt
  * calendar.txt
  * routes.txt
  * shapes.txt
  * stop_times.txt
  * stops.txt
  * trips.txt
Reading agency.txt
Reading calendar.txt
Reading routes.txt
Reading shapes.txt
Reading stop_times.txt
Reading stops.txt
Reading trips.txt
> 
> poa_gps <- gtfs2gps(poa)
Converting shapes to sf objects
Using 1 CPU cores
Processing the data

Attaching package: ‘purrr’

The following object is masked from ‘package:magrittr’:

    set_names


Attaching package: ‘data.table’

The following object is masked from ‘package:purrr’:

    transpose

Linking to GEOS 3.10.2, GDAL 3.4.3, PROJ 8.2.1; sf_use_s2() is TRUE
udunits database from /usr/share/udunits/udunits2.xml
Some internal bug occurred while processing gtfs data.
Please give us a feedback by creating a GitHub issue
(https://github.com/ipeaGIT/gtfs2gps/issues/new)
and attaching a subset of your data created from the
code below:
################################################
$message
[1] "geometries - Expecting an integer vector for indexing"

$call
NULL

$cppstack

  1 : /data/gannet/ripley/R/test-clang/sfheaders/libs/sfheaders.so(Rcpp::exception::exception(char const*, bool)+0xad) [0x7f2d9a93879d]
   2 : /data/gannet/ripley/R/test-clang/sfheaders/libs/sfheaders.so(void Rcpp::stop<>(char const*)+0x48) [0x7f2d9a93dec8]
   3 : /data/gannet/ripley/R/test-clang/sfheaders/libs/sfheaders.so(sfheaders::cast::cast_sf(Rcpp::DataFrame_Impl<Rcpp::PreserveStorage>&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >&, bool)+0x626) [0x7f2d9a943266]
   4 : /data/gannet/ripley/R/test-clang/sfheaders/libs/sfheaders.so(rcpp_cast_sf(Rcpp::DataFrame_Impl<Rcpp::PreserveStorage>, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, bool)+0x15) [0x7f2d9a9425c5]
   5 : /data/gannet/ripley/R/test-clang/sfheaders/libs/sfheaders.so(_sfheaders_rcpp_cast_sf+0xec) [0x7f2d9a926e6c]
   6 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0xefc8f) [0x558a96b53c8f]
   7 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x140ae7) [0x558a96ba4ae7]
   8 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   9 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   10 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]
   11 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12dc35) [0x558a96b91c35]
   12 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   13 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   14 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]
   15 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12dc35) [0x558a96b91c35]
   16 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   17 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   18 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]
   19 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12dc35) [0x558a96b91c35]
   20 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   21 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x142478) [0x558a96ba6478]
   22 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x143103) [0x558a96ba7103]
   23 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12adf9) [0x558a96b8edf9]
   24 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   25 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x142478) [0x558a96ba6478]
   26 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x143103) [0x558a96ba7103]
   27 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12adf9) [0x558a96b8edf9]
   28 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   29 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x142478) [0x558a96ba6478]
   30 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x143103) [0x558a96ba7103]
   31 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12adf9) [0x558a96b8edf9]
   32 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   33 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x142478) [0x558a96ba6478]
   34 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x143103) [0x558a96ba7103]
   35 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12adf9) [0x558a96b8edf9]
   36 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   37 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   38 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]
   39 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12dc35) [0x558a96b91c35]
   40 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   41 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   42 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]
   43 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12dc35) [0x558a96b91c35]
   44 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   45 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   46 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]
   47 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12dc35) [0x558a96b91c35]
   48 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   49 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   50 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]
   51 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12dc35) [0x558a96b91c35]
   52 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   53 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   54 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]
   55 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x4c4) [0x558a96b8ae84]
   56 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x14bb95) [0x558a96bafb95]
   57 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x406) [0x558a96b8adc6]
   58 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x14b69b) [0x558a96baf69b]
   59 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x406) [0x558a96b8adc6]
   60 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   61 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]
   62 : /data/gannet/ripley/R/R-clang/bin/exec/R(R_forceAndCall+0x202) [0x558a96bad9d2]
   63 : /data/gannet/ripley/R/test-clang/purrr/libs/purrr.so(+0x4521) [0x7f2d9a5d3521]
   64 : /data/gannet/ripley/R/test-clang/purrr/libs/purrr.so(+0x4834) [0x7f2d9a5d3834]
   65 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0xf1353) [0x558a96b55353]
   66 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0xf1ebe) [0x558a96b55ebe]
   67 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x62a) [0x558a96b8afea]
   68 : /data/gannet/ripley/R/test-clang/purrr/libs/purrr.so(+0x28ea) [0x7f2d9a5d18ea]
   69 : /data/gannet/ripley/R/R-clang/bin/exec/R(R_ExecWithCleanup+0x1a7) [0x558a96b3b1d7]
   70 : /data/gannet/ripley/R/test-clang/purrr/libs/purrr.so(+0x2777) [0x7f2d9a5d1777]
   71 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0xee909) [0x558a96b52909]
   72 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x140ae7) [0x558a96ba4ae7]
   73 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   74 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   75 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]
   76 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12dc35) [0x558a96b91c35]
   77 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   78 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x142478) [0x558a96ba6478]
   79 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x143103) [0x558a96ba7103]
   80 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12adf9) [0x558a96b8edf9]
   81 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   82 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x142478) [0x558a96ba6478]
   83 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x143103) [0x558a96ba7103]
   84 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12adf9) [0x558a96b8edf9]
   85 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   86 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   87 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]
   88 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12dc35) [0x558a96b91c35]
   89 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   90 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   91 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]
   92 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12dc35) [0x558a96b91c35]
   93 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   94 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   95 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]
   96 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x12dc35) [0x558a96b91c35]
   97 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_eval+0x1f6) [0x558a96b8abb6]
   98 : /data/gannet/ripley/R/R-clang/bin/exec/R(+0x148fa0) [0x558a96bacfa0]
   99 : /data/gannet/ripley/R/R-clang/bin/exec/R(Rf_applyClosure+0x1ea) [0x558a96ba6d4a]

ids <- c('T2-1')
data <- gtfstools::filter_by_shape_id(poa, ids)
gtfs2gps::write_gtfs(data, 'shapes_with_error.zip')
################################################
0 out of 1 shapes (0%) were properly processed.
0 out of 1 trips (0%) were properly processed.
Error in Ops.units(output$speed, units::set_units(0, "km/h")) : 
  both operands of the expression should be "units" objects
Calls: gtfs2gps -> unique -> which -> Ops.units
Execution halted