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

nanoc-cli: Only try to clean UTF-8 chars from UTF-8 strings #1505

Merged
merged 3 commits into from Jun 17, 2020

Conversation

ethancrawford
Copy link
Contributor

Detailed description

Previously, when attempting to load a custom filter in a Windows Nanoc
installation, Nanoc was crashing with indications that the UTF-8 stream cleaner
was unable to process the supplied string.
Now, we only attempt to clean UTF-8 characters out of the string if it is UTF-8
encoded.

To do

(Include the to-do list for this PR to be finished here.)

  • Tests

Related issues

Should fix #1502. (Including the contracts gem issue).

Previously, when attempting to load a custom filter in a Windows Nanoc
installation, Nanoc was crashing with indications that the UTF-8 stream cleaner
was unable to process the supplied string.
Now, we only attempt to clean UTF-8 characters out of the string if it is UTF-8
encoded.

Should fix nanoc#1502. (Including the contracts gem issue).
ethancrawford and others added 2 commits June 17, 2020 14:42
Co-authored-by: Denis Defreyne <denis@denis.ws>
Co-authored-by: Denis Defreyne <denis@denis.ws>
@ethancrawford
Copy link
Contributor Author

😅 thanks for the review 🙂

@denisdefreyne denisdefreyne merged commit 12a54af into nanoc:main Jun 17, 2020
@denisdefreyne
Copy link
Member

Thank you for the fix!

@ethancrawford
Copy link
Contributor Author

You're welcome 😄

@ethancrawford ethancrawford deleted the fix_windows_utf8_issue branch June 17, 2020 06:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Encoding::CompatibilityError when trying to run nanoc on Windows and Ruby 2.7.1
2 participants