Documenter error when specifying type signatures

Hi,

I am attempting to use Documenter and DocumenterVitepress and running into several errors when attempting to filter included docstrings.

A simple function in the module I am attempting to document is defined as

"""
    unitize(x::Number) -> Quantity ...
"""
function unitize(x::Number) ...

This generates documention

```
@docs
unitize
```

but this does not

```
@docs
unitize(::Number)
```

Instead, I get a duplicate docs error

**Error:** duplicate docs found for unitize(::Number) in @docs block
**ERROR:** LoadError: makedocs encountered an error \[:docs_block\] -- terminating build before rendering.

The full stack trace is shown below.

I’m not using autodocs, nor do I have unitize(::Number) documented elsewhere, so I’m quite puzzled by this.

Because I’m unable to filter on any type signatures, I can’t separate documentation for more complicated functions that have multiple methods.

This gives a different error

```
@docs
unitize(x)
```

**Error:** no docs found for unitize(x) in @docs block in src/reductions.md:11-14

Relatedly, I am unable to ascertain from the documentation what the (x) does in the above. Even without a type signature, documenting unitize and unitize(x) behave differently but I don’t understand why.

Any help would be greatly appreciated.


Stacktrace:

  \[1\] **error**(s::String)

  @ Base ./error.jl:44

  \[2\] **runner(**::Type{Documenter.Builder.RenderDocument}, doc::Documenter.Document)

  @ Documenter \~/.julia/packages/Documenter/eCrmY/src/builder_pipeline.jl:259

  \[3\] **dispatch(**::Type{Documenter.Builder.DocumentPipeline}, x::Documenter.Document)

  @ Documenter.Selectors \~/.julia/packages/Documenter/eCrmY/src/utilities/Selectors.jl:170

  \[4\] **#105**

  @ \~/.julia/packages/Documenter/eCrmY/src/makedocs.jl:283 \[inlined\]

  \[5\] **withenv(**::Documenter.var"#105#106"{Documenter.Document}, ::Pair{String, Nothing}, ::Vararg{Pair{String, Nothing}}**)**

  @ Base ./env.jl:273

  \[6\] **#103**

  @ \~/.julia/packages/Documenter/eCrmY/src/makedocs.jl:282 \[inlined\]

  \[7\] **cd**(f::Documenter.var"#103#104"{Documenter.Document}, dir::String)

  @ Base.Filesystem ./file.jl:112

  \[8\] **makedocs(**; debug::Bool, format::MarkdownVitepress, kwargs::@Kwargs{…}**)**

  @ Documenter \~/.julia/packages/Documenter/eCrmY/src/makedocs.jl:281

  \[9\] top-level scope

  @ \~/Desktop/Dropbox/Julia/Flare.jl/docs/make.jl:68

\[10\] **include**(mapexpr::Function, mod::Module, \_path::String)

  @ Base ./Base.jl:310

\[11\] top-level scope

  @ REPL\[1\]:1

Hello ! Could you share the complete repo that you tried to build the documentation ? It will be easier to help you. Also please use code block for code and stacktrace, like this:

"""
unitize(x::Number) → Quantity …
"""
function unitize(x::Number) …

it improves the readability. Also, is it expected that the character that you used for the triple quotation is “”" instead of """ ? I’m not sure Julia will parse them correctly…

Hi Franck,

Thanks for your reply. I’ve used the code blocks as requested. The quotes are """, they just became modified when because I didn’t use code blocks.

The repo is not public yet. I was hoping to sort out the documentation first. I will probably make it public before too long and then will come back with the link.