You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: NEWS.md
+7Lines changed: 7 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,12 @@
1
1
# filearray (development version)
2
2
3
+
# filearray 0.1.4
4
+
5
+
* Fixed a bug when allocated memory is one byte short than requested. The bug would crash R when triggered in certain cases.
6
+
* Removed limit to the maximum number of partitions when writing. The previous implementation creates and opens related file descriptors all at once before writing. This setup will raise errors when the number of connections reach to certain limit, often defined by the operating systems. This update only opens the connection on demand. The performance might be impacted when writing to disk, but in return, the program will be more robust
7
+
* Fixed `subset` function environment not resolved correctly when using formula
8
+
* Added `filearray_load_or_create` as an alternative to `filearray_checkload` by automatically replace existing obsolete array files if the headers, dimensions, or data types don't match. Also `on_missing` argument is provided to allow array initialization if new array is created.
9
+
3
10
# filearray 0.1.3
4
11
5
12
* Automatically detect whether symbolic-link works and show warnings
stop("`filearray_load_or_create`: additional parameters must be named.")
251
+
}
252
+
}
253
+
254
+
255
+
arr<- tryCatch(
256
+
expr= {
257
+
# try to load existing array
258
+
arr<- filearray_checkload(
259
+
filebase=filebase, mode=mode,
260
+
symlink_ok=symlink_ok, ...
261
+
)
262
+
263
+
# If no error raised, the array has been loaded
264
+
265
+
if(!is.na(type)) {
266
+
if(!identical(arr$type(), type)) {
267
+
stop("`filearray_load_or_create`: Requested array type does not match with existing array.")
268
+
}
269
+
} else {
270
+
# in case the array needs to be reconstructed, assuming the type
271
+
# remain the same
272
+
type<-arr$type()
273
+
}
274
+
275
+
# Now check the dimension
276
+
arr_dim<- as.integer(arr$dimension())
277
+
if(!identical(arr_dim, dimension)) {
278
+
stop("`filearray_load_or_create`: Requested dimension does not match with existing array.")
279
+
}
280
+
281
+
arr
282
+
},
283
+
error=function(e) {
284
+
if(verbose) {
285
+
message("`filearray_load_or_create`: cannot load the existing file array: ", e$message, "\nTrying creating a new one. If the array already exists, its file path will be removed.")
0 commit comments