Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

example causes R segfault #13

Open
nhejazi opened this issue Jul 23, 2017 · 2 comments
Open

example causes R segfault #13

nhejazi opened this issue Jul 23, 2017 · 2 comments

Comments

@nhejazi
Copy link

nhejazi commented Jul 23, 2017

I came across this package a while ago and finally got around to taking it for a test drive. I was quite excited about making hex stickers for several of my own packages, but, unfortunately, upon trying it out today, I discovered I cannot even run the example (for working with image files) in the README relevant to my intended use case:

❯ imgurl <- "http://www.belleamibengals.com/bengal_cat_2.png"
❯ sticker(imgurl, package="hexSticker", p_size=8, s_x=1, s_y=.75, s_width=.6, filename="./imgfile.png")

 *** caught segfault ***
address 0x0, cause 'unknown'

Traceback:
 1: grid.Call.graphics(C_text, as.graphicsAnnot(x$label), x$x, x$y,     resolveHJust(x$just, x$hjust), resolveVJust(x$just, x$vjust),     x$rot, x$check.overlap)
 2: drawDetails.text(x, recording = FALSE)
 3: drawDetails(x, recording = FALSE)
 4: drawGrob(x)
 5: recordGraphics(drawGrob(x), list(x = x), getNamespace("grid"))
 6: grid.draw.grob(x$children[[i]], recording = FALSE)
 7: grid.draw(x$children[[i]], recording = FALSE)
 8: drawGTree(x)
 9: recordGraphics(drawGTree(x), list(x = x), getNamespace("grid"))
10: grid.draw.gTree(x$children[[i]], recording = FALSE)
11: grid.draw(x$children[[i]], recording = FALSE)
12: drawGTree(x)
13: recordGraphics(drawGTree(x), list(x = x), getNamespace("grid"))
14: grid.draw.gTree(gtable)
15: grid.draw(gtable)
16: print.ggplot(x)
17: print(x)
18: grid.draw.ggplot(plot)
19: grid.draw(plot)
20: ggsave(sticker, width = 43.9, height = 50.8, filename = filename,     bg = "transparent", units = "mm")
21: save_sticker(filename, sticker)
22: sticker(imgurl, package = "hexSticker", p_size = 8, s_x = 1,     s_y = 0.75, s_width = 0.6, filename = "./imgfile.png")

Possible actions:
1: abort (with core dump, if enabled)
2: normal R exit
3: exit R without saving workspace
4: exit R saving workspace

I'm not exactly sure what might be going on internally, so some help in diagnosing and resolving this problem would be much appreciated.

Here's the relevant session information:

❯ sessionInfo()
R version 3.4.1 (2017-06-30)
Platform: x86_64-apple-darwin16.6.0 (64-bit)
Running under: macOS Sierra 10.12.5

Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libLAPACK.dylib

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] hexSticker_0.4.1     forcats_0.2.0        stringr_1.2.0.9000  
 [4] dplyr_0.7.2          purrr_0.2.2.2        readr_1.1.1         
 [7] tidyr_0.6.3          tibble_1.3.3         ggplot2_2.2.1       
[10] tidyverse_1.1.1.9000 devtools_1.13.2.9000 nima_0.4.0          
[13] fcuk_0.1.21          colorout_1.1-2       prompt_1.0.0        

loaded via a namespace (and not attached):
 [1] locfit_1.5-9.1       Rcpp_0.12.12         stringdist_0.9.4.4  
 [4] lubridate_1.6.0.9009 lattice_0.20-35      sysfonts_0.6        
 [7] fftwtools_0.9-8      png_0.1-7            clisymbols_1.2.0    
[10] gtools_3.5.0         assertthat_0.2.0     digest_0.6.12       
[13] psych_1.7.5          tiff_0.1-5           R6_2.2.2            
[16] cellranger_1.1.0     plyr_1.8.4           httr_1.2.1          
[19] rlang_0.1.1.9000     lazyeval_0.2.0       readxl_1.0.0        
[22] data.table_1.10.4    rstudioapi_0.6       ProjectTemplate_0.7 
[25] hexbin_1.27.1        boxes_0.0.0.9000     foreign_0.8-69      
[28] munsell_0.4.3        broom_0.4.2          compiler_3.4.1      
[31] modelr_0.1.0         gridGraphics_0.2     pkgconfig_2.0.1     
[34] BiocGenerics_0.22.0  mnormt_1.5-5         pkgbuild_0.0.0.9000 
[37] gridExtra_2.2.1      showtextdb_1.0       crayon_1.3.2.9000   
[40] withr_1.0.2          grid_3.4.1           nlme_3.1-131
[43] jsonlite_1.5         gtable_0.2.0         DBI_0.7             
[46] magrittr_1.5         scales_0.4.1.9002    stringi_1.1.5       
[49] reshape2_1.4.2       ggthemes_3.4.0       bindrcpp_0.2        
[52] xml2_1.1.1           EBImage_4.18.0       tools_3.4.1         
[55] showtext_0.4-6       glue_1.1.1           jpeg_0.1-8          
[58] hms_0.3              abind_1.4-5          pkgload_0.0.0.9000  
[61] parallel_3.4.1       colorspace_1.3-2     rvest_0.3.2         
[64] ggimage_0.0.4        memoise_1.1.0        bindr_0.1           
[67] haven_1.1.0   
@GuangchuangYu
Copy link
Owner

I can't reproduce your issue 😞

@nhejazi
Copy link
Author

nhejazi commented Jul 24, 2017

Thanks for trying. I guess it might be an issue on my local machine -- I'll try this again on a remote for verification. If that doesn't work, I guess no hex stickers for me 😢

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants