JuliaLang / julia

The Julia Programming Language
https://julialang.org/
MIT License
45.32k stars 5.45k forks source link

Document to use nightly Julia to contribute to the standard library #54688

Open Paalon opened 2 months ago

Paalon commented 2 months ago

Original title: Fail tests of the standard libraries at calling Docs.undocumented_names even following the instructions

This is a half question and a half issue of Julia project. I posted this at Discourse, but I think it can be a issue of Julia project, I filed. I want to edit and test a standard library and followed the instructions on CONTRIBUTING.md:

https://github.com/JuliaLang/julia/blob/b8a058a8738eca514fea71173d70552508767063/CONTRIBUTING.md?plain=1#L259-L275

but the test fails at calling Docs.undocumented_names with the following error:

Docstrings: Error During Test at /Users/paalon/git/julia/stdlib/Unicode/test/runtests.jl:550
  Test threw exception
  Expression: isempty(Docs.undocumented_names(Unicode))
  UndefVarError: `undocumented_names` not defined
  Stacktrace:
   [1] getproperty(x::Module, f::Symbol)
     @ Base ./Base.jl:31
   [2] macro expansion
     @ ~/.julia/juliaup/julia-1.10.4+0.x64.apple.darwin14/share/julia/stdlib/v1.10/Test/src/Test.jl:669 [inlined]
   [3] macro expansion
     @ ~/git/julia/stdlib/Unicode/test/runtests.jl:550 [inlined]
   [4] macro expansion
     @ ~/.julia/juliaup/julia-1.10.4+0.x64.apple.darwin14/share/julia/stdlib/v1.10/Test/src/Test.jl:1577 [inlined]
   [5] top-level scope
     @ ~/git/julia/stdlib/Unicode/test/runtests.jl:550
Test Summary: | Error  Total  Time
Docstrings    |     1      1  1.1s
ERROR: LoadError: Some tests did not pass: 0 passed, 0 failed, 1 errored, 0 broken.
in expression starting at /Users/paalon/git/julia/stdlib/Unicode/test/runtests.jl:549
ERROR: Package Unicode errored during testing

How to solve it?

Paalon commented 2 months ago

Ok, I noticed. The stdlib uses 1.11 functions so I need to test them in nightly Julia.

Paalon commented 2 months ago

This should be documented.