How to Install and Uninstall python38-unsync Package on openSuSE Tumbleweed

Last updated: November 23,2024

1. Install "python38-unsync" package

This guide covers the steps necessary to install python38-unsync on openSuSE Tumbleweed

$ sudo zypper refresh $ sudo zypper install python38-unsync

2. Uninstall "python38-unsync" package

Here is a brief guide to show you how to uninstall python38-unsync on openSuSE Tumbleweed:

$ sudo zypper remove python38-unsync

3. Information about the python38-unsync package on openSuSE Tumbleweed

Information for package python38-unsync:
----------------------------------------
Repository : openSUSE-Tumbleweed-Oss
Name : python38-unsync
Version : 1.3-1.5
Arch : noarch
Vendor : openSUSE
Installed Size : 20,1 KiB
Installed : No
Status : not installed
Source package : python-unsync-1.3-1.5.src
Summary : Unsynchronize asyncio
Description :
Unsynchronize `asyncio` by using an ambient event loop in a separate thread.
1. Mark all async functions with `@unsync`. May also mark regular
functions to execute in a separate thread.
* All `@unsync` functions, async or not, return an `Unfuture`
2. All `Futures` must be `Unfutures` which includes the result of an
`@unsync` function call, or wrapping `Unfuture(asyncio.Future)` or
`Unfuture(concurrent.Future)`. `Unfuture` combines the behavior of
`asyncio.Future` and `concurrent.Future`:
* `Unfuture.set_value` is threadsafe unlike `asyncio.Future`
* `Unfuture` instances can be awaited, even if made from
`concurrent.Future`
* `Unfuture.result()` is a blocking operation *except* in
`unsync.loop`/`unsync.thread` where it behaves like
`asyncio.Future.result` and will throw an exception if the future
is not done
3. Functions will execute in different contexts:
* `@unsync` async functions will execute in an event loop in
`unsync.thread`
* `@unsync` regular functions will execute in
`unsync.thread_executor`, a `ThreadPoolExecutor`
* `@unsync(cpu_bound=True)` regular functions will execute in
`unsync.process_executor`, a `ProcessPoolExecutor`