Skip to main content

A collection of useful tools

Project description

pyuseful

The package contains a collection of tools I find useful. Check out wiki page for more detail and examples.

Install

Requires python 3.9

pip install pyuseful

General info

Consists of several sub-packages:

  • classtools


    • immutable
      • class ImmutableProperties

        Makes class propreties immutable


    • message
      • class MessageThread

        Creates a separate thread which prints messeges in queue


    • postint
      • class PostInit

        Adds a call to __postinit__ method after init is complete


    • require
      • class RequireAttrs

        Adds attribute require which forces you to set listed attributes by the end of init

      • class RequireDictParser

        Parses dict or json file into a class and make attributes from keys. Adds attribute require and require_any which force you to set listed attributes by the end of init

  • decorators


    • require

      • decorator require_condition

        Let's you specify a condition in which a method of a class can be called

      • decorator once

        Function can only be called once or it always returns the same result as the 1st call

      • decorator limit

        Limits a number of times a function can be called

      • decorator try_times

        A function will be called several times if they raise an error


    • thread

      • decorator repeat_timer

      Repeat a function every timer number of seconds. Returns a Queue-like object with results


    • timing
      • decorator time_exec

        Messure exec time of a function

  • filetools


    • misc
      • function mod_name_with_ext

        Modify a path without modifying an extention


    • splicer
      • class Splicer

        Let's you specify blocks in files which can be pasted into other files

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

pyuseful-0.0.5.tar.gz (11.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyuseful-0.0.5-py3-none-any.whl (13.6 kB view details)

Uploaded Python 3

File details

Details for the file pyuseful-0.0.5.tar.gz.

File metadata

  • Download URL: pyuseful-0.0.5.tar.gz
  • Upload date:
  • Size: 11.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.9

File hashes

Hashes for pyuseful-0.0.5.tar.gz
Algorithm Hash digest
SHA256 5327eb06cd45231b8c0d4aad9e471b09c762d59d825a2225abbf8dea45ec05b9
MD5 6fd9f8e44227be03f90b5cccdb51d648
BLAKE2b-256 8a7219ddcb18b9fb287fb5ef70d9b56a90038e2e3983c7fdade99a8edf403272

See more details on using hashes here.

File details

Details for the file pyuseful-0.0.5-py3-none-any.whl.

File metadata

  • Download URL: pyuseful-0.0.5-py3-none-any.whl
  • Upload date:
  • Size: 13.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.9

File hashes

Hashes for pyuseful-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 13e2551eea13a4025cb4927c5bafa73510359339429322070030489c4d2439f6
MD5 decae7f455e6aec393c362ce768e1782
BLAKE2b-256 eecb962ef0125296bdfa197c20901da651384b642f9ce81d763b671fa7798ee6

See more details on using hashes here.

Supported by

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