Skip to content

API review: widen annotations, rename prepare_mm_package, expose parallel keyword, bump to v1.0.1#27

Merged
kdw503 merged 4 commits into
masterfrom
dwk/mng
May 14, 2026
Merged

API review: widen annotations, rename prepare_mm_package, expose parallel keyword, bump to v1.0.1#27
kdw503 merged 4 commits into
masterfrom
dwk/mng

Conversation

@kdw503
Copy link
Copy Markdown
Member

@kdw503 kdw503 commented May 14, 2026

Summary

  • Widen type annotations: VectorAbstractVector and DictAbstractDict across all driver and prepare_mm_package signatures, allowing sparse, GPU, ordered, and other subtypes without MethodError.
  • Rename mm_package_loaderprepare_mm_package (breaking): aligns with Julia's verb-first naming convention; the old name collided with the imported RegisterWorkerShell.load_mm_package, so prepare_mm_package was chosen as the non-colliding target. No deprecation shim (clean break per project policy).
  • Expose parallel keyword on driver method 1: parallel::Bool = length(algorithms) > 2 makes the threading threshold explicit. The default preserves existing behaviour exactly.
  • Bump to v1.0.1 and tighten RegisterCore/RegisterWorkerShell compat from "0.2, 1""1" (vestigial 0.2 entries removed).

Test plan

  • Existing test suite passes (Doctests, Aqua, ExplicitImports green; pre-existing flaky runtests.jl:88 is unrelated to these changes)
  • New @testset "parallel keyword" exercises parallel=false and parallel=true branches
  • grep confirms zero remaining references to mm_package_loader in source and docs
  • Project.toml shows version = "1.0.1"
  • After merge: request registration via @JuliaRegistrator register on the merge commit

🤖 Generated with Claude Code

kdw503 and others added 4 commits May 14, 2026 15:18
`driver` and `mm_package_loader` now accept any AbstractVector (not just
Vector) and any AbstractDict (not just Dict), matching Base's convention
of annotating with the abstract type the implementation can actually handle.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
`load_mm_package` (the originally planned target) collides with the same-named
symbol imported from RegisterWorkerShell, which is the function the wrapper
delegates to. `prepare_mm_package` is verb-first, non-colliding, and reads
naturally for its role: prepare the device-specific mismatch backend before
calling `driver`.

No deprecation shim per stated values (clean break).

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Add `parallel::Bool = length(algorithms) > 2` to `driver`'s multi-worker
signature, making the threading threshold explicitly configurable. The
default preserves existing dispatch exactly. Add a four-case testset
covering both branches.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Release all API-review improvements as v1.0.1. Also narrow RegisterCore
and RegisterWorkerShell compat from "0.2, 1" → "1"; the package has
required 1.x semantics since v1.0.0 and the 0.2 entries were vestigial.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@codecov
Copy link
Copy Markdown

codecov Bot commented May 14, 2026

Codecov Report

❌ Patch coverage is 71.42857% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 91.74%. Comparing base (31303c0) to head (a762366).

Files with missing lines Patch % Lines
src/RegisterDriver.jl 71.42% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master      #27      +/-   ##
==========================================
+ Coverage   91.26%   91.74%   +0.48%     
==========================================
  Files           1        1              
  Lines         103      109       +6     
==========================================
+ Hits           94      100       +6     
  Misses          9        9              

☔ View full report in Codecov by Sentry.
📢 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.

@kdw503 kdw503 merged commit 37b7a6b into master May 14, 2026
4 of 5 checks passed
@kdw503 kdw503 deleted the dwk/mng branch May 14, 2026 21:08
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.

1 participant