アノテーションチェッカー
Project description
アノテーションチェッカー
概要
Pythonのアノテーションを参考に関数の引数チェックを行います。
PEP484等に準じ書いてるつもりです。
問題点
Note that this PEP still explicitly does NOT prevent other uses of annotations, nor does it require (or forbid) any particular processing of annotations, even when they conform to this specification. 引用元
現在禁止してるので警告に変更するべきかもしれない
使用方法
from chk_args import chk_args
@chk_args
def example(arg_1:int):
return arg_1
example(5)
#result->5
example("a")
#result->TypeError("The type of argument (arg_1) is int.")
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
chk_args-1.1.tar.gz
(2.5 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file chk_args-1.1.tar.gz.
File metadata
- Download URL: chk_args-1.1.tar.gz
- Upload date:
- Size: 2.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
33b3538702bc4191d743e4ec4470baf586d83ccd948976ac480de913d8a090a7
|
|
| MD5 |
21246b22f2937e3e95b9f090f28ada2d
|
|
| BLAKE2b-256 |
a8caae3914252a68b69b7081cef7a3968f47de3f3df8c3b210351c7993317af2
|
File details
Details for the file chk_args-1.1-py3-none-any.whl.
File metadata
- Download URL: chk_args-1.1-py3-none-any.whl
- Upload date:
- Size: 2.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1641c4c4414893ba1c9731afe310de64a3781efc62d7df4a75132084a36eabd0
|
|
| MD5 |
f47bb6e5d40b94e00525a9015f6f17fb
|
|
| BLAKE2b-256 |
dc46cb5a1a1b459b2627c7aaca12f216b9c4cf3d4c3a43655e846a860cb59b5e
|