> sessionInfo()
R version 3.1.3 (2015-03-09)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 7 x64 (build 7601) Service Pack 1
locale:
[1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] splines grid stats graphics grDevices utils datasets methods base
other attached packages:
[1] shinydashboard_0.3.0 DAAG_1.20 MASS_7.3-39 plyr_1.8.1
[5] devtools_1.7.0 flux_0.3-0 caTools_1.17.1 aod_1.3
[9] rms_4.3-0 SparseM_1.6 Hmisc_3.15-0 Formula_1.2-1
[13] lattice_0.20-30 KMsurv_0.1-5 scales_0.2.4 digest_0.6.8
[17] survAUC_1.0-5 survival_2.38-1 reshape2_1.4.1 heplots_1.0-12
[21] car_2.0-25 gridExtra_0.9.1 png_0.1-7 dygraphs_0.4.3
[25] ggplot2_1.0.1 data.table_1.9.4 shiny_0.11.1
loaded via a namespace (and not attached):
[1] acepack_1.3-3.3 bitops_1.0-6 chron_2.3-45 cluster_2.0.1
[5] codetools_0.2-10 colorspace_1.2-6 foreign_0.8-63 gtable_0.1.2
[9] htmltools_0.2.6 htmlwidgets_0.3.2 httpuv_1.3.2 labeling_0.3
[13] latticeExtra_0.6-26 lme4_1.1-7 magrittr_1.5 Matrix_1.1-5
[17] mgcv_1.8-4 mime_0.3 minqa_1.2.4 multcomp_1.4-0
[21] munsell_0.4.2 mvtnorm_1.0-2 nlme_3.1-120 nloptr_1.0.4
[25] nnet_7.3-9 parallel_3.1.3 pbkrtest_0.4-2 polspline_1.1.9
[29] proto_0.3-10 quantreg_5.11 R6_2.0.1 RColorBrewer_1.1-2
[33] Rcpp_0.11.5 RJSONIO_1.3-0 rpart_4.1-9 sandwich_2.3-3
[37] stringr_0.6.2 TH.data_1.0-6 tools_3.1.3 xtable_1.7-4
[41] zoo_1.7-12
> sessionInfo()
R version 3.1.3 (2015-03-09)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 8 x64 (build 9200)
locale:
[1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] splines grid stats graphics grDevices utils datasets methods base
other attached packages:
[1] shinydashboard_0.3.0 DAAG_1.20 MASS_7.3-39 plyr_1.8.1
[5] devtools_1.7.0 flux_0.3-0 caTools_1.17.1 aod_1.3
[9] rms_4.3-0 SparseM_1.6 Hmisc_3.15-0 Formula_1.2-0
[13] lattice_0.20-30 KMsurv_0.1-5 scales_0.2.4 digest_0.6.8
[17] survAUC_1.0-5 survival_2.38-1 reshape2_1.4.1 heplots_1.0-12
[21] car_2.0-25 gridExtra_0.9.1 png_0.1-7 dygraphs_0.4.2
[25] ggplot2_1.0.1 data.table_1.9.4 shiny_0.11.1
loaded via a namespace (and not attached):
[1] acepack_1.3-3.3 bitops_1.0-6 chron_2.3-45 cluster_2.0.1
[5] codetools_0.2-10 colorspace_1.2-6 foreign_0.8-63 gtable_0.1.2
[9] htmltools_0.2.6 htmlwidgets_0.3.2 httpuv_1.3.2 labeling_0.3
[13] latticeExtra_0.6-26 lme4_1.1-7 magrittr_1.5 Matrix_1.1-5
[17] mgcv_1.8-4 mime_0.3 minqa_1.2.4 multcomp_1.4-0
[21] munsell_0.4.2 mvtnorm_1.0-2 nlme_3.1-120 nloptr_1.0.4
[25] nnet_7.3-9 parallel_3.1.3 pbkrtest_0.4-2 polspline_1.1.9
[29] proto_0.3-10 quantreg_5.11 R6_2.0.1 RColorBrewer_1.1-2
[33] Rcpp_0.11.5 RJSONIO_1.3-0 rpart_4.1-9 sandwich_2.3-3
[37] stringr_0.6.2 TH.data_1.0-6 tools_3.1.3 xtable_1.7-4
[41] zoo_1.7-12
--
You received this message because you are subscribed to the Google Groups "Shiny - Web Framework for R" group.
To unsubscribe from this group and stop receiving emails from it, send an email to shiny-discus...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/shiny-discuss/1f538c76-6e19-4500-b05b-0fded37af997%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
To view this discussion on the web visit https://groups.google.com/d/msgid/shiny-discuss/aa37d29b-8aab-4cb1-b91f-ba5f17f6b9b5%40googlegroups.com.
“I suggested you debug httpuv::service, and see what exactly the value of timeoutMs is (which you did not tell us), and why R failed to coerce it to a numeric value. “
all.is.numeric2 <- function (x, what = c("test", "vector"), extras = c(".", "NA")) {
what <- match.arg(what)
old <- options(warn = -1)
on.exit(options(old))
x <- sub("[[:space:]]+$", "", x)
x <- sub("^[[:space:]]+", "", x)
xs <- x[x %nin% c("", extras)]
# suppressWarnings(isnum <- !any(is.na(as.numeric(xs))))
isnum <- !any(is.na(as.numeric(xs))) if (what == "test")
isnum
else if (isnum)
as.numeric(x)
else x
}“service” function.
function (timeoutMs = ifelse(interactive(), 100, 1000))
{
run(timeoutMs)
}
I think it will be nice if we can figure out the root cause instead of sweeping the issue under the carpet by suppressWarnings().
“Do you have options(warn) set on one of the computers? I don't know why else it'd pose such a problem if suppressWarnings fixes it.”
“I suspect run(timeoutMs) isn't actually relevant here, but just R/httpuv/shiny printing out the wrong part of the call stack.”
“Reino, where was the code that was calling all.is.numeric? In your Shiny Server function directly? In a reactive, or output? At the top of server.R?”
All over the place Joe. Lol The function is defined:
source(source_file, local = TRUE)
within source_file:
all.is.numeric2 <- function(input){…
isnum <-!any(is.na(as.numeric(xs)))
… }
hold <- function(input){…
all.is.numeric2(“sometimes a string”)
…}
shinyServer(function(input, output, clientData, session){
obs_fun <- observe({
…
hold(…)
…
})
reac_fun <- reactive({
…
hold(…)
…
})
}
" I suggest you write to Frank, and recommend him to use suppressWarnings() instead of
options(warn = -1)."
From names.c:
/* Type coercion */
{"as.double", do_ascharacter, 2, 1, -1, {PP_FUNCALL, PREC_FN, 0}},
From coerce.c:
/* the "ascharacter" name is a historical anomaly: as.character used to be the
* only primitive; now, all these ops are : */
SEXP attribute_hidden do_ascharacter(SEXP call, SEXP op, SEXP args, SEXP rho)
{
...
case 2:
name = "as.double"; type = REALSXP; break;
...
}
/*Which gets plopped into isna later..*/
SEXP attribute_hidden do_isna(SEXP call, SEXP op, SEXP args, SEXP rho)
{...
case REALSXP:
for (i = 0; i < n; i++)
LOGICAL(ans)[i] = ISNAN(REAL(x)[i]);
...}I do not see significant differences between the two R sessions: https://www.diffchecker.com/vmzd3js8 I do not understand why the warning messages can be different on the two computers.