bugfix infinite loop in Terminal.wrap
Closes https://github.com/jquast/blessed/issues/273 by @grayjk,
The following code enters an infinite loop:
import blessed
blessed.Terminal().wrap('\u5973', 1)
This fixes by explicit check: when
- the given individual sequence is of length '2'
- and the wrap width is '1'
- and the cur_len is '0'
we cannot break down this "Wide" character any further -- so it is allowed to flow outside the given cell.
faulthandler_timeout = 30is added to[pytest]in tox.ini- Tests for East-Asian, Emoji, and ZWJ are added
- Further noting that blessed gets ZWJ wrong
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 95.57%. Comparing base (
77fe25a) to head (edb5196). Report is 9 commits behind head on master.
Additional details and impacted files
@@ Coverage Diff @@
## master #275 +/- ##
==========================================
+ Coverage 95.56% 95.57% +0.01%
==========================================
Files 10 10
Lines 1037 1040 +3
Branches 177 165 -12
==========================================
+ Hits 991 994 +3
Misses 43 43
Partials 3 3
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
:rocket: New features to boost your workflow:
- :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
poke @jquast @avylove
hoping this can get merged so I can remove a workaround for #273. thanks!
yes, sure, i'll do it soon
This is released, although the wheel has uploaded I'm having a problem with pushing the source tarball, it should get online eventually