Open cboettig opened 3 years ago
If I generate a hash like for a file and coerce it to a character, it still doesn't have class character:
character
hash <- openssl::md5(file(system.file("CITATION"))) x <- as.character(hash) class(x) # [1] "hash" "md5"
This doesn't effect hashes generated from strings. This can obviously create issues downstream, e.g. if I try and serialize the has to JSON:
jsonlite::toJSON(list(hash = x)) Error: No method asJSON S3 class: md5
If I generate a hash like for a file and coerce it to a character, it still doesn't have class
character
:This doesn't effect hashes generated from strings. This can obviously create issues downstream, e.g. if I try and serialize the has to JSON: