Skip to content

Conversation

@abarth
Copy link
Contributor

@abarth abarth commented Nov 18, 2015

Now we print the name of the asset and the base directory where we looked for
the error instead of throwing a null pointer exception.

Fixes #296

Now we print the name of the asset and the base directory where we looked for
the error instead of throwing a null pointer exception.

Fixes flutter#296
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use the logging infrastructure?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@devoncarew 's recommendation is not to use the logging system for messages intended for humans. I don't fully understand when we're supposed to use logging and when we're supposed to just write to stdout/stderr.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we were using logging too much early in the life of this tool. Generally, I think all errors should be written to stderr regardless of the logging level. Status messages to the user should probably go to stdout, again, regardless of the logging level. And only diagnostic stuff should go to logging (about to run process 'foo arg1 arg2'). This would be for users to use when things go off the rails and they're trying to determine where in the process things are breaking. And we could probably just dial the use of logging back down to use info, so there's less guesswork about which things go where.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Filed #461 to track this.

@Hixie
Copy link
Contributor

Hixie commented Nov 18, 2015

LGTM

abarth added a commit that referenced this pull request Nov 18, 2015
Improve error message for non-existent asset
@abarth abarth merged commit b20a1f4 into flutter:master Nov 18, 2015
@abarth abarth deleted the asset_error branch November 18, 2015 07:07
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 17, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

hard to parse error if flutter.yaml points to a file that doesn't exist.

3 participants