A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/16EAGLE/basemaps/issues/11 below:

Issues related to caching · Issue #11 · 16EAGLE/basemaps · GitHub

I believe I've stumbled upon a couple of possibly inter-related issues with the caching code.

First, if I set something like the following:

basemap_ggplot(ext=ext,map_service='esri',map_type='world_imagery',verbose=TRUE, map_dir=file.path(.wd,'mymaps'))

png files are correctly placed in the mymaps folder. However, a file like mymapsbasemap_20220829115215.tif is placed in my working directory. Is this also supposed to be placed in the mymaps directory? If so, I think the culprit is here:

paste0(map_dir, "basemap_", gsub(":", "", gsub(" ", "", gsub("-", "", Sys.time()))), ".tif")

Perhaps you meant do so something like file.path(map_dir, ...) instead of paste0(map_dir,...) ?

Secondly, the basemap_* function throws an error message if you change the cache within the session. If I executed the code above, then execute (changing mymaps to mytiles):

basemap_ggplot(ext=ext,map_service='esri',map_type='world_imagery',verbose=TRUE, map_dir=file.path(.wd,'mytiles'))

I receive the error message

Error in cached[[which(cached.match)]]$file_comp : $ operator is invalid for atomic vectors

It seems to come from here:

cached[[which(cached.match)]]$file_comp

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4