Skip to main content

A simple recursive function that allows to give more information about an object than 'type' binded function

Project description

Overview

Supertype-python is a package countaining a single function, supertype(). This one works like type but gives more information, which could be useful in a development phase.

Installation

pip install supertype-python

Usage

Without this package, it would take some precious time and precious attention to know the content of an object like this :

a = [0,1,2]
b = 'bbb'
c = 5
d = {"x": "X", "y": "Y", "z": "Z"}
e = [a,b]
f = (e,c,d)

Now, you can import supertype() and just ask the supertype of the object f :

from supertype import supertype

supertype(f)

This returns :

tuple of 3 elements containing :
    -list of 2 elements containing :
        -list of 3 elements containing {'int'}
        -str of 3 elements
    -int
    -dict of 3 elements

What should be added soon

-correction of language approximations
-specific treatment for some types (not very useful to know the size of a string for example)
-better comments
-check compatibility with all python 3, see if it can go to python 2
-...

If you have any idea or suggestion feel free to contact me on my email.

License

MIT

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

supertype-python-1.0.5.tar.gz (2.1 kB view details)

Uploaded Source

Built Distribution

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

supertype_python-1.0.5-py3-none-any.whl (6.2 kB view details)

Uploaded Python 3

File details

Details for the file supertype-python-1.0.5.tar.gz.

File metadata

  • Download URL: supertype-python-1.0.5.tar.gz
  • Upload date:
  • Size: 2.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.4

File hashes

Hashes for supertype-python-1.0.5.tar.gz
Algorithm Hash digest
SHA256 1e46dc3976576e0c2ed82068cbe3465b760ac1a3c8913ed63cb1efc0ae6a62ba
MD5 1e966f798a74c35538b6b8725ed31763
BLAKE2b-256 501486eec783bdc01557e1a67a5cfba781a7b1e23ac0393fd56b66609263a1e9

See more details on using hashes here.

File details

Details for the file supertype_python-1.0.5-py3-none-any.whl.

File metadata

  • Download URL: supertype_python-1.0.5-py3-none-any.whl
  • Upload date:
  • Size: 6.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.4

File hashes

Hashes for supertype_python-1.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 15c65e5d5550b994e6bd0d01bfd41d49467256efd9ca43756e3c0bdd38efe2b8
MD5 6315c33ded2e8b370d48974ab0ab60cf
BLAKE2b-256 8de1beece34fc530026e7cfd041cce287472902b00a112b642972e3571558e8c

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