Typical

Latest version: v2.9.0

Safety actively analyzes 682251 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 12 of 13

2.0.0

This release brings an entirely new annotation resolution engine which
is backwards-incompatible with v1.

New features include:

1. `typic.protocol` for binding a serialization & deserialization
for any type or annotation.
2. `typic.constrained` for definining restricted versions of
builtin types.
3. `typic.settings` for resolving the default values of a dataclass
from your environment variables
4. A whole new suite of useful types, including:
- `FrozenDict`, a hashable, immutable dictionary
- `DSN`, a JSON-serializable string-type for your database URIs
- `URL`, a JSON-serializable string-type for your URLs
- `Email`, a JSON-serializable string-type for emails
- `SecretString`, a JSON-serializable string-type for hiding
secrets when logging or printing
5. `typic.schema` for getting a valid JSON Schema definition for
your classes and type annotations. ``typical`` classes also have
access to this as a classmethod.
6. `typic.primitive` for extracting a valid JSON-serializable
primitive from just about anything. ``typical`` classes also have
access to this as an instance method.
7. `typic.tojson` for dumping any value directly to a JSON-compliant string.

And so much more. Check out the [documentation](https://python-typical.org/) for details!

2.0.0rc2

Bugfixes:
- Fix `ext.json` module for case when ujson cannot be imported. (51 )
- Frozen dataclasses with slots can be deep-copied (52 )

2.0.0rc1

This version includes a few changes from the previous beta (b24):

**Bugfixes:**
- Fix time truncation when transmuting datetimes
- Fix nested serialization of mappings, lists & serialization with standard json lib.

**Improvements:**
- Allow passing keyword args to downstream JSON encoder in `tojson()`

2.0.0b24

**Features:**
- Optional lazy evaluation of fields when serializing with `typic.primitive` or `MyObj.primitive`
- New high-level `typic.tojson` and `MyObj.tojson` methods for fast, easy serialization.
- New `json` extra for automatically installing typical's json serializer of choice.

2.0.0b23

Bugfixes:
- Proper validation of varargs in Strict-Mode (45)

2.0.0b22

**Features:**
- Optional lazy evaluation of fields when serializing with typic.primitive
or MyObj.primitive
- New high-level typic.tojson and MyObj.tojson methods for fast, easy serialization.
[Docs](https://python-typical.org/usage/advanced#helpers)
- New json extra for automatically installing typical's json serializer of choice.

Page 12 of 13

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.