Skip to content

Conversation

@HerrEmil
Copy link
Contributor

@HerrEmil HerrEmil commented Aug 7, 2020

When the editor checks the current query with explain, the potential mistake of sending multiple statements in one query is not caught. Frontend has the info to flag this issue so this PR adds an extra check on editor update, and displays the warning as a warning triangle in the editor gutter.

multi statement warning

When clicking other warnings in the editor, an explain query is sent and the result displayed in a warning frame. Since this warning is caught in frontend, that query is skipped and a simple error frame with a message is displayed.

@HerrEmil HerrEmil requested a review from OskarDamkjaer August 7, 2020 12:16
@OskarDamkjaer
Copy link
Contributor

OskarDamkjaer commented Aug 7, 2020

Nice little video! I get this though..
image
It sticks even when I remove the query and clear the local storage.

I'll try to see if i can find what went wrong

@OskarDamkjaer
Copy link
Contributor

I think it'd be really nice if the warning went away automatically when the box got ticked, not sure if out of scope though :)

@HerrEmil
Copy link
Contributor Author

Nice little video! I get this though..
image
It sticks even when I remove the query and clear the local storage.

I'll try to see if i can find what went wrong

Thanks for flagging these, both were my bad and I've found how to fix them :)

@HerrEmil
Copy link
Contributor Author

I think it'd be really nice if the warning went away automatically when the box got ticked, not sure if out of scope though :)

I agree, I will try adding that

@HerrEmil HerrEmil merged commit b92abf3 into neo4j:master Aug 10, 2020
@HerrEmil HerrEmil deleted the multi-statement-warning branch August 10, 2020 15:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants