Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upR crashing intermitently #115
Comments
|
Is there any error message printed to the console?
…On Fri, Sep 28, 2018, 7:32 AM Pedro Aphalo ***@***.***> wrote:
Summary
When building the vignettes of 'ggspectra' R crashes intermittently in
chunks which use geom_label_repel with long vectors of labels. These same
examples have been working well for several versions of 'ggspectra'.
Minimal code example
I have no example yet that consistently triggers this problem. Could this
problem be the result of a memory leak?
Question
Is this a known problem?
Suggested solution
I will investigate this in detail next week, unless this is a known issue.
Version information
Here is the output from sessionInfo() in my R session:
R version 3.5.1 Patched (2018-09-25 r75362)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)
Matrix products: default
locale:
[1] LC_COLLATE=English_United Kingdom.1252 LC_CTYPE=English_United Kingdom.1252
[3] LC_MONETARY=English_United Kingdom.1252 LC_NUMERIC=C
[5] LC_TIME=English_United Kingdom.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] bindrcpp_0.2.2 knitr_1.20 ggrepel_0.8.0
[4] ggspectra_0.2.5-1 photobiologyWavebands_0.4.2 photobiology_0.9.24
[7] scales_1.0.0 ggplot2_3.0.0
loaded via a namespace (and not attached):
[1] Rcpp_0.12.18 pillar_1.3.0 compiler_3.5.1 plyr_1.8.4 bindr_0.1.1
[6] tools_3.5.1 digest_0.6.17 packrat_0.4.9-3 evaluate_0.11 lubridate_1.7.4
[11] tibble_1.4.2 gtable_0.2.0 pkgconfig_2.0.2 rlang_0.2.2 rstudioapi_0.7
[16] yaml_2.2.0 withr_2.1.2 dplyr_0.7.6 stringr_1.3.1 rprojroot_1.3-2
[21] grid_3.5.1 tidyselect_0.2.4 glue_1.3.0 R6_2.2.2 rmarkdown_1.10
[26] purrr_0.2.5 splus2R_1.2-2 magrittr_1.5 backports_1.1.2 htmltools_0.3.6
[31] assertthat_0.2.0 colorspace_1.3-2 labeling_0.3 stringi_1.2.4 lazyeval_0.2.1
[36] munsell_0.5.0 crayon_1.3.4
--
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#115>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAMzMp5ifwK6OnrmlndiW-h45-bKNuxXks5ufgjIgaJpZM4W-Vvu>
.
|
|
No, just R has crashed when knitting in RStudio, and system error when building the package or checking it, but only occasionally. However, my laptop has been misbehaving lately, so if this problem has not been earlier reported I think I will investigate by myself and let you know my progress sometime next week. I have yet to see the problem in Winbuilder... |
|
Problem seems to be in my own package. Sorry about the false alarm! |
|
@slowkow I have now found a way of reproducing the R crashes. Seems to be a memory corruption or something related. Long vectors of labels, like those we discussed about earlier as a way of avoiding overlap with data points by setting labels to "", no longer work in 'ggrepel' 0.8.0. In some cases when the data is not so big, the crash of R may happen after the plot is printed on a subsequent call to a different R function.
The system data is:
Hope this helps. |
|
Thanks for sharing an example. It does not crash R on my system. At this point, my best guess is that the problem might be revealed by comparing the compiler output for the C++ code on Windows and macOS. You might consider recompiling the code by yourself on your own machine instead of running the compiled code from CRAN. My system:
On my MacBook, I can run the first example with 1000 points and 100 labels:
Here is the second plot:
|
|
I installed 'ggrepel' from sources from CRAN, and this did not solve the problem. |
|
Pedro, thank you! I never noticed that log, but it should help to figure this out. I found a nice blog post by Brian J. Knaus that should help get us started: https://knausb.github.io/2017/06/cran-memory-error/ Since your system is crashing, I think you have a good chance to find the bug if you're able and willing. Please feel free to go ahead and hunt for the bug. I'll be very grateful if you can fix it! My system is not crashing, so it looks like there is a lot of work ahead to find the bug:
I'd like to ask for help on this issue. If anyone wants to try to fix this, I would greatly appreciate your help. I'm not sure if I can fix this any time soon. |
|
Must be a new type of log. I saw it for the first time only today. I am very busy at the moment with teaching and manuscripts about to be submitted. I'll give a go at continuing the debugging next weekend, unless I find some free time tomorrow. If you have any code that needs to be quickly tested, I can handle that a lot faster. |
|
OK, don't worry about it for now. I will spend some time and see if I make any progress. Just browsing around, I found some nice new packages and websites that should make this easier. For example, I think I should be able to test the package with ASAN just like this: # In the ggrepel directory.
install.packages("rhub")
library(rhub)
# Validate your email address and get an access token.
validate_email()
# Send the tar.gz file to https://builder.r-hub.io
# Check it for errors with ASAN
check_with_sanitizers() |
|
I had not noticed that 'rhub' now has |
|
My first attempt did not reproduce the CRAN error: https://builder.r-hub.io/status/ggrepel_0.8.0.tar.gz-9779cd78b03c425fa366849cf09189d5#L2368 I tried again with this command: # First, download the source package for ggrepel from CRAN.
# Test it.
check_with_sanitizers(
path = "ggrepel_0.8.0.tar.gz",
check_args = '--as-cran --no-stop-on-test-error'
)But I don't think it actually executed the same code as the CRAN log: https://builder.r-hub.io/status/ggrepel_0.8.0.tar.gz-198f9a4fd10e41c6999754cddbea83b8 I'm not sure where to go from here... any tips would be helpful! |
|
I looked at the commits and you haven't made many edits to the C++ code recently. The only further insight is that the crash happens when the figure is printed rather than when the ggplot2 object is constructed. |
|
@slowkow I have just updated to 'ggplot2' 3.1.0 (and 'rlang' and 'tidyr') and I can no longer reproduce the error. Hopefully this is the end of this problem. I am not closing this issue yet, as probably some additional testing would be a good idea. |
|
@slowkow I was too fast, after a few successful checks the problem started to repeat, and was not cured by restarting Windows. So, once again, crashes are reproducible... part of the time. |
|
I'm still interested to fix the bug in your linked report. (I copied it here to make sure I can read it later.) Unfortunately, I don't have time right now to setup my development environment with the necessary tools to track it down. Thanks again for reporting this! Eventually this will need to get fixed. I hope it doesn't slow you down too much. Sorry I can't offer more support right now. ERROR: AddressSanitizer: heap-buffer-overflow* using log directory ‘/data/gannet/ripley/R/packages/tests-gcc-SAN/ggrepel.Rcheck’
* using R Under development (unstable) (2018-10-22 r75478)
* using platform: x86_64-pc-linux-gnu (64-bit)
* using session charset: UTF-8
* using option ‘--no-stop-on-test-error’
* checking for file ‘ggrepel/DESCRIPTION’ ... OK
* this is package ‘ggrepel’ version ‘0.8.0’
* checking package dependencies ... OK
* checking if this is a source package ... OK
* checking if there is a namespace ... OK
* checking for hidden files and directories ... OK
* checking for portable file names ... OK
* checking whether package ‘ggrepel’ can be installed ... [78s/85s] OK
* checking package directory ... OK
* checking whether the package can be loaded ... OK
* checking whether the package can be loaded with stated dependencies ... OK
* checking whether the package can be unloaded cleanly ... OK
* checking whether the namespace can be loaded with stated dependencies ... OK
* checking whether the namespace can be unloaded cleanly ... OK
* checking loading without being on the library search path ... OK
* checking compiled code ... OK
* checking installed files from ‘inst/doc’ ... OK
* checking files in ‘vignettes’ ... OK
* checking examples ... [11s/12s] OK
* checking tests ... [30s/30s] OK
Running ‘testthat.R’ [29s/29s]
* checking package vignettes in ‘inst/doc’ ... OK
* checking re-building of vignette outputs ... [10s/11s] WARNING
Error in re-building vignettes:
...
Warning in hook_png(before, options, envir, "pngquant", function(x) { :
cannot find pngquant; please install and put it in PATH
=================================================================
==37138==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x608000002a00 at pc 0x7f3635a98931 bp 0x7ffe80159f50 sp 0x7ffe80159f40
READ of size 32 at 0x608000002a00 thread T0
#0 0x7f3635a98930 in repel_boxes(Rcpp::Matrix<14, Rcpp::PreserveStorage>, double, double, Rcpp::Matrix<14, Rcpp::PreserveStorage>, Rcpp::Vector<14, Rcpp::PreserveStorage>, Rcpp::Vector<14, Rcpp::PreserveStorage>, Rcpp::Vector<14, Rcpp::PreserveStorage>, Rcpp::Vector<14, Rcpp::PreserveStorage>, double, int, std::__cxx11::basic_string, std::allocator >) /data/gannet/ripley/R/packages/tests-gcc-SAN/ggrepel/src/repel_boxes.cpp:631
#1 0x7f3635a2bcaa in _ggrepel_repel_boxes /data/gannet/ripley/R/packages/tests-gcc-SAN/ggrepel/src/RcppExports.cpp:87
#2 0x56773a in R_doDotCall /data/gannet/ripley/R/svn/R-devel/src/main/dotcode.c:617
#3 0x570fcb in do_dotcall /data/gannet/ripley/R/svn/R-devel/src/main/dotcode.c:1252
#4 0x61c427 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6769
#5 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#6 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#7 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#8 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#9 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#10 0x6e316a in dispatchMethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:433
#11 0x6e3ed6 in Rf_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:473
#12 0x6e4727 in do_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:562
#13 0x618ca2 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6789
#14 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#15 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#16 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#17 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#18 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#19 0x641cf3 in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:743
#20 0x5bc361 in do_recordGraphics /data/gannet/ripley/R/svn/R-devel/src/main/engine.c:3107
#21 0x61c427 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6769
#22 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#23 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#24 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#25 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#26 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#27 0x6e316a in dispatchMethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:433
#28 0x6e3b58 in Rf_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:469
#29 0x6e4727 in do_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:562
#30 0x618ca2 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6789
#31 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#32 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#33 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#34 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#35 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#36 0x641cf3 in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:743
#37 0x5bc361 in do_recordGraphics /data/gannet/ripley/R/svn/R-devel/src/main/engine.c:3107
#38 0x61c427 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6769
#39 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#40 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#41 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#42 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#43 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#44 0x6e316a in dispatchMethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:433
#45 0x6e3b58 in Rf_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:469
#46 0x6e4727 in do_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:562
#47 0x618ca2 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6789
#48 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#49 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#50 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#51 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#52 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#53 0x641cf3 in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:743
#54 0x5bc361 in do_recordGraphics /data/gannet/ripley/R/svn/R-devel/src/main/engine.c:3107
#55 0x61c427 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6769
#56 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#57 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#58 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#59 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#60 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#61 0x6e316a in dispatchMethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:433
#62 0x6e3b58 in Rf_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:469
#63 0x6e4727 in do_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:562
#64 0x618ca2 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6789
#65 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#66 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#67 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#68 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#69 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#70 0x6e316a in dispatchMethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:433
#71 0x6e3b58 in Rf_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:469
#72 0x6e4727 in do_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:562
#73 0x618ca2 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6789
#74 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#75 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#76 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#77 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#78 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#79 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#80 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#81 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#82 0x6e316a in dispatchMethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:433
#83 0x6e3de8 in Rf_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:483
#84 0x6e4727 in do_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:562
#85 0x618ca2 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6789
#86 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#87 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#88 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#89 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#90 0x643507 in forcePromise /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:516
#91 0x64207f in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:643
#92 0x652a3d in do_withVisible /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:3201
#93 0x6ddc4b in do_internal /data/gannet/ripley/R/svn/R-devel/src/main/names.c:1372
#94 0x618ca2 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6789
#95 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#96 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#97 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#98 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#99 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#100 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#101 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#102 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#103 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#104 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#105 0x643507 in forcePromise /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:516
#106 0x64207f in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:643
#107 0x652a3d in do_withVisible /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:3201
#108 0x6ddc4b in do_internal /data/gannet/ripley/R/svn/R-devel/src/main/names.c:1372
#109 0x618ca2 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6789
#110 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#111 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#112 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#113 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#114 0x643507 in forcePromise /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:516
#115 0x644157 in FORCE_PROMISE /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:4962
#116 0x644157 in getvar /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:5004
#117 0x61e7c5 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6501
#118 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#119 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#120 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#121 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#122 0x643507 in forcePromise /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:516
#123 0x644157 in FORCE_PROMISE /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:4962
#124 0x644157 in getvar /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:5004
#125 0x61e7c5 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6501
#126 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#127 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#128 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#129 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#130 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#131 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#132 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#133 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#134 0x641cf3 in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:743
#135 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#136 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#137 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#138 0x643507 in forcePromise /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:516
#139 0x644157 in FORCE_PROMISE /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:4962
#140 0x644157 in getvar /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:5004
#141 0x61e7c5 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6501
#142 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#143 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#144 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#145 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#146 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#147 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#148 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#149 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#150 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#151 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#152 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#153 0x6e316a in dispatchMethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:433
#154 0x6e3ed6 in Rf_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:473
#155 0x6e4727 in do_usemethod /data/gannet/ripley/R/svn/R-devel/src/main/objects.c:562
#156 0x618ca2 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6789
#157 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#158 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#159 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#160 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#161 0x643507 in forcePromise /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:516
#162 0x644157 in FORCE_PROMISE /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:4962
#163 0x644157 in getvar /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:5004
#164 0x61e7c5 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6501
#165 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#166 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#167 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#168 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#169 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#170 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#171 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#172 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#173 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#174 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#175 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#176 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#177 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#178 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#179 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#180 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#181 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#182 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#183 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#184 0x643507 in forcePromise /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:516
#185 0x644157 in FORCE_PROMISE /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:4962
#186 0x644157 in getvar /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:5004
#187 0x61e7c5 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6501
#188 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#189 0x643507 in forcePromise /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:516
#190 0x644157 in FORCE_PROMISE /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:4962
#191 0x644157 in getvar /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:5004
#192 0x61e7c5 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6501
#193 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#194 0x643507 in forcePromise /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:516
#195 0x644157 in FORCE_PROMISE /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:4962
#196 0x644157 in getvar /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:5004
#197 0x61e7c5 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6501
#198 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#199 0x643507 in forcePromise /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:516
#200 0x644157 in FORCE_PROMISE /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:4962
#201 0x644157 in getvar /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:5004
#202 0x61e7c5 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6501
#203 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#204 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#205 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#206 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#207 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#208 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#209 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#210 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#211 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#212 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#213 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#214 0x6208f7 in bcEval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:6737
#215 0x6417ef in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:620
#216 0x646945 in R_execClosure /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:1780
#217 0x641cf3 in Rf_eval /data/gannet/ripley/R/svn/R-devel/src/main/eval.c:743
#218 0x6b821e in Rf_ReplIteration /data/gannet/ripley/R/svn/R-devel/src/main/main.c:260
#219 0x6b88d0 in R_ReplConsole /data/gannet/ripley/R/svn/R-devel/src/main/main.c:310
#220 0x6b8a04 in run_Rmainloop /data/gannet/ripley/R/svn/R-devel/src/main/main.c:1084
#221 0x417b88 in main /data/gannet/ripley/R/svn/R-devel/src/main/Rmain.c:29
#222 0x7f364b26711a in __libc_start_main (/lib64/libc.so.6+0x2311a)
#223 0x41a2b9 in _start (/data/gannet/ripley/R/gcc-SAN/bin/exec/R+0x41a2b9)
|
|
Just some observations. My C++ is not good enough to detect buffer overflows just by reading, so probably red herrings:
ratios[i] = (TextBoxes[i].y2 - TextBoxes[i].y1)
/ (TextBoxes[i].x2 - TextBoxes[i].x1);
original_centroids[i] = centroid(TextBoxes[i], hjust[i], vjust[i]);a. Are zero-width labels going to cause divide-by-zero problems in b. Are we sure that |
|
Has there been any progress on this issue? I have experienced the same problem (on Windows) - R crashes intermittently when trying to print figures which use ggrepel with long vectors of labels. I use ggrepel a lot - it's very useful and saves me a lot of time - so I'm following this issue with interest! I definitely haven't the programming knowledge to help, unfortunately. |
|
@m20ty Sorry to hear that, Mike. No progress yet. Thanks for letting us know that you have the same problem. That increases my confidence that there is a bug in the C++ code. Still very weird that I never see this on macOS. For those of you experiencing this issue, could I please ask you to try compiling the source code? Try installing ggrepel like this: install.packages("ggrepel", type = "source")Then close your R session and start a fresh one. Does this issue continue? Does it go away? |
|
Confirm that even compiling from source on Windows reproduces the issue.
…On Fri, 15 Feb 2019 at 12:48 am, Kamil Slowikowski ***@***.***> wrote:
@m20ty <https://github.com/m20ty> Sorry to hear that, Mike. No progress
yet. Thanks for letting us know that you have the same problem. That
increases my confidence that there is a bug in the C++ code. Still very
weird that I never see this on macOS.
For those of you experiencing this issue, could I please ask you to try
compiling the source code? Try installing ggrepel like this:
install.packages("ggrepel", type = "source")
Then close your R session and start a fresh one.
Does this issue continue? Does it go away?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#115 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHvGDIe2Ukb5_zfYnlmx8Cp8UZ2odSleks5vNWk1gaJpZM4W-Vvu>
.
|
|
Sorry — I meant after compiling from source I can still reproduce, not that
I can reproduce the memory fault simply by installing.
On Fri, 15 Feb 2019 at 12:50 am, HughParsonage <notifications@github.com>
wrote:
… Confirm that even compiling from source on Windows reproduces the issue.
On Fri, 15 Feb 2019 at 12:48 am, Kamil Slowikowski <
***@***.***>
wrote:
> @m20ty <https://github.com/m20ty> Sorry to hear that, Mike. No progress
> yet. Thanks for letting us know that you have the same problem. That
> increases my confidence that there is a bug in the C++ code. Still very
> weird that I never see this on macOS.
>
> For those of you experiencing this issue, could I please ask you to try
> compiling the source code? Try installing ggrepel like this:
>
> install.packages("ggrepel", type = "source")
>
> Then close your R session and start a fresh one.
>
> Does this issue continue? Does it go away?
>
> —
> You are receiving this because you commented.
> Reply to this email directly, view it on GitHub
> <#115 (comment)>,
> or mute the thread
> <
https://github.com/notifications/unsubscribe-auth/AHvGDIe2Ukb5_zfYnlmx8Cp8UZ2odSleks5vNWk1gaJpZM4W-Vvu
>
> .
>
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#115 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHvGDHNzo2L89vFpRg2hF4vGtFsJ-uEWks5vNWmqgaJpZM4W-Vvu>
.
|
|
I can also reproduce the issue after installing from source on Windows. |
|
Kurt Hornik from CRAN says we need to fix this by 2019-03-08 to safely retain ggrepel package on CRAN. If anyone would like to help contribute by fixing this bug, many ggrepel users would be very grateful for your help. Here are the log files that show the errors: https://cran.r-project.org/web/checks/check_results_ggrepel.html In particular, have a look at one of these 2 files: https://www.stats.ox.ac.uk/pub/bdr/memtests/clang-ASAN/ggrepel/00check.log https://www.stats.ox.ac.uk/pub/bdr/memtests/gcc-ASAN/ggrepel/00check.log |
|
Could you try the new code I just pushed? I think I fixed the heap buffer overflow error. |
|
Can confirm the problem is fixed. Ran the reprex above without issue. Thank you! |
|
@slowkow I can also confirm that the vignettes of 'ggspectra' no longer crash R under Windows 10. i.e. the bug I reported when I opened this issue seems to have been solved. |
|
@HughParsonage @aphalo I'm very happy to hear that. I'm sorry for all the crashes. I know it can be frustrating and disruptive to your work, and I apologize for causing this issue. I really hope I didn't disrupt your work too badly. Thanks for your patience! Since this fix is important, I will try to push a new release of ggrepel to CRAN as soon as possible. |


Summary
When building the vignettes of 'ggspectra' R crashes intermittently in chunks which use
geom_label_repelwith long vectors of labels. These same examples have been working well for several versions of 'ggspectra'.Minimal code example
I have no example yet that consistently triggers this problem. Could this problem be the result of a memory leak?
Question
Is this a known problem?
Suggested solution
I will investigate this in detail next week, unless this is a known issue.
Version information
Here is the output from
sessionInfo()in my R session: