Skip to content

fix: fix reading of LGL and NCOL files (broken in 2.0.0)#1347

Merged
aviator-app[bot] merged 4 commits intomainfrom
fix/ncol-lgl
May 23, 2024
Merged

fix: fix reading of LGL and NCOL files (broken in 2.0.0)#1347
aviator-app[bot] merged 4 commits intomainfrom
fix/ncol-lgl

Conversation

@szhorvat
Copy link
Copy Markdown
Member

Fixes #1346

I'm sorry, I really don't have time for a test, but I hope someone can add one based on my first comment in #1346.

@aviator-app
Copy link
Copy Markdown
Contributor

aviator-app bot commented Apr 20, 2024

Current Aviator status

Aviator will automatically update this comment as the status of the PR changes.
Comment /aviator refresh to force Aviator to re-examine your PR (or learn about other /aviator commands).

This PR was merged using Aviator.


See the real-time status of this PR on the Aviator webapp.
Use the Aviator Chrome Extension to see the status of your PR within GitHub.

@knwng
Copy link
Copy Markdown
Contributor

knwng commented Apr 22, 2024

Tried to add unittest for the change in #1348. I'm new to R, so please let me know if there's anything not following common practices.

@szhorvat
Copy link
Copy Markdown
Member Author

@krlmlr @Antonov548 One of the CI issues seems to be that GLPK is not found in the macOS image, so it uses the vendored GLPK.

ncol_path <- tempfile("testfile", fileext = ".ncol")
g <- make_graph(c(1, 2, 2, 3))
write_graph(g, ncol_path, "ncol")
expect_no_error(g2 <- read_graph(ncol_path, "ncol"))
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we want to know more than no error?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is good to merge, and the fix should be released ASAP (I'd consider this a very serious bug).

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we want to know more than no error?

I supposed g and g2 are identical at the beginning, but they are not. The graphs have the same structures but there's some difference in properties. So I replaced expect_true(identical_graphs(g, g2)) with expect_no_error to meet the minimum requirement. If that's not expected, there should be other changes after thorough inspection.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NCOL will always treat vertex "identifiers" as strings, not numerical vertex IDs, so a difference there is expected.

@szhorvat szhorvat mentioned this pull request May 6, 2024
@maelle maelle requested a review from krlmlr May 7, 2024 07:31
Copy link
Copy Markdown
Contributor

@krlmlr krlmlr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does CI/CD fail?

@szhorvat
Copy link
Copy Markdown
Member Author

Let me know if there's anything else that you need from me here (it seems to me this is good to go).

@krlmlr
Copy link
Copy Markdown
Contributor

krlmlr commented May 23, 2024

Thanks!

@aviator-app aviator-app bot added the blocked label May 23, 2024
@aviator-app
Copy link
Copy Markdown
Contributor

aviator-app bot commented May 23, 2024

This pull request failed to merge: PR cannot be automatically rebased, please rebase manually to continue. Once the issues are resolved, remove the blocked label and re-queue the pull request. Note that the pull request will be automatically re-queued if it has the mergequeue label.

Additional debug info: Failed to rebase this PR onto the latest changes from the base branch. You will probably need to rebase this PR manually and resolve conflicts).

@szhorvat szhorvat removed the blocked label May 23, 2024
@aviator-app aviator-app bot merged commit 3a46d60 into main May 23, 2024
@aviator-app aviator-app bot deleted the fix/ncol-lgl branch May 23, 2024 11:08
@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 24, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Failed to load graph using read.graph.ncol

4 participants