Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Epic: Improve Graph Read/Write Error Detection and Reporting #37

Open
5 tasks
john-boyer-phd opened this issue Mar 25, 2024 · 0 comments
Open
5 tasks
Labels

Comments

@john-boyer-phd
Copy link
Collaborator

john-boyer-phd commented Mar 25, 2024

There are several improvements that can be made throughout the graphIO.c code:

  • All instances of return NOTOK and RetVal = NOTOK should be preceded with an explanatory ErrorMessage() to indicate what has gone wrong, in keeping with the level of information now provide by the new "graph6"reader. For example, there should be an error message in _ReadAdjList() that indicates loop edges are not supported.
  • The adjacency matrix reader should be amended to detect the failure of fscanf() and sscanf() as well as successful reading of integer values other than 0 and 1, and provide an appropriate ErrorMessage() and return NOTOK when such events occur.
  • Amend ReadAdjList() and _ReadLEDAGraph() to efficiently detect and report an error and return NOTOK if multiple edges are detected
  • Amend the LEDA graph format reader to detect a loop edge and report an error and return NOTOK
  • Amend _WriteAdjMatrix() and the new "graph6" writer to report an error and return NOTOK if the graph being written is a digraph.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant