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

Add more well-formedness checks to the verifier #5993

Open
zrlk opened this issue Jan 18, 2024 · 3 comments
Open

Add more well-formedness checks to the verifier #5993

zrlk opened this issue Jan 18, 2024 · 3 comments
Assignees
Labels
verifier Issues with the Kythe verifier

Comments

@zrlk
Copy link
Contributor

zrlk commented Jan 18, 2024

We should add opt-in checks for things like

  • All vnames should have a corpus set (possibly modulo usrs)
  • No anchors are the targets of edges
  • Only known names are used (for edges, fact names, fact values)
  • ...

Some of these can be done during input ingestion (vnames/values); others can be datalog.

@zrlk zrlk added the verifier Issues with the Kythe verifier label Jan 18, 2024
@zrlk zrlk self-assigned this Jan 18, 2024
@zrlk
Copy link
Contributor Author

zrlk commented Feb 15, 2024

Another check: no diagnostic nodes emitted. If a diagnostic is emitted, the error report should contain information about it (message, details, anchor location, and so on).

@shahms
Copy link
Contributor

shahms commented Feb 16, 2024

Capturing thoughts from chat:

I think it's reasonable to "warn" on diagnostic nodes which don't match another goal, but I worry that failing on such nodes will just discourage their use. I can certainly imagine a indexer author seeing the node in the graph, emitting a relevant diagnostic, being surprised when confronted with a bunch of unexpected test failures, and changing the diagnostic into a log message instead.

Diagnostics are generally more visible than log messages and, when suitable, preferable.

@salguarnieri
Copy link
Contributor

I was thinking about the same idea (diagnostics sometimes being preferable to logs in the right situations) but then it was brought up that they end up in the graph so there is some cost to emitting them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
verifier Issues with the Kythe verifier
Projects
None yet
Development

No branches or pull requests

3 participants