-
Notifications
You must be signed in to change notification settings - Fork 12
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
Integrate misti static analyzer #92
Comments
@anton-trunov I think it would be better to display the analysis directly in the editor, similar to how ESLint works in VSCode, and also during the contract pre-build (with an option to enable it in the settings). |
Sure, that works. Just keep in mind that sometimes the analysis can take a lot of time to finish (it's not incremental), so we need also some kind of indication that Misti is working in the background. |
@rahulyadav-57 Two questions on this:
|
We can pass the configuration file without any issues, as we have a virtual file system in place. The IDE is just a static build and doesn't require any API, as everything is built and stored in the browser. Is there another option we can consider without using Souffle? |
Not really. Some of the detectors won't be available without it. We could consider compiling Souffle to WASM as an ultimate hack, but it will be a PITA to maintain it. |
Could you check it once if we can use any JavaScript alternative for Souffle? |
We cannot. Misti uses specific features to leverage the Souffle Datalog variant. It should not be changed, as we use a code generator for that Datalog variant, and this logic must remain unchanged. |
@anton-trunov I won't be able to integrate it with the Web IDE due to the dependency on |
Actually, we have three possible solutions for this issue:
|
We can start with the third option and then explore the first one. For instance, we cannot expect the IDE to support running Soufflé for free during programming contests (we expect at least thousands of participants) as this can be used to DDoS us. So, let's postpone the second option until we can collaborate with the devops team on this. |
@rahulyadav-57 here is the suggested implementation on how to integrate Misti using its API:
See the implementation of The output format for warnings is a subject of change: nowarp/misti#159. |
Thanks @jubnzv for the resources. Today, I was reviewing the codebase of Here are a couple of points I noticed that might need changes:
I'll explore these further this week, try to run it, and share a finalized list of the required changes. |
Yes, we could definitely extend Misti's functionality, especially the aspects related to the virtual file system you mentioned. Please create issues in the Misti repository. |
https://github.com/nowarp/misti
I would imagine it could be a new button on the left bar, somewhere near the Build button.
The text was updated successfully, but these errors were encountered: