Skip to content

chore(series): Apply the review nits of the vendoring series - #2992

Draft
krlmlr wants to merge 6 commits into
claude/f1-leiden-directedfrom
claude/f-nits
Draft

krlmlr wants to merge 6 commits into
claude/f1-leiden-directedfrom
claude/f-nits

Conversation

@krlmlr

@krlmlr krlmlr commented Oct 18, 2026 •

Copy link
Copy Markdown
Contributor

Commit dcfe7b3 (eigen_centrality() stress test) moves to main in #2997.

Draft, do not merge: review vehicle for a fix collected for the series rebuild on main-fwd-build. Merging would move the main-green mirror, which the series loop owns.

This is the third of three stacked review vehicles. It is based on claude/f1-leiden-directed (#2991), which is itself based on claude/f2-lad-time-limit (#2990). It was rebased onto the rebased claude/f1-leiden-directed without conflicts, so its diff shows only the nits.

What it changes

The branch carries six commits, one per review nit.

  • cluster_edge_betweenness() now raises the weighted-run warnings from R with cli::cli_warn() instead of from the glue with IGRAPH_WARNING(), which reported the glue file and line as their source. As in igraph 0.10, only the first warning is raised, and the typo "betwenness" is fixed.
  • The six *_dijkstra_impl() aliases are removed, because upstream merged the weighted _dijkstra variants into the base functions and nothing in the package calls them. The generated-interface tests in test-aaa-auto.R that called four of them now call the base functions, and the one duplicating pseudo_diameter_impl() is gone.
  • The stale igraph_rewire mode default is dropped from the Stimulus functions-R.yaml, since igraph_rewire() no longer has a mode parameter. Regenerating the interface leaves its output byte-identical.
  • The redundant igraph_personalized_pagerank_vs DEPS override is dropped from the same file, since upstream's functions.yaml declares the same dependencies. Regenerating the interface leaves its output byte-identical.
  • hits_scores(scale) carries the superseded badge in its documentation and says what FALSE still does, matching the lifecycle signal the function already raises.
  • The eigen_centrality() stress test expects the near-zero warning on disconnected random graphs and muffles only that warning, instead of emitting hundreds of warnings on a passing test.

Proposed correction for series commit a7a553a

This is not a commit on this branch. The subsession that made these nits proposed the following corrected message for series commit a7a553a:

R-side fix: upstream renames the vertex_weights argument of igraph_community_leiden() to vertex_out_weights and adds vertex_in_weights, which must be NULL for undirected graphs. Its override keeps the R name vertex_weights and always passes NULL in-weights, so the arguments of community_leiden_impl() and cluster_leiden() are unchanged. Upstream also drops the error for directed graphs, so cluster_leiden() now runs on a directed graph instead of failing.

Note that PR 2991 (#2991, the cluster_leiden() fix) reverses that last sentence: with it, cluster_leiden() rejects directed graphs again. The rebuild must therefore either adjust the last sentence or fold that fix into this commit.

Tests

The package was built and installed from this branch tip, which includes both branches below it, into a scratch library, and the test files touched by the three branches were run against the installed package with NOT_CRAN=true. All have 0 failures and 0 errors.

  • test-aaa-auto.R: 712 tests, 1313 expectations, 0 skips, 1 warning (from the hub_and_authority_scores_impl basic test).
  • test-centrality.R: 44 tests, 2904 expectations, 0 skips.
  • test-community.R: 37 tests, 355 expectations, 0 skips.
  • test-topology.R: 45 tests, 626 expectations, 1 skip (an existing FIXME about errors in the callback being gobbled).

air format --check is clean on all changed R files.

Provenance

Made by a Claude subsession: https://claude.ai/code/session_01L5n6BLiYoPmk3NFiYDSKZZ


Generated by Claude Code

The C core no longer warns about weighted edge betweenness runs,
so the glue re-added the igraph 0.10 warnings with `IGRAPH_WARNING()`,
which reported the glue file and line as their source.
`cluster_edge_betweenness()` now raises them,
the first one only, as igraph 0.10 did through the warning handler.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01L5n6BLiYoPmk3NFiYDSKZZ
Upstream merged the weighted `_dijkstra` variants into the base functions,
and nothing in the package calls the six aliases kept for their names.
The generated-interface tests that called four of them now call the base functions,
and the one duplicating `pseudo_diameter_impl()` is gone.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01L5n6BLiYoPmk3NFiYDSKZZ
`igraph_rewire()` no longer has a `mode` parameter,
so its R default in `functions-R.yaml` named nothing.
Regenerating the interface leaves its output unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01L5n6BLiYoPmk3NFiYDSKZZ
…ride

Upstream's `functions.yaml` declares the same dependencies,
so the override in `functions-R.yaml` changes nothing.
Regenerating the interface leaves its output unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01L5n6BLiYoPmk3NFiYDSKZZ
`hits_scores()` signals `scale = FALSE` as superseded,
because the C core now always scales the largest scores to one,
but its documentation still described `scale` as a plain argument.
It now carries the superseded badge and says what `FALSE` still does.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01L5n6BLiYoPmk3NFiYDSKZZ
…s test

Most random graphs in the stress test are disconnected,
so `eigen_centrality()` warns that some centralities are nearly zero,
which emitted hundreds of warnings on a passing test.
The test now checks that only this warning occurs and muffles it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01L5n6BLiYoPmk3NFiYDSKZZ

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants