Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
18 changes: 0 additions & 18 deletions .amc.toml

This file was deleted.

4 changes: 2 additions & 2 deletions .github/workflows/additional-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ name: additional checks

on:
push:
branches: [ main ]
branches: [ main, dev ]
pull_request:
branches: [ main ]
branches: [ main, dev ]
workflow_dispatch:

jobs:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/code-quality.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ name: Code Quality

on:
push:
branches: [ main ]
branches: [ main, dev ]
pull_request:
branches: [ main ]
branches: [ main, dev ]
workflow_dispatch:

env:
Expand Down Expand Up @@ -41,4 +41,4 @@ jobs:
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- name: Clippy check
run: cargo clippy --all-features --workspace -- -D warnings
run: cargo clippy --features "server,cli,fjall" --workspace -- -D warnings
4 changes: 2 additions & 2 deletions .github/workflows/platform-coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: Platform & Coverage

on:
push:
branches: [ main ]
branches: [ main, dev ]
pull_request:
branches: [ main ]
branches: [ main, dev ]
workflow_dispatch:

env:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/publish-pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.target }}
args: --release --out dist --features python --interpreter python3.11
args: --release --out dist --no-default-features --features python --interpreter python3.11
sccache: 'true'
manylinux: auto
- name: Upload wheels
Expand All @@ -47,7 +47,7 @@ jobs:
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.target }}
args: --release --out dist --features python
args: --release --out dist --no-default-features --features python
sccache: 'true'
- name: Upload wheels
uses: actions/upload-artifact@v4
Expand All @@ -65,7 +65,7 @@ jobs:
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
args: --release --out dist --features python
args: --release --out dist --no-default-features --features python
sccache: 'true'
- name: Upload wheels
uses: actions/upload-artifact@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
- name: Build Python extension
run: |
source .venv/bin/activate
maturin develop --features python
maturin develop --no-default-features --features python

- name: Run Python tests
run: |
Expand Down
40 changes: 9 additions & 31 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,40 +2,18 @@ name: Tests

on:
push:
branches: [ main ]
branches: [ main, dev ]
pull_request:
branches: [ main ]
branches: [ main, dev ]
workflow_dispatch:

env:
CARGO_TERM_COLOR: always
REDIS_URI: redis://localhost:6379/15
MONGODB_URI: mongodb://localhost:27017/testdb


jobs:
test:
name: Test Suite
runs-on: ubuntu-latest
services:
redis:
image: redis
ports:
- 6379:6379
options: >-
--health-cmd "redis-cli ping"
--health-interval 10s
--health-timeout 5s
--health-retries 5
mongodb:
image: mongo:6
ports:
- 27017:27017
options: >-
--health-cmd "mongosh --eval 'db.runCommand(\"ping\").ok'"
--health-interval 10s
--health-timeout 5s
--health-retries 5

steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
Expand All @@ -48,12 +26,12 @@ jobs:
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}

- name: Cargo check
run: cargo check --all-features --workspace
run: cargo check --features "server,cli,fjall" --workspace

- name: Run unit tests
run: cargo test --lib --all-features --workspace
run: cargo test --lib --features "server,cli,fjall" --workspace

- name: Run integration tests
run: cargo test --test "*" --all-features --workspace
run: cargo test --test "*" --features "server,cli,fjall" --workspace
3 changes: 3 additions & 0 deletions .typos.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[default.extend-words]
fpr = "fpr"
FPR = "FPR"
Empty file added CHANGELOG.md
Empty file.
6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "probabilistic-rs"
version = "0.6.3"
version = "0.6.4"
edition = "2024"
authors = ["oiwn"]
description = "Probabilistic data structures in Rust"
Expand Down Expand Up @@ -64,13 +64,13 @@ features = ["fjall", "cli"]
all-features = false

[features]
default = ["server", "cli", "fjall"]
default = ["cli", "fjall"]
docs-only = ["cli", "fjall"]
fjall = ["dep:fjall", "dep:tokio"]
server = ["dep:axum", "dep:tokio", "dep:utoipa", "dep:utoipa-swagger-ui", "dep:serde_json", "dep:dotenvy", "fjall"]
cli = ["dep:clap", "dep:ratatui", "dep:unicode-width", "fjall"]
tests = []
python = ["dep:pyo3", "dep:tokio"]
python = ["dep:pyo3", "dep:tokio", "fjall"]

[package.metadata.docs]
features = ["cli", "fjall"] # Exclude "server" feature
Expand Down
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ Probabilistic data structures in Rust with Python bindings and HTTP API.
- **Python Bindings** — native wheels via PyO3/maturin
- **CLI + TUI** — interactive terminal interface

![TUI Screenshot](tui.png)

## Installation

**Rust:**
Expand Down
11 changes: 11 additions & 0 deletions prek.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
fail_fast = true

[[repos]]
repo = "local"
hooks = [
{ id = "fmt", name = "cargo fmt", language = "system", entry = "cargo fmt --check", types = ["rust"], pass_filenames = false },
{ id = "clippy", name = "cargo clippy", language = "system", entry = "cargo clippy --all-targets --all-features -- -D warnings", types = ["rust"], pass_filenames = false },
{ id = "test", name = "cargo test", language = "system", entry = "cargo test --all-features", types = ["rust"], pass_filenames = false },
{ id = "typos", name = "typos", language = "system", entry = "typos", pass_filenames = false },
{ id = "gitleaks", name = "gitleaks", language = "system", entry = "gitleaks git --verbose", pass_filenames = false },
]
Loading
Loading