Skip to main content

A print funtion that slowly shows the output in console in real time

Project description

Snail Print

GitHub release codeclimate Tests & Linter Code style: black

This library includes a print funtion that slows down the showing of output in console, character by character, as though typed by a typewriter.

Getting started

Install the library with:

pip install -U snail_print

Usage

Presentation Demo Video

Gif 1: Example of use of this real time print library

Moreover, every console log in this video was made with the library and with this file

Copy and paste this code and try it yourself!

from snail_print import snail_print
snail_print("Hello World", delay=0.2)

Documentation

snail_print

function snail_print(*objects, delay=0.1, sep=" ", end="\n")

Parameters

  • objects: Can be any or even multiple python objects.

The objects whose string representation will be "snail printed".

  • delay: float or int, default 0.1.

The delay, measured in seconds, between the printing of each character in object.

  • sep: str, default " ".

In case of having multiple arguments, one sep will be placed between each and the next.

  • end: str, default "\n".

The final character of the print. By default creates a new line.

Testing

Run the test suite with:

python -m unittest tests

Install local

To install it locally from the source code:

python setup.py develop

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

snail_print-0.1.9.tar.gz (4.0 kB view hashes)

Uploaded Source

Built Distribution

snail_print-0.1.9-py3-none-any.whl (4.2 kB view hashes)

Uploaded Python 3

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