I'm having an issue with GeoJSON files not obeying the right hand rule. I'm not sure what goes wrong. Both geoJSON files have the problem according to https://geojsonlint.com/.
library(sf)
# Linking to GEOS 3.9.1, GDAL 3.3.2, PROJ 7.2.1
library(qgisprocess)
qgis_configure()
# Using 'qgis_process' at '/apps/bin/qgis_process'.
# QGIS version: 3.23.0-Master
qgis_run_algorithm("native:forcerhr", INPUT = "test.gpkg", OUTPUT = "test.geojson")
qgis_run_algorithm("native:forcerhr", INPUT = "test.gpkg", OUTPUT = "test2.gpkg")
st_write(read_sf("test2.gpkg"), "test2.geojson", delete_dsn = TRUE)
R version 4.1.2 (2021-11-01)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 20.04.3 LTS
Matrix products: default
BLAS: /usr/lib/x86_64-linux-gnu/blas/libblas.so.3.9.0
LAPACK: /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3.9.0
locale:
[1] LC_CTYPE=nl_BE.UTF-8 LC_NUMERIC=C LC_TIME=nl_BE.UTF-8 LC_COLLATE=nl_BE.UTF-8 LC_MONETARY=nl_BE.UTF-8
[6] LC_MESSAGES=nl_BE.UTF-8 LC_PAPER=nl_BE.UTF-8 LC_NAME=C LC_ADDRESS=C LC_TELEPHONE=C
[11] LC_MEASUREMENT=nl_BE.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats graphics grDevices datasets utils methods base
other attached packages:
[1] sessioninfo_1.2.1 qgisprocess_0.0.0.9000 sf_1.0-4
loaded via a namespace (and not attached):
[1] Rcpp_1.0.7 rstudioapi_0.13 magrittr_2.0.1 units_0.7-2 tidyselect_1.1.1 R6_2.5.1 rlang_0.4.12 fansi_0.5.0
[9] stringr_1.4.0 dplyr_1.0.7 tools_4.1.2 grid_4.1.2 KernSmooth_2.23-20 utf8_1.2.2 cli_3.1.0 e1071_1.7-9
[17] DBI_1.1.1 withr_2.4.2 fortunes_1.5-4 ellipsis_0.3.2 class_7.3-19 assertthat_0.2.1 tibble_3.1.6 lifecycle_1.0.1
[25] crayon_1.4.2 processx_3.5.2 purrr_0.3.4 ps_1.6.0 vctrs_0.3.8 glue_1.5.0 stringi_1.7.5 proxy_0.4-26
[33] compiler_4.1.2 pillar_1.6.4 generics_0.1.1 classInt_0.4-3 renv_0.14.0 pkgconfig_2.0.3
I'm having an issue with GeoJSON files not obeying the right hand rule. I'm not sure what goes wrong. Both geoJSON files have the problem according to https://geojsonlint.com/.
test.gpkg(96 kB)Session info