Check that functions work with invalid Unicode strings #156
Open
Description
in particular dbQuoteString()
:
set.seed(20171108)
x <- rawToChar(as.raw(runif(100) * 255+1))
xx <- gsub("'", "''", x)
xx <- gsub("'", "''", x, fixed = TRUE, useBytes = TRUE)
xx <- gsub("'", "''", x, fixed = TRUE)
#> Error in gsub("'", "''", x, fixed = TRUE): input string 1 is invalid in this locale
(Also, results should always be in UTF-8.)
@gaborcsardi @hadley: I believe this is the reason for revdepcheck failures.
@patperry: Do you have a workaround for this in utf8?