chore!: make update public rather than exported#243
Open
seabbs-bot wants to merge 1 commit into
Open
Conversation
Several ecosystem packages (and plenty outside it) have their own update-shaped verb; exporting a name this generic risks the same ambiguous-binding clash #233 hit with as_turing when two packages both export a same-named generic function. Reach it as ComposedDistributions.update or `using ComposedDistributions: update`. Fixes the ~150 call sites across the test suite and docs that relied on the implicit export to call update unqualified. Co-authored-by: Sam Abbott <contact@samabbott.co.uk>
Contributor
Try this Pull Request!Option 1: Julia Package ManagerOpen Julia and type: import Pkg
Pkg.activate(temp=true)
Pkg.add(url="https://github.com/EpiAware/ComposedDistributions.jl", rev="chore/update-export-to-public-221")
using ComposedDistributionsOption 2: Local CheckoutIf you have the repo locally: git checkout chore/update-export-to-public-221
julia --project=. -e "using Pkg; Pkg.instantiate()" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
First half of #221:
updatemoves fromexporttopublic.Several ecosystem packages (and plenty outside it) have their own
update-shaped verb. Exporting a name this generic risks the same ambiguous-binding clash #233 hit withas_turing, where two packages both exporting a same-named generic function makes the bare name unresolvable when both are loaded together.public.jlalready carries this pattern for several other names (flat_dimension,reconstruct,params_table, ...);updatefits the same shape.A caller now reaches it as
ComposedDistributions.update(...)orusing ComposedDistributions: update.Blast radius
updateis this package's single most heavily used verb — about 150 call sites across 18 files (test suite + doc tutorials) relied on the implicit export to call it unqualified inside a@testitem/tutorial script (TestItemRunner auto-usings the tested package per item, which only brings in exported names, notpublicones). Fixed all of them: added an explicitusing ComposedDistributions: updateto each affected testitem/script.One real build failure caught by running
docs, not by inspection:docs/src/getting-started/index.mdhas a genuinely executable@example overviewblock using bareupdate(...)(unlike most of the other affected doc pages, whereupdateonly appears in prose/tables/non-executed ```julia blocks) — fixed by adding the import to that block'susingline.The remaining
[update](@ref)cross-reference warnings across several doc pages are cosmetic (not build-breaking) and match a pre-existing pattern already tolerated in this repo for otherpublic-not-exported names (flat_dimension,as_logdensity,logdensity,to_constrained,flatten,unflattenare already in the same "no docstring found forMain.X" state onmain, confirmed by diffing against a pristine checkout) — not something this PR need chase further.Test plan
task test-fast: 1625/1625 passtask test-quality: 228/241 pass, 13 broken (pre-existing expected-broken tests, unrelated)task docs-fast: builds clean (was failing on theindex.mdexecutable block before the fix above)NEWS.md carries the breaking-change note.
This was opened by a bot. Please ping @seabbs for any questions.