[Bioc-devel] SpatialExperiment checks fail on Windows platform

Hervé Pagès hp@ge@@on@g|thub @end|ng |rom gm@||@com
Tue Dec 13 20:57:13 CET 2022

Hi Dario,

Note that we observe the same problem on our daily Windows builder, so 
this has not much to do with your GitHub actions setup:


It looks to me that some recent changes to the package broke the dim() 
method for StoredSpatialImage objects. Here is how the method is defined 
in BioC devel:

 > selectMethod("dim", "StoredSpatialImage")
Object with tracing code, class "MethodDefinitionWithTrace"
Original definition:
Method Definition:

function (x)
     src <- imgSource(x)
     src <- normalizePath(src)
     src <- paste0("file://", src)
     img <- .get_from_cache(src, NULL)
     if (!is.null(img))
     img <- image_read(src)
     tib <- image_info(img)
     c(tib$height, tib$width)
<bytecode: 0x55a3f2dee5b8>
<environment: namespace:SpatialExperiment>

target  "StoredSpatialImage"
defined "StoredSpatialImage"

## (to see the tracing code, look at body(object))

I'm not sure I understand the logic for prefixing the already normalized 
local path with "file://", but this breaks magick::image_read() on 
Windows. Without the "file://" prefix, the dim() method seems to work 
fine on all platforms.

Hope this helps,


On 12/12/2022 02:11, Dario Righelli wrote:
> Hi everyone,
> we are having an issue when running GithubActions on Windows platform
> that we are not able to figure out.
> The error is about loading an image as a grob during the vignette
> construction.
> It seems that it loads the image path twice, but this sounds weird
> because the same vignette code is working on the other two platforms
> (linux and osx).
> Does anyone have any ideas about this?
> Here it is the reported check error:
> Quitting from lines 110-111 (SpatialExperiment.Rmd) Error: processing
> vignette 'SpatialExperiment.Rmd' failed with diagnostics: Rscript.exe:
> UnableToOpenBlob
> `F:\biocbuild\bbs-3.17-bioc\tmpdir\RtmpsN0lzb\Rbuild3f6c3ae24a46\SpatialExperiment\vignettes\file:\F:\biocbuild\bbs-3.17-bioc\tmpdir\RtmpsN0lzb\Rinst3f6c113c6bc2\SpatialExperiment\extdata\10xVisium\section1\outs\spatial\tissue_lowres_image.png':
> Invalid argument @ error/blob.c/OpenBlob/2924 --- failed re-building
> 'SpatialExperiment.Rmd'
> Thanks, Dario
> 	[[alternative HTML version deleted]]
> _______________________________________________
> Bioc-devel using r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/bioc-devel

Hervé Pagès

Bioconductor Core Team
hpages.on.github using gmail.com

More information about the Bioc-devel mailing list