strictclasses
Disclaimer: this is beta software, API is not stable.
This is a validation companion to dataclasses.
It adds the strict method to the dataclass to validate the types are correct.
Usage:
from dataclasses import dataclass
from strictclasses import strict
@strict
@dataclass
class Foo:
bar: int
f = Foo('3')
f.strict() # -> AssertionError: bar is not an instance of <class 'int'>
Metadata
Release files for strictclasses 0.1.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| strictclasses-0.1.4.tar.gz | 1.5 kB | Without provenance | Details for strictclasses-0.1.4.tar.gz |
Release files / strictclasses-0.1.4.tar.gz
| Download URL | strictclasses-0.1.4.tar.gz |
|---|---|
| Size | 1.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
bfe0016c890d17401419abdf25e6824ee9a2be09ceddb924fe31d863caa7b775
|
|
BLAKE2b-256 checksum How to use checksums |
ed6b23378c49e5256b543bab14ac14eecbcb62e670822bb7cadc2d2174a741ea
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for strictclasses 0.1.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.