Skip to main content

A framework that exposes a simple set of APIs enabling multi-process integration with the curses screen painting library

Project description

mpcurses is a framework that exposes a simple set of APIs enabling multi-process integration with the curses screen painting library.

With the mpcurses APIs, the complexities of setting up multi-processing within a curses environment are abstracted away. The only requirement is that the target method needs to implement logging.

How it works

The method you wish to execute concurrently is decorated with the queue handler decorator. The queue handler decorator creates a new log handler that will write all logged messages within the decorated method to a thread-safe queue. The main process creates the thread-safe message queue and handles the spawning of the desired number of concurrent processes, each process will be passed the reference to the message queue upon startup. The main process will then read messages from the message queue as they come in and update the curses screen accordingly.

The layout of the curses screen is defined as a dictionary and can leverage builtin constructs for capturing messages, incrementing counters, and processing side effects such as changing text colors when certain messages appear. The result is a dynamic screen that is being updated dynamically from any number of concurrent processes running in the background.

For samples checkout our home page: https://github.com/soda480/mpcurses

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mpcurses-0.0.1.tar.gz (7.2 kB view details)

Uploaded Source

Built Distribution

mpcurses-0.0.1-py3-none-any.whl (9.6 kB view details)

Uploaded Python 3

File details

Details for the file mpcurses-0.0.1.tar.gz.

File metadata

  • Download URL: mpcurses-0.0.1.tar.gz
  • Upload date:
  • Size: 7.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/39.0.1 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.6.5

File hashes

Hashes for mpcurses-0.0.1.tar.gz
Algorithm Hash digest
SHA256 fbd46c61febdb06ad01e565f89193e069c81933dbbe3c43a9ba11b7d6dae2584
MD5 fb1c13e77d8e95bd09fbe395e8642374
BLAKE2b-256 46d155bd089437099cf32b8fc73e209bcb472849a4a1596cd01a2dd6735fc7d7

See more details on using hashes here.

Provenance

File details

Details for the file mpcurses-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: mpcurses-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 9.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/39.0.1 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.6.5

File hashes

Hashes for mpcurses-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 727567957e000130c66d3899bd8f30ba29e73c607094fe5ba3e51a03c8af1c85
MD5 631eadc14e6bc9c0a174430b85886c48
BLAKE2b-256 6cfb5b8163f496f72b12853f997d71bb3fdcfcb6b7cdd48be40e6e73641b2695

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page