Skip to main content

This module provides capabilities for type checking function arguments. (NOTE: A full type check with this module is not possible, since this is fundamentally not possible due to limitiations of Python itself.)

Project description

jk_typing

Introduction

This module provides capabilities for type checking function arguments.

Please note that a full type check with this module is not possible, since this is fundamentally not possible due to limitiations of Python itself.

Information about this module can be found here:

Why this module?

Python nowadays is capable of managing type hints for function arguments and return values. Unfortunately Python does not perform type checking automatically. This module provides capabilities of performing type checking automatically.

For more details have a look at the documentation.

Requirements

This module requires Python 3.7 or later. It can not be used on older releases of Python because of limitations of module typing.

Limitations of this module

Type checking is not implemented in pure Python. Therefore it is slower as if the Python interpreter would perform type checking itself. Additionally this module has not yet a complete implementation of all kinds of types. (This will change in the future, maybe with your help.)

For more details have a look at the documentation.

How to use this module

Import this module

Please include this module into your application using the following code:

import jk_typing

Define a function

Example:

@checkFunctionSignature(bDebug = True)
def someFunction(a:int, b:str) -> bool:
	return str(a) == b

Invoke the function (and perform type checking)

result = someFunction(123, "123")
print(result)

Contact Information

This work is Open Source. This enables you to use this work for free.

Please have in mind this also enables you to contribute. We, the subspecies of software developers, can create great things. But the more collaborate, the more fantastic these things can become. Therefore Feel free to contact the author(s) listed below, either for giving feedback, providing comments, hints, indicate possible collaborations, ideas, improvements. Or maybe for "only" reporting some bugs:

License

This software is provided under the following license:

  • Apache Software License 2.0

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

jk_typing-0.2024.1.3.tar.gz (11.3 kB view details)

Uploaded Source

Built Distribution

jk_typing-0.2024.1.3-py3-none-any.whl (19.6 kB view details)

Uploaded Python 3

File details

Details for the file jk_typing-0.2024.1.3.tar.gz.

File metadata

  • Download URL: jk_typing-0.2024.1.3.tar.gz
  • Upload date:
  • Size: 11.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-requests/2.31.0

File hashes

Hashes for jk_typing-0.2024.1.3.tar.gz
Algorithm Hash digest
SHA256 a9b8d98a79551eb136beed0d464275630e4811ded3e5224e0f30d1b29efa6818
MD5 9ee41a15ce7df4b283a71d2a7fe42af7
BLAKE2b-256 c7257f162946eb01117229e021c1962c7e02c11508f43cdce17d9ca53bccc805

See more details on using hashes here.

File details

Details for the file jk_typing-0.2024.1.3-py3-none-any.whl.

File metadata

File hashes

Hashes for jk_typing-0.2024.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 6ae6f17b055d8a2f12f11f9f369bee961fe4a65b88ad2de82e29dbd5745fea8a
MD5 4cff230d5c91b54bc6a6d539acf3ce14
BLAKE2b-256 1d9b15467632d81e5598746f2888697e3450fcbd400c6cc76b2aaf3efc5ff77e

See more details on using hashes here.

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