<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/python-packages/urwid.git/urwid/tests, branch master</title>
<subtitle>github.com: wardi/urwid.git
</subtitle>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/urwid.git/'/>
<entry>
<title>Fix `TextCanvas` `CanvasError("Attribute extends beyond text...")` (#555)</title>
<updated>2023-05-09T07:13:40+00:00</updated>
<author>
<name>Alexey Stepanov</name>
<email>penguinolog@users.noreply.github.com</email>
</author>
<published>2023-05-09T07:13:40+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/urwid.git/commit/?id=ffbfa07533809a523938d5e342ff7482a12dd5d0'/>
<id>ffbfa07533809a523938d5e342ff7482a12dd5d0</id>
<content type='text'>
* Fix TextCanvas `CanvasError("Attribute extends beyond text...")

* `[[]] * ...` causes
  list of 1 list with pointers
  amount equal to multiplier
  instead of "list of lists"
* Add 2 basic font tests which check for Canvas create issue
* Add few type annotations during debug process

Fix: #554

* Force tests to restore default encoding in tearDown

Tests order change should not cause tests failures

---------

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* Fix TextCanvas `CanvasError("Attribute extends beyond text...")

* `[[]] * ...` causes
  list of 1 list with pointers
  amount equal to multiplier
  instead of "list of lists"
* Add 2 basic font tests which check for Canvas create issue
* Add few type annotations during debug process

Fix: #554

* Force tests to restore default encoding in tearDown

Tests order change should not cause tests failures

---------

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>Return original code to the deprecated getters and setters (#549)</title>
<updated>2023-05-01T13:26:37+00:00</updated>
<author>
<name>Alexey Stepanov</name>
<email>penguinolog@users.noreply.github.com</email>
</author>
<published>2023-05-01T13:26:37+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/urwid.git/commit/?id=bac20db87eaeb0b7a0026807d7e6dbe391b08580'/>
<id>bac20db87eaeb0b7a0026807d7e6dbe391b08580</id>
<content type='text'>
* Return original code to the deprecated getters and setters

* Make more aggressive deprecation warning

Fix: #548

* Return original code to the deprecated getters and setters

* Make more aggressive deprecation warning

Fix: #548

---------

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* Return original code to the deprecated getters and setters

* Make more aggressive deprecation warning

Fix: #548

* Return original code to the deprecated getters and setters

* Make more aggressive deprecation warning

Fix: #548

---------

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>Fix incorrect type cast in vterm (`apply_mapping` should return `bytes`) (#545)</title>
<updated>2023-04-25T17:20:33+00:00</updated>
<author>
<name>Alexey Stepanov</name>
<email>penguinolog@users.noreply.github.com</email>
</author>
<published>2023-04-25T17:20:33+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/urwid.git/commit/?id=1cc1d63358f7759785b39079eca069ed41078b6d'/>
<id>1cc1d63358f7759785b39079eca069ed41078b6d</id>
<content type='text'>
* Fix incorrect type cast in vterm (`apply_mapping` should return `bytes`)

Add `time.sleep(0.1)` to the event loop tests:
  in the worst scenario on windows and slow machine
  function in parallel thread/async can wait up to 80 milliseconds (tested)
Add type annotations to the `vterm` and `test_vterm` to simplify error lookup.
* Fix `DeprecationWarning` in doctests &amp; examples
* Add `pytest` configuration in `pyproject.toml` without migration
* `Signals.emit()` rework: stop `user_args` join with `weak_args`

Partial: #544
Partial: #512
Partial: #406

* drop `sleep`: not enough effective with pytest

* set timer for errors raise to 0: faster raise, faster test done

---------

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* Fix incorrect type cast in vterm (`apply_mapping` should return `bytes`)

Add `time.sleep(0.1)` to the event loop tests:
  in the worst scenario on windows and slow machine
  function in parallel thread/async can wait up to 80 milliseconds (tested)
Add type annotations to the `vterm` and `test_vterm` to simplify error lookup.
* Fix `DeprecationWarning` in doctests &amp; examples
* Add `pytest` configuration in `pyproject.toml` without migration
* `Signals.emit()` rework: stop `user_args` join with `weak_args`

Partial: #544
Partial: #512
Partial: #406

* drop `sleep`: not enough effective with pytest

* set timer for errors raise to 0: faster raise, faster test done

---------

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>Fix text layout for `align="center", wrap="clip"` when `maxcol` == `line_width - 1` (#543)</title>
<updated>2023-04-24T10:13:41+00:00</updated>
<author>
<name>Toluwaleke Ogundipe</name>
<email>anonymoux47@gmail.com</email>
</author>
<published>2023-04-24T10:13:41+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/urwid.git/commit/?id=6bf74be23f3179d87d4f40d45d2a4e8718ab26f5'/>
<id>6bf74be23f3179d87d4f40d45d2a4e8718ab26f5</id>
<content type='text'>
* Fix text layout for `align="center", wrap="clip"`

- Fix: Prevent zero run length in text layout.

Refs: urwid#542

* Add test for "clip" text layout fix

Refs: #542</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* Fix text layout for `align="center", wrap="clip"`

- Fix: Prevent zero run length in text layout.

Refs: urwid#542

* Add test for "clip" text layout fix

Refs: #542</pre>
</div>
</content>
</entry>
<entry>
<title>[BREAKING CHANGE] Fixes: #90 Remove idle emulation from asyncio event loop (#541)</title>
<updated>2023-04-21T13:12:51+00:00</updated>
<author>
<name>Alexey Stepanov</name>
<email>penguinolog@users.noreply.github.com</email>
</author>
<published>2023-04-21T13:12:51+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/urwid.git/commit/?id=350ee5c47ff565d3b0d25b1c3cbddbfb2a0a2a4f'/>
<id>350ee5c47ff565d3b0d25b1c3cbddbfb2a0a2a4f</id>
<content type='text'>
* [BREAKING CHANGE] Fix: #90 Remove idle emulation from asyncio event loop

Re-implement abandoned PR #418
* Fix "not hashable `AttrSpec`" and it's instance creation price (use `__slots__`)
  `AttrSpec` instances may be created in huge amount,
  with slots this process consume less resources.
* `Terminal` is always created with event loop,
  if not provided -&gt; `SelectEventLoop` is used
* Fixed `TornadoEventLoop` &amp; `AsyncioEventLoop` logic
  (Tornado IOLoop is asyncio based)

For extra details see original PR.

* Make `AttrSpec` immutable and hash-reusable

* Update IDLE callback comment

* Update urwid/display_common.py

Co-authored-by: Ian Ward &lt;ian@excess.org&gt;

---------

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;
Co-authored-by: Ian Ward &lt;ian@excess.org&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* [BREAKING CHANGE] Fix: #90 Remove idle emulation from asyncio event loop

Re-implement abandoned PR #418
* Fix "not hashable `AttrSpec`" and it's instance creation price (use `__slots__`)
  `AttrSpec` instances may be created in huge amount,
  with slots this process consume less resources.
* `Terminal` is always created with event loop,
  if not provided -&gt; `SelectEventLoop` is used
* Fixed `TornadoEventLoop` &amp; `AsyncioEventLoop` logic
  (Tornado IOLoop is asyncio based)

For extra details see original PR.

* Make `AttrSpec` immutable and hash-reusable

* Update IDLE callback comment

* Update urwid/display_common.py

Co-authored-by: Ian Ward &lt;ian@excess.org&gt;

---------

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;
Co-authored-by: Ian Ward &lt;ian@excess.org&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>[BREAKING CHANGE] Refactoring: Split event loop in several modules (#537)</title>
<updated>2023-04-18T15:35:19+00:00</updated>
<author>
<name>Alexey Stepanov</name>
<email>penguinolog@users.noreply.github.com</email>
</author>
<published>2023-04-18T15:35:19+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/urwid.git/commit/?id=d1710f0983e86dc5ec06efec6e94f3b6d204bbb3'/>
<id>d1710f0983e86dc5ec06efec6e94f3b6d204bbb3</id>
<content type='text'>
* [BREAKING CHANGE] Refactoring: Split event loop in several modules

* `urwid.main_loop` is split into multiple modules which is easier to maintain
* `urwid.compat` is not used anymore and removed
* `TornadoEventLoop`, `GLibEventLoop`, `TwistedEventLoop` and `TrioEventLoop`
  accessible ONLY if required dependencies installed
  (like: Tornado installed -&gt; `TornadoEventLoop` is accessible for import)
* `TornadoEventLoop` use the same idle logic as `AsyncioLoop`:
  tornado.ioloop.IOLoop is asyncio based.
* Trio &lt; 0.15 is not supported. Version 0.15 was released almost 3 years ago.
* Tornado &lt; 5.0 is not supported. Tornado 5.0 was released 5 years ago.

* Remove useless shebang

* `EventLoop` should be real abstract
* add new module docstrings

* Fix docstrings

* remove unneeded import

---------

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* [BREAKING CHANGE] Refactoring: Split event loop in several modules

* `urwid.main_loop` is split into multiple modules which is easier to maintain
* `urwid.compat` is not used anymore and removed
* `TornadoEventLoop`, `GLibEventLoop`, `TwistedEventLoop` and `TrioEventLoop`
  accessible ONLY if required dependencies installed
  (like: Tornado installed -&gt; `TornadoEventLoop` is accessible for import)
* `TornadoEventLoop` use the same idle logic as `AsyncioLoop`:
  tornado.ioloop.IOLoop is asyncio based.
* Trio &lt; 0.15 is not supported. Version 0.15 was released almost 3 years ago.
* Tornado &lt; 5.0 is not supported. Tornado 5.0 was released 5 years ago.

* Remove useless shebang

* `EventLoop` should be real abstract
* add new module docstrings

* Fix docstrings

* remove unneeded import

---------

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>Fix empty markup handling (#536)</title>
<updated>2023-04-12T07:43:26+00:00</updated>
<author>
<name>Alexey Stepanov</name>
<email>penguinolog@users.noreply.github.com</email>
</author>
<published>2023-04-12T07:43:26+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/urwid.git/commit/?id=9f748c7fe98c20a6c1b55e28344a57b43209b046'/>
<id>9f748c7fe98c20a6c1b55e28344a57b43209b046</id>
<content type='text'>
* not switching to Unicode-only at this moment, so make simple

Fix #408

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* not switching to Unicode-only at this moment, so make simple

Fix #408

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>Fix regression: `Pile()` focus_item can be Widget -&gt; need to set property `focus` in constructor (#535)</title>
<updated>2023-04-12T07:30:34+00:00</updated>
<author>
<name>Alexey Stepanov</name>
<email>penguinolog@users.noreply.github.com</email>
</author>
<published>2023-04-12T07:30:34+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/urwid.git/commit/?id=ed8074910d54d510ba30829c6bb7ed4c3b3e0a55'/>
<id>ed8074910d54d510ba30829c6bb7ed4c3b3e0a55</id>
<content type='text'>
Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>Fix #445 - add `__len__` to listbox with validation if body `Sized` (#534)</title>
<updated>2023-04-12T07:03:27+00:00</updated>
<author>
<name>Alexey Stepanov</name>
<email>penguinolog@users.noreply.github.com</email>
</author>
<published>2023-04-12T07:03:27+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/urwid.git/commit/?id=2f80badfdd011dc3e96c95e51bf459b282f6d735'/>
<id>2f80badfdd011dc3e96c95e51bf459b282f6d735</id>
<content type='text'>
* If body is not `Sized` - `__len__` call should raise `AttributeError`
* Downside: since body can be replaced, `__len__` is always set ant `ListBox` by itself will pass `Sized` instance check
* Relax `SimpleListWalker` constructor rules: any Iterable is allowed as source due to `list` is used internally

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* If body is not `Sized` - `__len__` call should raise `AttributeError`
* Downside: since body can be replaced, `__len__` is always set ant `ListBox` by itself will pass `Sized` instance check
* Relax `SimpleListWalker` constructor rules: any Iterable is allowed as source due to `list` is used internally

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>Deprecate legacy property creation (#533)</title>
<updated>2023-04-12T05:47:14+00:00</updated>
<author>
<name>Alexey Stepanov</name>
<email>penguinolog@users.noreply.github.com</email>
</author>
<published>2023-04-12T05:47:14+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/python-packages/urwid.git/commit/?id=8a0a6d166e4cef88a7e7b644abee8712eacee7f6'/>
<id>8a0a6d166e4cef88a7e7b644abee8712eacee7f6</id>
<content type='text'>
* Deprecate legacy property creation

* Drop long time ago removed methods (never returning methods)
* Move large part of property implementations under `@property`
* Emit `PendingDeprecationWarning`
  for old compatibility code
  for public methods used as core for property and methods for compatibility
* Emit `DeprecationWarning`
  for private methods used in property construction
  using `property()` call

Due to amount of copy-paste like changes, for containers shared part is moved to the existing base classes
Add `__len__` to the list based containers. Related #445
Fix typo in type annotation for `Frame.mouse_event`

* Update urwid/canvas.py

Co-authored-by: Ian Ward &lt;ian@excess.org&gt;

* Update urwid/canvas.py

Co-authored-by: Ian Ward &lt;ian@excess.org&gt;

* Update urwid/tests/test_container.py

Co-authored-by: Ian Ward &lt;ian@excess.org&gt;

* Fix typo in test name

* Frame `header`, `body` and `footer` also has property and methods from pre-property era

Make consistent with other containers

---------

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;
Co-authored-by: Ian Ward &lt;ian@excess.org&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* Deprecate legacy property creation

* Drop long time ago removed methods (never returning methods)
* Move large part of property implementations under `@property`
* Emit `PendingDeprecationWarning`
  for old compatibility code
  for public methods used as core for property and methods for compatibility
* Emit `DeprecationWarning`
  for private methods used in property construction
  using `property()` call

Due to amount of copy-paste like changes, for containers shared part is moved to the existing base classes
Add `__len__` to the list based containers. Related #445
Fix typo in type annotation for `Frame.mouse_event`

* Update urwid/canvas.py

Co-authored-by: Ian Ward &lt;ian@excess.org&gt;

* Update urwid/canvas.py

Co-authored-by: Ian Ward &lt;ian@excess.org&gt;

* Update urwid/tests/test_container.py

Co-authored-by: Ian Ward &lt;ian@excess.org&gt;

* Fix typo in test name

* Frame `header`, `body` and `footer` also has property and methods from pre-property era

Make consistent with other containers

---------

Co-authored-by: Aleksei Stepanov &lt;alekseis@nvidia.com&gt;
Co-authored-by: Ian Ward &lt;ian@excess.org&gt;</pre>
</div>
</content>
</entry>
</feed>
