JuliaDocs/Documenter.jl

Doctests not catching exceptions from show

Open

#1.631 aberto em 6 de jul. de 2021

Ver no GitHub
 (0 comments) (0 reactions) (0 assignees)Julia (513 forks)batch import
Topic: UsabilityType: Bughelp wanted

Métricas do repositório

Stars
 (910 stars)
Métricas de merge de PR
 (Mesclagem média 16d 9h) (3 fundiu PRs em 30d)

Description

This type of doctest, where show throws an error, does not work currently:

julia> gd
Error showing value of type GroupedDataFrame{DataFrame}:
ERROR: AssertionError: The current number of rows in the parent data frame is 3 and it does not match the number of rows it contained when GroupedDataFrame was created which was 2. The number of rows in the parent data frame has likely been changed unintentionally (e.g. using subset!, filter!, delete!, push!, or append! functions).

I believe it's because Documenter does not handle exceptions from the show calls which happen here: https://github.com/JuliaDocs/Documenter.jl/blob/6c8679bac445ab1c656744075b13a57835081cc3/src/DocTests.jl#L319

X-ref https://github.com/JuliaData/DataFrames.jl/pull/2811

Guia do colaborador