scalableminds / webknossos

Visualize, share and annotate your large 3D images online
https://webknossos.org
GNU Affero General Public License v3.0
123 stars 18 forks source link

Add SQL Syntax Checker #7777

Open fm3 opened 2 months ago

fm3 commented 2 months ago

Can we feed our scala sources into a tool like pgsanity or plpgsql lint to find some issues without actually executing the queries?

Hurdles:

MichaelBuessemeyer commented 1 month ago

My 5ct:

Parsing and looking for q"" should be possible with tree-sitter which also has scala support. Tree sitter makes it easily possible to query a file for q""-strings and from there we should be able to

  1. put it into a validator against our schema
  2. format the query string to support unified query string formatting