Skip to content

Add TileDB - #135

Merged
mattcieslak merged 2 commits into
mainfrom
add-tiledb
Aug 4, 2026
Merged

Add TileDB#135
mattcieslak merged 2 commits into
mainfrom
add-tiledb

Conversation

@tien-tong

Copy link
Copy Markdown
Contributor

No description provided.

@codecov-commenter

codecov-commenter commented Jul 31, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 91.11349% with 83 lines in your changes missing coverage. Please review.
✅ Project coverage is 91.66%. Comparing base (f833f90) to head (1653371).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
R/utils.R 86.55% 57 Missing ⚠️
R/analyse-helpers.R 93.80% 21 Missing ⚠️
R/analyse.R 93.82% 5 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #135      +/-   ##
==========================================
+ Coverage   90.48%   91.66%   +1.17%     
==========================================
  Files           6        6              
  Lines        1870     2542     +672     
==========================================
+ Hits         1692     2330     +638     
- Misses        178      212      +34     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@tien-tong
tien-tong requested a review from mattcieslak July 31, 2026 13:32
…ressions

The new TileDB test file never ran in CI: TileDBArray is Bioconductor-only,
so devtools::install_deps() could not resolve it and skip_if_no_tiledb()
skipped all 748 lines with a green build. Install tiledb/jsonlite via apt
(both in r2u), TileDBArray via BiocManager, and add a verify step so a
missing stack fails loudly instead of skipping silently.

Bug fixes:

* .modelarray_backend() returned a named scalar for merged objects, because
  mergeModelArrays() keys the backend vector by scalar name. Every caller
  compares with identical(., "tiledb"), which a surviving name makes FALSE,
  so on any merged object the TileDB row cache silently never engaged and
  elementMetadata() fell through to rhdf5::h5read() on a TileDB directory.

* writeResults()'s HDF5 branch kept the old deparsed-class check while the
  TileDB path used the new .prepare_results_for_storage(). The two disagree
  on numeric/integer columns carrying an extra class attribute: HDF5
  factorized them, replacing the values with LUT indices. Both backends now
  share one implementation.

* .read_scalar_row()'s non-contiguous fallback used `[[` on a named vector,
  which throws "subscript out of bounds" for an absent name rather than
  returning NULL, making the fall-through to a direct storage read dead code.

* write_results_compression_level was validated only on the TileDB path;
  hoisted above the backend branch to match .init_scalar_stream_writer().

* Backend auto-detection claimed any existing directory as a TileDB store,
  and the streaming writers unlink the group they replace. Now requires a
  .tdb suffix or a directory that actually contains scalars/ or results/.

* .write_hdf5_attribute() used create_attr(), which errors when the
  attribute already exists, unlike the h5writeAttribute() it replaced.

Output regressions:

* show() had dropped per-scalar element counts. Keep the new layout, which
  the vignettes document, and restore the counts as "FD (182581 elements)".

* print.h5summary() emitted "H5 file:/path"; the vignettes document the
  space after the colon.

Tests: cross-backend writeResults agreement, overwrite = FALSE on TileDB,
a multi-scalar store driving a scalar predictor, chunked reads verified
against unchunked with an out-of-order subset and n_cores = 2,
mergeModelArrays across mixed backends, and auto-detection boundaries.
Replaced the self-transposing reader in the HDF5/TileDB equivalence test
with an orientation assertion, which was masking the bug class most likely
in a new storage backend.

Also drop the committed generated README.html (it was shipping in the
tarball), regenerate man/ so h5summary.Rd becomes ModelArraySummary.Rd,
de-duplicate a test helper, and reindent three added lines so the change
is lint-neutral.
@mattcieslak
mattcieslak merged commit b38bb25 into main Aug 4, 2026
4 checks passed
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

Successfully merging this pull request may close these issues.

3 participants