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
Part of or might close#804
Rather than coming up with perfect API that ties everything together,
let's start with the `Diagnostic` and iterate from there.
Instead of an
Error
type, I suggest moving toDiagnsotic
notation, popularized by Roslyn, TypeScript, VS Code, and others.Diagnostic::message() -> String
to return a human readable string, usable in editors and downstream APIs.Diagnostic::kind() -> DiagnosticKind
to return an enum:ParserError
,ValidationError
, etc...Diagnostic::code() -> String
the string represenatation ofDiagnosticKind
, suitable to surface in editors and URLs (error glossary/wiki).Diagnostic::severity() -> DiagnosticSeverity
to return an enum:Error
,Warning
,Info
, etc... (same as LSP severity levels)Diagnostic::location()
for file/range info.As for the errors API:
ariadne
reports from the API (should only be the CLI).FileNotFound
), instead of just panicking.The text was updated successfully, but these errors were encountered: