Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
c4ac5a5
fix(error): compile test module only under cfg(test), prune dead vari…
noamteyssier Aug 26, 2026
23fb13f
refactor(bq)!: drop StreamWriter and the deprecated write_record family
noamteyssier Aug 26, 2026
c3eea07
refactor(fastx): drain only completed blocks per batch
noamteyssier Aug 26, 2026
40a13b8
refactor: delete dead code across bq, vbq, write, and record
noamteyssier Aug 26, 2026
374d6e0
refactor(cbq): delete dead code
noamteyssier Aug 26, 2026
75d88bb
dep: replace byteorder with std to_le_bytes / from_le_bytes
noamteyssier Aug 26, 2026
ad775a2
dep: use std available_parallelism instead of num_cpus
noamteyssier Aug 26, 2026
5bcd1b8
dep: drop auto_impl; move memchr to dev-dependencies
noamteyssier Aug 26, 2026
8e4c8ef
refactor!: share one nucleotide Encoder between bq and vbq writers
noamteyssier Aug 26, 2026
946ad1c
refactor: simplify internals across readers, writers, and indexes
noamteyssier Aug 26, 2026
98e22b1
test(policy): reduce the number of repeated tests and collapse into
noamteyssier Aug 26, 2026
aa23e14
chore: restrict internal reader items to pub(crate)
noamteyssier Aug 26, 2026
ccae95e
chore: remove cargo config from repo
noamteyssier Aug 26, 2026
0432230
chore: track lock
noamteyssier Aug 26, 2026
0b7feec
docs: update changelog and bump version
noamteyssier Aug 26, 2026
a2d3157
ci: fix ci to point to auto-write
noamteyssier Aug 26, 2026
5e695d4
fix(vbq): only flush a full block once the record will be written
noamteyssier Aug 26, 2026
75ddfae
style: formatting
noamteyssier Aug 26, 2026
5936d2f
refactor: safe accessors for dbuf with slices
noamteyssier Aug 26, 2026
1758693
feat!: make paraseq and anyhow opt-in
noamteyssier Aug 26, 2026
b117a14
ci: don't need to run examples in release mode and fix args
noamteyssier Aug 26, 2026
9a5200d
refactor: add back in opt flag
noamteyssier Aug 26, 2026
bea1c4c
refactor: add back in all opt
noamteyssier Aug 26, 2026
20a68bd
refactor: add back in with_compression_level
noamteyssier Aug 26, 2026
f91762a
style: clippy fix
noamteyssier Aug 26, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions .cargo/config.toml

This file was deleted.

19 changes: 12 additions & 7 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,14 @@ jobs:
- name: Build
run: cargo build --verbose
- name: Run tests
run: cargo test --verbose
run: cargo test --verbose --all-features
- name: Run tests (release)
run: cargo test --verbose --release
run: cargo test --verbose --release --all-features
- name: Check feature matrix
run: |
cargo check --no-default-features
cargo check --no-default-features --features paraseq
cargo check --no-default-features --features anyhow

fmt_lint:
runs-on: ubuntu-latest
Expand All @@ -37,7 +42,7 @@ jobs:
steps:
- uses: actions/checkout@v7
- name: run example ${{ matrix.ext }}
run: cargo run --release --example grep -- ./data/subset.${{ matrix.ext }} "ACGTACGT"
run: cargo run --example grep -- ./data/subset.${{ matrix.ext }} "ACGTACGT"

example_range:
runs-on: ubuntu-latest
Expand All @@ -47,7 +52,7 @@ jobs:
steps:
- uses: actions/checkout@v7
- name: run example ${{ matrix.ext }}
run: cargo run --release --example parallel_range -- ./data/subset.${{ matrix.ext }} 4 30 200
run: cargo run --example parallel_range -- ./data/subset.${{ matrix.ext }} -T 4 --start 30 --end 200

example_write:
runs-on: ubuntu-latest
Expand All @@ -57,9 +62,9 @@ jobs:
steps:
- uses: actions/checkout@v7
- name: run example (single) ${{ matrix.ext }}
run: cargo run --release --example write -- ./data/subset_R1.fastq.gz -o ./output.${{ matrix.ext }}
run: cargo run --example auto-write -F paraseq -- ./data/subset_R1.fastq.gz -o ./output.${{ matrix.ext }}
- name: run example (paired) ${{ matrix.ext }}
run: cargo run --release --example write -- ./data/subset_R1.fastq.gz ./data/subset_R2.fastq.gz -o ./output.${{ matrix.ext }}
run: cargo run --example auto-write -F paraseq -- ./data/subset_R1.fastq.gz ./data/subset_R2.fastq.gz -o ./output.${{ matrix.ext }}

example_read:
runs-on: ubuntu-latest
Expand All @@ -69,4 +74,4 @@ jobs:
steps:
- uses: actions/checkout@v7
- name: run example ${{ matrix.ext }}
run: cargo run --release --example read -- ./data/subset.${{ matrix.ext }}
run: cargo run --example read -- ./data/subset.${{ matrix.ext }}
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/target

Cargo.lock
data/test*
53 changes: 53 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,59 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.10.0] - 2026-08-25

- Large cleanup of internal and public API.
- Runtime dependencies removed (`byteorder`, `num_cpus`, `auto_impl`, and `memchr`).
- Deprecated items removed from the public API.

### Removed

- **`bq::StreamWriter` / `bq::StreamWriterBuilder`**
- pure delegating wrappers; compose `bq::WriterBuilder` with `std::io::BufWriter` instead (see the `network_streaming` example).
- **Deprecated `write_record` / `write_paired_record`** on the `bq` and `vbq` writers
- use `push(SequencingRecord)`.
- **`bq::Encoder`** from the public API
- `bq` and `vbq` now share one internal encoder;
- sequence-length validation happens in `bq::Writer::push`.
- **`vbq::BlockIndex::from_vbq`**
- indexes are embedded in VBQ files - removing this holdover from way back when;
- use `MmapReader::load_index`.
- **Redundant header constructors**
- `bq::FileHeader::{new, new_extended, set_bitsize}` and `vbq::FileHeader::{new, with_capacity, set_bitsize}`;
- use the `FileHeaderBuilder`s.
- **Never-constructed error variants**
- the five `WriteError` flag-mismatch variants and `CbqError::MissingSequenceOnSequencingRecord`;
- `BuilderError` folds into `HeaderError::MissingSequenceLength` and `FastxEncodingError` into `WriteError`.
- **`&R` / `&mut R` impls of `BinseqRecord`**
- the `auto_impl` dependency is dropped and nothing used the reference impls;
- pass records by value (they are already references anyways).
- Dead accessors throughout (`RefRecord::{config, set_id}`, `cbq` writer `usage` / `bytes_written`, and similar zero-caller items), plus the redundant `streaming` and `write` examples.

### Changed

- `SequencingRecord` fields are now public and the getters are removed
- FASTX encoding now drains only _completed_ blocks per batch and does a final drain per thread
- CBQ blocks stay full across batches for better compression and less time under the global writer lock.
- Dependencies: `byteorder` replaced with `std` little-endian conversions (byte-identical output), `num_cpus` replaced with `std::thread::available_parallelism`, `auto_impl` dropped, and `memchr` moved to dev-dependencies.
- The `paraseq` feature is no longer enabled by default, reducing compile times when FASTX encoding is not needed. Enable it with `features = ["paraseq"]` to use `encode_fastx` (which remains visible on docs.rs with a feature banner).
- `anyhow` is now actually an optional dependency:
- the CBQ Elias-Fano codec is handled directly without the auto-derive from thiserror
- fixes the optional feature which actually never compiled when disabled.
- Internal simplification:
- one shared `bq`/`vbq` encoder
- `BatchRecord` wraps `RefRecord`
- `cbq` `Span` replaced by `Range<usize>`
- unreachable `pub` items demoted to `pub(crate)`.

### Fixed

- The `error` test module was missing `#[cfg(test)]`, so a test-only enum compiled into release builds.
- `cbq::Index::average_block_size` reports `0.0` instead of `NaN` for files with fewer than two blocks.
- `encode_fastx` with single non-paired input no longer records second read's length as `xlen`
- made fixed-length BQ output look paired and fail on interleaved encoding.
- The extended length now only probes when builder is configured paired.

## [0.9.6] - 2026-08-12

### Changed
Expand Down
Loading