Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integer values cannot be converted #218

Open
kadyb opened this issue Mar 17, 2024 · 1 comment
Open

Integer values cannot be converted #218

kadyb opened this issue Mar 17, 2024 · 1 comment

Comments

@kadyb
Copy link

kadyb commented Mar 17, 2024

The following error appears when converting integers. For real numbers it works ok.

library("wk")
library("sf")

p = st_sfc(st_point(c(1L, 2L)))
as_wkt(p)
#> Error in wk_handle.sfc(sf::st_sfc(handleable), handler, ...) : 
#>   REAL() can only be applied to a 'numeric', not a 'integer'
@paleolimbot
Copy link
Owner

Good catch! I didn't know this was allowed! (Or: I thought sf would have sanitized the input with as.numeric() or similar).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants