Closed kaboc closed 7 months ago
It would also be great if jaspr provided a way of clearing the cache. I wasn't sure how to clear it, but I deleted .dart_tool/build/
to check if the behaviour differed depending on the existing of the cache.
[BUILDER] [ERROR] Initializing inputs
[BUILDER] [ERROR] Building new asset graph...
[BUILDER] [ERROR] Building new asset graph completed, took 2.0s
[BUILDER] [ERROR] Checking for unexpected pre-existing outputs....
[BUILDER] [ERROR] Checking for unexpected pre-existing outputs. completed, took 0ms
[BUILDER] [ERROR] Setting up file watchers...
[BUILDER] [ERROR] Setting up file watchers completed, took 3ms
Is this really an error? The output always has these lines and they are printed in red. I think it is better to show these lines as just [INFO]
or something if the error is not critical.
Thanks for the issue.
Including error logs also in non-verbose mode is a good idea, will try to implement it.
You can clean the buildrunner cache using 'dart eun build_runner clean'
I noticed this too, but this comes from the build runner daemon, I'm not sure I can do something about this.
I think this is resolved by now, as I improved the logging of the cli and added jaspr clean
command.
Description
It is not clear in the output that main.dart.js was not generated due to dependency on a package not supporting the web.
Steps To Reproduce
jaspr build --input xxxx
with or without the--verbose
flag.Expected Behavior
The output clearly states that the build has failed. It might be better to show it in some colour.
Additional Context
Thank you for the great package. I've been using jaspr for my blog.
I was able to build the site successfully some months ago, but recently noticed that builds would fail for some reason. It later turned out that it was because one of the packages that the app depended on had (accidentally) removed support for the web. However, it was a bit difficult to identify the cause of the issue since
jaspr build
ended as if there was no error nor warning most of the time.With cache
Without
--verbose
With
--verbose
Without cache
Without
--verbose
With
--verbose
So, it looks like the warnings are included in the output only when there is no cache and the command was run with
--verbose
. In fact, however, main.dart.js has not been generated, meaning the build has failed. Therefore I think the failure and its reason should be more obvious in the output regardless of whether a cache exists or whether the command was run with some particular flag.