The squire to your python projects.
Project description
Escudeiro
The squire to your Python projects.
Escudeiro is a modern, extensible toolkit for Python that brings together advanced data modeling, configuration, utilities, and high-performance Rust-powered extensions. It is designed for developers who want robust, ergonomic, and efficient solutions for building complex Python applications.
Features
-
Slots-first, Descriptor-friendly Data Classes
Escudeiro’sdatamodule is an attrs-like, slots-first data modeling system. It natively supports Python__slots__, advanced descriptors (like lazy fields and lazymethods), and is designed for extensibility.- Out-of-the-box support for lazy fields, slotted descriptors, and custom field types.
- Integrates seamlessly with async and sync lazy evaluation.
- Serialization/deserialization to dict/JSON, schema generation, and type variable resolution.
-
Configuration Management
Flexible configuration loading from environment variables, files, and mappings, with type-safe casting and validation. -
Utilities & Helpers
A rich set of helpers for type casting, lazy evaluation, async utilities, string manipulation, and more. -
Autodiscovery
Dynamic and static discovery of modules and objects at runtime, supporting plugin-like architectures. -
Rust-powered Performance
Performance-critical components are implemented in Rust (via PyO3), including file tree management and string utilities.
Installation
pip install escudeiro
Requires Python 3.12+.
Quick Start
Data modeling and descriptors:
from escudeiro.data import data, field
from escudeiro.lazyfields import lazyfield
@data
class User:
name: str = field()
age: int = field(default=0)
@lazyfield
def expensive_computation(self):
print("Computing...")
return self.age * 2
user = User(name="Alice", age=21)
print(user.expensive_computation) # "Computing..." then 42
print(user.expensive_computation) # 42 (cached)
Asynchronous lazy evaluation:
from escudeiro.lazyfields import asynclazyfield
import asyncio
@data
class Resource:
@asynclazyfield
async def load(self):
await asyncio.sleep(1)
return "loaded"
async def main():
r = Resource()
print(await r.load()) # "loaded"
asyncio.run(main())
File tree management with Rust:
from escudeiro.filetree import FileTree
tree = FileTree(base_dir="my_project")
vt = tree.virtual
vt.create_text_file("README.md", content="# My Project")
tree.write()
Integrations
- Optional support for Pydantic for data validation and settings management.
- Optional support for msgspec for high-performance serialization/deserialization.
Install with:
pip install escudeiro[pydantic,msgspec]
License
This project is licensed under the Apache License 2.0. See the LICENSE file for details.
Contributing
We welcome contributions! Please open an issue or submit a pull request on GitHub.
Changelog
See the CHANGELOG for a detailed list of changes and updates.
Author
Escudeiro is developed and maintained by me.
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
Built Distributions
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 escudeiro-0.2.11.tar.gz.
File metadata
- Download URL: escudeiro-0.2.11.tar.gz
- Upload date:
- Size: 212.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: maturin/1.8.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3d997eb4d8e8f41777edd6a0c3b69ea08958c473e239c13b74d25ffdefffdb01
|
|
| MD5 |
d1568451175c1b12d4969979a1f9e770
|
|
| BLAKE2b-256 |
4ead13eec12271f0a0346901bfc0c813539488843005c80d4698e85688a76a4b
|
File details
Details for the file escudeiro-0.2.11-cp313-cp313-musllinux_1_1_x86_64.whl.
File metadata
- Download URL: escudeiro-0.2.11-cp313-cp313-musllinux_1_1_x86_64.whl
- Upload date:
- Size: 1.2 MB
- Tags: CPython 3.13, musllinux: musl 1.1+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: maturin/1.8.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3b92821a8dc052b317faff71431fba9e747c00c0bbcc126e13da3f9df34519a9
|
|
| MD5 |
32036e00d7fb89cb16eb181dba8065a9
|
|
| BLAKE2b-256 |
b72a061e129651c74b058dd988769e17a53e8dfac697c09b32634581c5d5de9b
|
File details
Details for the file escudeiro-0.2.11-cp313-cp313-manylinux_2_34_x86_64.whl.
File metadata
- Download URL: escudeiro-0.2.11-cp313-cp313-manylinux_2_34_x86_64.whl
- Upload date:
- Size: 1.4 MB
- Tags: CPython 3.13, manylinux: glibc 2.34+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: maturin/1.8.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6812ceabb67092116142a7ff4f44ce05299d626ee85e8b71755497b19509838e
|
|
| MD5 |
74f811761edc54e3c2591f7b34680e99
|
|
| BLAKE2b-256 |
17a624f0faa36b28b238458623c7b01547c1706e24b6b4bac0fe8c1e6e4dd2ad
|
File details
Details for the file escudeiro-0.2.11-cp313-cp313-manylinux_2_28_x86_64.whl.
File metadata
- Download URL: escudeiro-0.2.11-cp313-cp313-manylinux_2_28_x86_64.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.13, manylinux: glibc 2.28+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: maturin/1.8.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
719573f9dd4123f7e2627f1f184186cbd5becec85569403b63d471bf075a402f
|
|
| MD5 |
d011b452aeee3f90fd194aff61c1b109
|
|
| BLAKE2b-256 |
834006c54514253077a34a9fd8f1290c322f44527faab1f2fa12ae4ff917a7a7
|
File details
Details for the file escudeiro-0.2.11-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: escudeiro-0.2.11-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.13, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: maturin/1.8.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
31cc770847a5e984005aa90755b9182ad6906986ed80081adb5a9208b3388080
|
|
| MD5 |
66f7f6d678e1354837468053095e660b
|
|
| BLAKE2b-256 |
95e26193b25eb214f379329c8cafff3b79bd9d8d4a0a6c958ee5648f46533ced
|
File details
Details for the file escudeiro-0.2.11-cp312-cp312-musllinux_1_1_x86_64.whl.
File metadata
- Download URL: escudeiro-0.2.11-cp312-cp312-musllinux_1_1_x86_64.whl
- Upload date:
- Size: 1.2 MB
- Tags: CPython 3.12, musllinux: musl 1.1+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: maturin/1.8.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0d55e40405758167b8cc45cd269bcee2f89b3b547716887159702a3c6b189d45
|
|
| MD5 |
993c3b950c2bd4cc183ed5bd54585d9d
|
|
| BLAKE2b-256 |
568c79164d2e065486d6d74b40cb70aefb6445a2d3b0e11c312f5045d5968f80
|
File details
Details for the file escudeiro-0.2.11-cp312-cp312-manylinux_2_34_x86_64.whl.
File metadata
- Download URL: escudeiro-0.2.11-cp312-cp312-manylinux_2_34_x86_64.whl
- Upload date:
- Size: 1.4 MB
- Tags: CPython 3.12, manylinux: glibc 2.34+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: maturin/1.8.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
830beb107f30289fb623ed8335c6a46d63fab50e9942c839a905061c15fab374
|
|
| MD5 |
60484ff28c6231a72bc889ffeae7e984
|
|
| BLAKE2b-256 |
595a09910f318a7d5645b92bd04c4dc8c25ff3394034c1a34989229bc95ea2ac
|
File details
Details for the file escudeiro-0.2.11-cp312-cp312-manylinux_2_28_x86_64.whl.
File metadata
- Download URL: escudeiro-0.2.11-cp312-cp312-manylinux_2_28_x86_64.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.12, manylinux: glibc 2.28+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: maturin/1.8.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
97dd53513ccc3053d35f5f5d7e61223bf44daf60837c7c7474be2578d7046494
|
|
| MD5 |
31a94becfdcf380405ffafbab197f62b
|
|
| BLAKE2b-256 |
a86f4d03f1c7be96f325cb5d5e08bf5a1b989a9723d5e9fb5170d446e2402abf
|
File details
Details for the file escudeiro-0.2.11-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: escudeiro-0.2.11-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.12, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: maturin/1.8.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c1efc0b48729a83a2be66af05bd420590af7903e555e87fc955d984e214e4373
|
|
| MD5 |
0f067aae1843d92768ab6d995de51aa9
|
|
| BLAKE2b-256 |
192a045ce4221fe3b3c11ce934128e2a05578b4442c1043eebe3e18427daa511
|