Open
Conversation
passsy
reviewed
Oct 16, 2023
Comment on lines
334
to
336
| void Function()? updateCheck; | ||
| try { | ||
| final updateFuture = VersionChecker.isDependencyUpToDate( |
Contributor
There was a problem hiding this comment.
The try catch is now useless, because the updateFuture is not awaited.
The error of VersionChecker.isDependencyUpToDate() is never caught and would crash the CLI
Contributor
Author
There was a problem hiding this comment.
The Future itself is awaited in Line 345 in combination with the timeout
Errors are caught and result in returning null
passsy
reviewed
Oct 16, 2023
| final unmount = mount(debugName: args.join(' ')); | ||
|
|
||
| ArgResults? parsedArgs; | ||
| Future<void Function()?>? updateCheck; |
Contributor
There was a problem hiding this comment.
A Future<void> should be sufficient. The void Function() seems redundant
Contributor
Author
There was a problem hiding this comment.
I updated it to a String? :)
added 2 commits
November 4, 2023 15:15
993b9d6 to
632af79
Compare
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.
This PR is addressing this issue #174
Starting the update check at the beginning of a command in an isolate and execute the returned function, which contains the
_checkCliVersionIntegrityand may contain the print that an update is available