You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Allow write_graph(..., format = "gml") to use the GML writer's default vertex IDs when id is omitted. Fixes#2710.
Thanks to maintainers
Thanks for triaging the report, requesting a regression test, and reviewing the branch refresh.
Issue or motivation
Writing any graph as GML currently fails unless the caller supplies one ID per vertex. Earlier versions generated node IDs when none were supplied.
Root cause
Stimulus treated the C writer's nullable id pointer as a required vector. The generated R wrapper converted NULL to numeric(0), so C received an empty vector instead of a null pointer and rejected its length.
Change
Mark id as optional in the Stimulus metadata and regenerate both interface layers. The added test writes a graph without IDs and reads it back to confirm graph isomorphism.
Merged the current main branch into this PR branch as requested. The GML fix itself is unchanged.
Thanks to maintainers
Thanks for reviewing the fix and for the guidance on when to refresh the branch.
Issue or motivation
The branch was seven commits behind main, including the recent package-cleanup changes, so its CI result no longer represented the current repository state.
Root cause
The previous PR checks ran against the older base at acd63244. The branch needed the current main history before CI could reassess the patch.
Change
Merged igraph/rigraph@e772e9e7 without conflicts. Relative to current main, the PR still changes only the four original GML interface/test files.
Tests
air format .
focused test-foreign.R: four non-skipped tests passed; six CRAN-gated tests skipped
R CMD check --no-manual: tests and vignette rebuild passed; two existing vendored-GLPK warnings and one local rgl/X11 note remain
Scope
This update only syncs the PR with main. It does not alter the GML patch, workflows, vendored GLPK, or unrelated current-main CI failures.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Allow
write_graph(..., format = "gml")to use the GML writer's default vertex IDs whenidis omitted. Fixes #2710.Thanks to maintainers
Thanks for triaging the report, requesting a regression test, and reviewing the branch refresh.
Issue or motivation
Writing any graph as GML currently fails unless the caller supplies one ID per vertex. Earlier versions generated node IDs when none were supplied.
Root cause
Stimulus treated the C writer's nullable
idpointer as a required vector. The generated R wrapper convertedNULLtonumeric(0), so C received an empty vector instead of a null pointer and rejected its length.Change
Mark
idas optional in the Stimulus metadata and regenerate both interface layers. The added test writes a graph without IDs and reads it back to confirm graph isomorphism.Tests
air format --check .test-foreign.R: 13 passed, 0 failed, 0 warningsR CMD build: succeeded, including vignette creationR CMD check --no-manualon R 4.6.1: 0 errors; package tests and vignette rebuild passed; one existing warning comes from vendored GLPKrccis currentlyaction_required; the workflow created no jobs or logs and requires maintainer approval to runScope
Explicit IDs, other file formats, GML serialization details, and vendored C sources are unchanged.
I used AI assistance to help check for issues, refine the code, and run tests.
I'm fine with GPL 2 or later and FDL.