This repository was archived by the owner on Jun 18, 2026. It is now read-only.
Commit 0d5b44d
committed
fix: ensure edge-only vertices are tracked in ParseResult.getVertices()
When vertices appear only in edge lines (not in the 'nodes' section),
they were added to the JUNG graph by addEdge() but missing from
ParseResult.getVertices(). This caused inconsistencies where
graph.getVertexCount() != result.getVertices().size(), breaking
downstream code that relies on the vertex set for iteration, metrics,
or export.
Now edge endpoints are explicitly added to both the vertex set and
the graph before edge insertion, ensuring consistency regardless of
whether vertices are declared in the nodes section.1 parent 29802be commit 0d5b44d
1 file changed
Lines changed: 5 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
164 | 164 | | |
165 | 165 | | |
166 | 166 | | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
167 | 172 | | |
168 | 173 | | |
169 | 174 | | |
| |||
0 commit comments