JuliaStats / Statistics.jl

The Statistics stdlib that ships with Julia.
https://juliastats.org/Statistics.jl/dev/
Other
71 stars 40 forks source link

Prepare standalone package, step 2 #128

Closed nalimilan closed 1 year ago

nalimilan commented 1 year ago

mean and mean! are now defined in Base.

Tests will fail until https://github.com/JuliaLang/julia/pull/46501 is merged.

nalimilan commented 1 year ago

Given that we have a chicken-and-egg problem to get CI to pass in Statistics.jl and in Julia, I've restored definitions for mean and mean!, making them conditional on isdefined(Base, :mean). That way we can merge this here with CI passing, and then update https://github.com/JuliaLang/julia/pull/46501 to use the latest Statistics.jl and CI should pass there too. Then we can drop function definitions. OK?

nalimilan commented 1 year ago

I also dropped mean and mean! from the manual as that causes the Julia build to fail due to duplicate inclusion of docstrings.

ararslan commented 1 year ago

mean and mean! are now defined in Base.

Big if true 😜

I also dropped mean and mean! from the manual as that causes the Julia build to fail due to duplicate inclusion of docstrings.

Documenter complains about having the same docstring twice? I guess that makes sense since in most cases that's probably user error. Unfortunate that they need to be removed though because of that though. So in the period between the merging of this and merging the linked Julia PR, mean(!) won't appear in any manual builds?

nalimilan commented 1 year ago

Documenter complains about having the same docstring twice? I guess that makes sense since in most cases that's probably user error. Unfortunate that they need to be removed though because of that though. So in the period between the merging of this and merging the linked Julia PR, mean(!) won't appear in any manual builds?

No, because the master branch of Statistics will only be used after merging the Julia PR. Any changes made here will have zero effect on users as long as we don't bump the commit in Julia.

codecov-commenter commented 1 year ago

Codecov Report

Patch coverage: 88.09% and project coverage change: +0.01% :tada:

Comparison is base (bb7063d) 96.98% compared to head (0f9ea53) 96.99%. Report is 1 commits behind head on master.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #128 +/- ## ========================================== + Coverage 96.98% 96.99% +0.01% ========================================== Files 1 1 Lines 431 433 +2 ========================================== + Hits 418 420 +2 Misses 13 13 ``` | [Files Changed](https://app.codecov.io/gh/JuliaStats/Statistics.jl/pull/128?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaStats) | Coverage Δ | | |---|---|---| | [src/Statistics.jl](https://app.codecov.io/gh/JuliaStats/Statistics.jl/pull/128?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=JuliaStats#diff-c3JjL1N0YXRpc3RpY3Muamw=) | `96.99% <88.09%> (+0.01%)` | :arrow_up: |

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

nalimilan commented 1 year ago

Actually given that Statistics will remain an stdlib (at least for now), and simply become upgradable, mean isn't going to move to Base so this PR isn't needed anymore. https://github.com/JuliaStats/Statistics.jl/pull/148 reverts it.