Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a warning emoji ⚠️ to the logger #588

Merged
merged 1 commit into from
Jan 20, 2018

Conversation

fathyb
Copy link
Contributor

@fathyb fathyb commented Jan 19, 2018

because we all love emojis, don't we?

@codecov-io
Copy link

codecov-io commented Jan 19, 2018

Codecov Report

Merging #588 into master will decrease coverage by 0.16%.
The diff coverage is 50%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #588      +/-   ##
==========================================
- Coverage   88.85%   88.68%   -0.17%     
==========================================
  Files          57       57              
  Lines        1749     1750       +1     
==========================================
- Hits         1554     1552       -2     
- Misses        195      198       +3
Impacted Files Coverage Δ
src/Logger.js 32.72% <0%> (-5.46%) ⬇️
src/utils/emoji.js 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a120fbb...c069ee4. Read the comment docs.

src/Logger.js Outdated
@@ -42,7 +42,7 @@ class Logger {
return;
}

this.write(this.chalk.yellow(message));
this.status(emoji.warning, message, 'yellow');
Copy link
Contributor

Choose a reason for hiding this comment

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

This introduces a logging defect. If I'm using a logLevel of 2, warn should write. With this change, it will be silenced by the check in this.status which requires a logLevel of 3.

A test for such a regression is included in #562.

@@ -4,3 +4,4 @@ const supportsEmoji = process.platform !== 'win32' || process.env.VSCODE_PID;
exports.progress = supportsEmoji ? '⏳' : '∞';
exports.success = supportsEmoji ? '✨' : '√';
exports.error = supportsEmoji ? '🚨' : '×';
exports.warning = supportsEmoji ? '⚠️' : '⚠';
Copy link
Contributor

Choose a reason for hiding this comment

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

The provided Windows fallback '⚠' doesn't actually work on Windows and will render as []. Please use (203C).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks, I pushed a new commit with both issues fixed.

@devongovett devongovett merged commit 25cf217 into parcel-bundler:master Jan 20, 2018
devongovett pushed a commit that referenced this pull request Oct 15, 2018
devongovett pushed a commit that referenced this pull request Oct 15, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants