[WIP] @feature: "cargo check"-inspector for the rust bundle#464
Open
bugabinga wants to merge 7 commits intohowl-editor:masterfrom
Open
[WIP] @feature: "cargo check"-inspector for the rust bundle#464bugabinga wants to merge 7 commits intohowl-editor:masterfrom
bugabinga wants to merge 7 commits intohowl-editor:masterfrom
Conversation
This adds an "on_idle" inspector in the rust bundle, that calls `cargo check` and parses the output json for warning and errors. It was necessary to extend `inspect.moon` to accept options for enabling/disabling stdout/stderr because cargo sends the json to stdout and some other non-json to stderr. This produced a bug in `activities.moon` where the pump-methods of the process always received a `on_stdout` and a `on_stderr` handler, regardless of the existence of a `stdout` or `stderr` object respectivly in the process. The fix simply checks for the existence of these objects and omits passing the respective handler if the output stream does not exist.
This adds an "on_idle" inspector in the rust bundle, that calls `cargo check` and parses the output json for warning and errors. It was necessary to extend `inspect.moon` to accept options for enabling/disabling stdout/stderr because cargo sends the json to stdout and some other non-json to stderr. This produced a bug in `activities.moon` where the pump-methods of the process always received a `on_stdout` and a `on_stderr` handler, regardless of the existence of a `stdout` or `stderr` object respectivly in the process. The fix simply checks for the existence of these objects and omits passing the respective handler if the output stream does not exist.
Contributor
Author
|
add "work in progress" label, because I have encountered a bug that I will fix. |
…s return `nil`. `Cargo check` returns issues with a list of "spans", that hold position information about the issue in the text buffer. Since a spans "label" (message) is optional, a fallback to the parent issues message was added.
Contributor
|
@bugabinga I believe we talked about this on Gitter, but I see this as useful. Remove the WIP label when you feel it's ready for review. |
- use more precise filter to get errors/warnings from cargo - use rendered message from error to display in howl
Contributor
Author
|
I still try to fix this from time to time, but regularly hit a wall. There is a bug blocking this:
Hopefully you will find some time to whip up some docs about how bundles are supposed to get built ;). |
|
Has these been any progress on this? Seems like a very useful feature. I've not used Moon before, but I'm happy to try my hand at fixing the remaining issue if explained a little further. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.