windows_version() cannot catch Windows version
Closed this issue · 2 comments
cedricbatailler commented
Hey! Nice work, will be super useful. :)
Unfortunately I have a problem using notify()
. Here's the output I get when I try to use it.
> notifier::notify("Test")
Error: invalid version specification ‘Microsoft Windows [version 6.1.7601]’
By digging around I think the problem come from windows_version()
function (more specifically, line 21).
The input this function receive must be badly formatted in my case, when tracebacking, here's the input this line receives: Microsoft Windows [version 6.1.7601]
. I guess this line was to supposed to extract 6.1.7601
but it doesn't appear to work.
Here are more info:
> sessionInfo()
R version 3.3.2 (2016-10-31)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 7 x64 (build 7601) Service Pack 1
locale:
[1] LC_COLLATE=French_France.1252 LC_CTYPE=French_France.1252 LC_MONETARY=French_France.1252
[4] LC_NUMERIC=C LC_TIME=French_France.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] magrittr_1.5 readxl_0.1.1 dplyr_0.5.0 purrr_0.2.2 readr_1.0.0 tidyr_0.6.0 tibble_1.2
[8] ggplot2_2.2.0 tidyverse_1.0.0
loaded via a namespace (and not attached):
[1] Rcpp_0.12.8 notifier_1.0.0 devtools_1.12.0 munsell_0.4.3 colorspace_1.3-1 R6_2.2.0 httr_1.2.1
[8] plyr_1.8.4 tools_3.3.2 grid_3.3.2 gtable_0.2.0 DBI_0.5-1 git2r_0.16.0 withr_1.0.2
[15] lazyeval_0.2.0 assertthat_0.1 digest_0.6.10 curl_2.3 memoise_1.0.0 scales_0.4.1
gaborcsardi commented
Thanks, it seems that sometimes version
is in lowercase. Easy to fix....
cedricbatailler commented
#8 appears to fix the problem on my setup!