-
Notifications
You must be signed in to change notification settings - Fork 785
fix: switching from_stderr to false
for solhint diagnostics
#811
fix: switching from_stderr to false
for solhint diagnostics
#811
Conversation
…r for messages to show up in the proper output buffer.
I won't have time to test this for a bit, but could it be due to a version incompatibility? I can see a scenario where upstream switched from |
Thanks for looking at this, and there's no rush - i've got it fixed locally via my branch. It's unclear to me why it stopped working, but I suspect that I did not commit the proper configuration in my original PR, and just didn't notice until now when i ran the linter manually in the console. My Feel free to verify & test locally before I mark it as ready for review. And thanks again! |
So I tested this out with a fresh install of |
Interesting, then there must be something wrong with my local configuration. Thanks for verifying this works as intended out the box with vanilla solhint. I'll close this PR for now & investigate my local configuration further. Thanks again! |
@ahashim I am also getting the same issue as you have. My Should we reopen this issue until we can figure out exactly what's going on? |
@DavideSilva thanks for verifying. Yes, I'll reopen the PR, but will not mark it as ready until we figure out the root cause of the regression. I currently don't have much bandwidth to investigate, but can create a demo solidity project to experiment with null-ls settings sometime this week. Appreciate you helping to triage the issue with @jose-elias-alvarez. |
I did some experimenting in a clean environment this morning to reproduce the bug, and here are my findings: Operating System
Software
Repositoryhttps://github.com/ahashim/null-ls-solhint-sandbox Steps to reproduce
Using @jose-elias-alvarez's Using @ahashim's As you can see, the error output for both branches is It seems that tests are also passing for the @DavideSilva or @jose-elias-alvarez If you can verify for me the above is correct, then perhaps we can figure out where the disconnect is. AFAIK Thanks again for taking the time to help with this 🙏🏾 |
Thank you for putting this testing repo together. I can confirm that I have exactly the same behavior as you @ahashim. Using the same Neovim and Solhint versions Opening the Changing the |
Alright, not 100% sure what's going on but I can confirm that I see the behavior you describe with your reproduction. Let me know if this is okay to merge (I went ahead and pushed a fix that was causing CI to fail for an unrelated reason). |
Thanks for testing this & confirming the expected behavior @jose-elias-alvarez & @DavideSilva. I suspect the error was still mine when I initially committed the PR (and just didn't realize it for a bit). Regardless, I'm happy to see this working again. Thank you for fixing the tests, and feel free to merge at your earliest convenience ✌🏾 |
Thanks all! |
Hi guys, @ahashim @jose-elias-alvarez although this PR was closed, but seems that this setting is not 100% sure, so I'm here to share what I have found. Currently, I encounter a similar error with my project but I have to set After comparing the difference between my project and The following is what I have tested to reproduce. I set the But I'm not familiar with solhint, so I don't know why this happens. |
Thank for you investigating & sharing your findings @KalleChen. This seems like a configuration that should be solved on the solhint side of things in order for the null-ls plugin to have consistent behavior. According to the solhint repository, the compiler version configuration option is turned on only if the user enables the Perhaps this needs to be rectified in the solhint repository so errors are always sent to If that makes sense, i'll start an investigation on the solhint repo & can open up a PR to adjust the error output settings. What are your thoughts? Thank you again for helping to investigate. |
@ahashim Thanks for your reply. Yeah, I think it should be rectified in the solhint repository. In my test case, changing Besides, while I investigated the Also, I've opened an PR here to add formatter support for stdin process in Thanks again. |
Thanks for the thorough investigation @KalleChen. I have indeed been able to reproduce the issue on my end, and agree with your conclusions. I think we should move the discussion over to the PR you created to fix it (seeing as how this isn't a null-ls issue at this point). Thank you again for getting to the bottom of this! 💪🏾 |
Thanks all for investigating! The behavior we were seeing was pretty confusing, so I think the upstream solution makes sense. |
This fixes not seeing warnings/errors when running null-ls diagnostics on Solidity files. The change will now make diagnostic messages to actually show up in the proper output buffer.
Here is the
NullLsLog
output for said diagnostics in debug mode: