apache / apache/pekko

graphviz errors in scaladocs for 2.12

Open
#1,129 1 comment 0 reactions 0 assignees View on GitHub
bug
Dominant language
Scala
Stars
1.6k
Forks
211
Avg merge
1d 6h
Merged PRs (30d)
89

Description

graphviz produces errors during the generation of embedded svgs in the 2.12 scaladocs.

you can reproduce this with e.g. `sbt ++2.12 persistence-tck/doc`.

diagnosing by adding `-diagrams-debug` to the scaladoc options in `project/Doc.scala`, we get some more diagnostics:

```
model contains 36 documentable templates

**********************************************************************
The graphviz dot diagram tool has malfunctioned and will be restarted.

The following is the log of the failure:
DOT : malloc_consolidate(): unaligned fastbin chunk detected

Cleanup: Last template: org.apache.pekko.persistence.journal.JournalPerfSpec
Cleanup: Last dot input:
digraph G {
compound="true";
rankdir="TB";
node [margin="0.08,0.01", fontsize="8.00", style="filled,rounded", height="0.0", penwidth="1", shape="rect", width="0.0", fontname="Source Code Pro"];
edge [arrowsize="0.7", fontcolor="#aaaaaa", fontsize="9.00", color="#d4d4d4", fontname="Source Code Pro"];
subgraph clusterAll {
style="invis"
subgraph clusterOutgoing {
style="invis"
node6 [label=<scalatest.matchers.should.Matchers.Equalizer[JournalPerfSpec] >,fontcolor="#7d7d7d", color="#ababab", id="implicit-outgoing class|graph1_6", fillcolor="#e1e1e1", tooltip="org.apache.pekko.persistence.journal.JournalPerfSpec can be implicitly converted to scalatest.matchers.should.Matchers.Equalizer[JournalPerfSpec] by the implicit method convertToEqualizer in trait org.scalactic.TripleEquals"];
node5 [label=<scalatest.matchers.should.Matchers.AnyShouldWrapper[JournalPerfSpec] >,fontcolor="#7d7d7d", color="#ababab", id="implicit-outgoing class|graph1_5", fillcolor="#e1e1e1", tooltip="org.apache.pekko.persistence.journal.JournalPerfSpec can be implicitly converted to scalatest.matchers.should.Matchers.AnyShouldWrapper[JournalPerfSpec] by the implicit method convertToAnyShouldWrapper in trait org.scalatest.matchers.should.Matchers"];
node4 [label=<scalactic.TripleEquals.Equalizer[JournalPerfSpec] >,fontcolor="#7d7d7d", color="#ababab", id="implicit-outgoing class|graph1_4", fillcolor="#e1e1e1", tooltip="org.apache.pekko.persistence.journal.JournalPerfSpec can be implicitly converted to scalactic.TripleEquals.Equalizer[JournalPerfSpec] by the implicit method convertToEqualizer in trait org.scalactic.TripleEquals"];
node3 [label=<scalatest.Assertions.Equalizer[JournalPerfSpec] >,fontcolor="#7d7d7d", color="#ababab", id="implicit-outgoing class|graph1_3", fillcolor="#e1e1e1", tooltip="org.apache.pekko.persistence.journal.JournalPerfSpec can be implicitly converted to scalatest.Assertions.Equalizer[JournalPerfSpec] by the implicit method convertToEqualizer in trait org.scalactic.TripleEquals"];
node3 -> node4 -> node5 -> node6 [constraint="false", style="invis", minlen="0.0"];
}
subgraph clusterThis {
style="invis"
node0 [label=<JournalPerfSpec >,fontcolor="#ffffff", URL="#inheritance-diagram", color="#418565", id="this class|graph1_0", fillcolor="#418565", tooltip="org.apache.pekko.persistence.journal.JournalPerfSpec (this class)"];
}

node0 -> node3 [id="implicit-outgoing|0_3", tooltip="JournalPerfSpec can be implicitly converted to scalatest.Assertions.Equalizer[JournalPerfSpec], scalactic.TripleEquals.Equalizer[JournalPerfSpec], scalatest.matchers.should.Matchers.AnyShouldWrapper[JournalPerfSpec], scalatest.matchers.should.Matchers.Equalizer[JournalPerfSpec]", constraint="false", minlen="2", ltail="clusterThis", lhead="clusterOutgoing", label="implicitly"];
}
node1 [label=<JavaJournalPerfSpec >,fontcolor="#ffffff", URL="../japi/journal/JavaJournalPerfSpec.html#inheritance-diagram", color="#418565", id="class|graph1_1", fillcolor="#418565", tooltip="org.apache.pekko.persistence.japi.journal.JavaJournalPerfSpec"];
node2 [label=<JournalSpec >,fontcolor="#ffffff", URL="JournalSpec.html#inheritance-diagram", color="#418565", id="class|graph1_2", fillcolor="#418565", tooltip="org.apache.pekko.persistence.journal.JournalSpec"];
node2 -> node0 [id="inheritance|graph1_2_0", tooltip="JournalPerfSpec is a subtype of JournalSpec", dir="back", arrowtail="empty"];
node0 -> node1 [id="inheritance|graph1_0_1", tooltip="JavaJournalPerfSpec is a subtype of JournalPerfSpec", dir="back", arrowtail="empty"];
}

Cleanup: Dot path: dot
Cleanup: Dot exit code: 134
**********************************************************************
Graphviz will be restarted...

Diagram generation running time breakdown:

diagrams model filtering
========================
count: 72 items
total time: 0 ms
average time: 0 ms
maximum time: 0 ms

diagrams model generation
=========================
count: 72 items
total time: 10 ms
average time: 0 ms
maximum time: 2 ms

dot diagram generation
======================
count: 21 items
total time: 6 ms
average time: 0 ms
maximum time: 1 ms

dot process running
===================
count: 21 items
total time: 387 ms
average time: 18 ms
maximum time: 277 ms

svg processing
==============
count: 21 items
total time: 81 ms
average time: 3 ms
maximum time: 28 ms

Broken images: 94
Fixed images: 0

```

I'm using graphviz 9.0.0, and passing that graph to dot manually works fine. Also 2.13 docs appear to be fine.

Perhaps we should just disable scaladoc diagrams for 2.12?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.