Re: [R-pkg-devel] Reproducing address sanitizer errors
On Sat, Jul 6, 2019 at 10:45 PM Ralf Stubner wrote: > I have been informed that the most recent upload of our swephR package > triggers stack-buffer-overflow. See for example > https://www.stats.ox.ac.uk/pub/bdr/memtests/clang-ASAN/swephR. The > reason seems to be quite obvious (an array has been declared with 36 > instead of 37 elements), but I would like to be sure about that. > However, I cannot reproduce the issue. I have tried > "rhub::check_with_sanitizers()" as well as running the problematic > code with RD from the docker image rocker/r-devel-ubsan-clang (with > --cap-add SYS_PTRACE), but to no avail. Does any of you have some > other possibility to reproduce ASAN errors? The linked page is gone since I uploaded a fixed version of swephR today. In the I was able to reproduce the error and check the fix using rocker/r-devel-ubsan-clang together with export ASAN_OPTIONS='detect_leaks=0:detect_odr_violation=0' cheerio ralf __ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel
[Rd] head.matrix can return 1000s of columns -- limit to n or add new argument?
I think of head() as a standard helper for "glancing" at objects, so I'm sometimes surprised that head() produces massive output: M = matrix(nrow = 10L, ncol = 10L) print(head(M)) # <- beware, could be a huge print I assume there are lots of backwards-compatibility issues as well as valid use cases for this behavior, so I guess defaulting to M[1:6, 1:6] is out of the question. Is there any scope for adding a new argument to head.matrix that would allow this flexibility? IINM it should essentially be as simple to do head.array as: do.call(`[`, c(list(x, drop = FALSE), lapply(pmin(dim(x), n), seq_len))) (with extra decoration to handle -n, etc) [[alternative HTML version deleted]] __ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel
Re: [Bioc-devel] Problems with MACPET package
Under bioc-devel, I ran MACPET/vignettes$ R CMD Stangle MACPET.Rmd and then in R source("MACPET.R", echo = TRUE) where the problem manifests as > summary(MACPET_pintraData,heatmap=TRUE) Error in .Vector_summary(object, ...) : unused argument (heatmap = TRUE) You have the S4 class > getClass(class(MACPET_pintraData)) Class "PIntra" [package "MACPET"] Slots: Name:anchor1 anchor2 regions NAMES Class: integer integer GRanges character_OR_NULL Name:elementMetadata metadata Class: DataFrame list Extends: Class "GInteractions", directly Class "Vector", by class "GInteractions", distance 2 Class "Annotated", by class "GInteractions", distance 3 Class "vector_OR_Vector", by class "GInteractions", distance 3 that extends 'Vector'. You have an S3 generic summary.PIntra, but I guess recently S4Vectors introduced an S4 method summary,Vector-method. Probably the dispatch system sees the inherited S4 method before your S3 method, and the solution is to change your S3 method to S4. Best practice would do this for all S3 methods defined on S4 classes. Martin On 7/8/19, 10:46 AM, "Bioc-devel on behalf of Ioannis Vardaxis" wrote: Hey, My package (MACPET) has been crashing lately. The error I get is from the vignette: Error in .Vector_summary(object, ...) : unused argument (heatmap = TRUE) Calls: ... withCallingHandlers -> withVisible -> eval -> eval -> summary -> summary Execution halted When I call the summary function which is specified on one of my classes. I realised that for some reason all the methods that I had created and worked fine for every class, they just don’t work anymore. I have no idea what causes the error.. Best, Ioannis [[alternative HTML version deleted]] ___ Bioc-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/bioc-devel ___ Bioc-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/bioc-devel
[Bioc-devel] Problems with MACPET package
Hey, My package (MACPET) has been crashing lately. The error I get is from the vignette: Error in .Vector_summary(object, ...) : unused argument (heatmap = TRUE) Calls: ... withCallingHandlers -> withVisible -> eval -> eval -> summary -> summary Execution halted When I call the summary function which is specified on one of my classes. I realised that for some reason all the methods that I had created and worked fine for every class, they just don’t work anymore. I have no idea what causes the error.. Best, Ioannis [[alternative HTML version deleted]] ___ Bioc-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/bioc-devel