thatlib

Faster pathlib for Python

MIT License

Stars
53
Committers
17

ThatLib

Using Pathlib can make your project +50x Slower

Use

Type-safe DotEnv

Thatlib has builtin support for Type-safe .env. Type-safe .env file is just a .env but Typed.

Types are enforced via a comment, so it is still a "vanilla" .env.

Type-safe .env file can be used with unsafe .env parsers, legacy parsers will ignore the comment.

Keys must be a non-empty ASCII string [a-zA-Z0-9_], keys are validated. Key-Value separator must be =.

Parses the same .env file from the vanilla implementation tests.

Several orders of magnitude faster than the vanilla implementation. Implementation is ~ 50 lines of code.

Examples:

# This is a comment
DB_HOST=localhost  # string
DB_USER=root       # string
DB_PASS="123"      # string
DB_TIMEOUT=42      # int
DELAY=3.14         # float
ACTIVE=true        # bool

Requisites

  • Python 1.x or 2.x or 3.x, 64Bit, CPython implementation.

PYPI

Dependencies

  • None.

💰➡️🍕

BEP20 Binance Smart Chain Network BSC

0xb78c4cf63274bb22f83481986157d234105ac17e

BTC Bitcoin Network

1Pnf45MgGgY32X4KDNJbutnpx96E4FxqVi

Lightning Network

[email protected]

BEP20 Binance Smart Chain Network BSC

0xb78c4cf63274bb22f83481986157d234105ac17e

ERC20 Ethereum Network

0xb78c4cf63274bb22f83481986157d234105ac17e

BEP20 Binance Smart Chain Network BSC

0xb78c4cf63274bb22f83481986157d234105ac17e

ERC20 Ethereum Network

0xb78c4cf63274bb22f83481986157d234105ac17e

TRC20 Tron Network

TWGft53WgWvH2mnqR8ZUXq1GD8M4gZ4Yfu

BEP20 Binance Smart Chain Network BSC

0xb78c4cf63274bb22f83481986157d234105ac17e

SOL Solana Network

FKaPSd8kTUpH7Q76d77toy1jjPGpZSxR4xbhQHyCMSGq

BEP20 Binance Smart Chain Network BSC

0xb78c4cf63274bb22f83481986157d234105ac17e

ADA Cardano Network

DdzFFzCqrht9Y1r4Yx7ouqG9yJNWeXFt69xavLdaeXdu4cQi2yXgNWagzh52o9k9YRh3ussHnBnDrg7v7W2hSXWXfBhbo2ooUKRFMieM

ERC20 Ethereum Network

0xb78c4cf63274bb22f83481986157d234105ac17e

ALGO Algorand Network

WM54DHVZQIQDVTHMPOH6FEZ4U2AU3OBPGAFTHSCYWMFE7ETKCUUOYAW24Q

DOT Network

13GdxHQbQA1K6i7Ctf781nQkhQhoVhGgUnrjn9EvcJnYWCEd

BEP20 Binance Smart Chain Network BSC

0xb78c4cf63274bb22f83481986157d234105ac17e

https://pay.binance.com/en/checkout/e92e536210fd4f62b426ea7ee65b49c3

Stars

@juancarlospaco@hamidb80@nikitavoloboev@mxschmitt@harrtho@kangkot@crox-safe@carno@xdroff@tumregels@Pebaz@Siss3l@daweedkob@xilicode@pietroppeter@linwaytin@thomas-mckay@hansalemaos@benzolium@T145@Xynonners@BlackNurse@xjzh123@JoeBarouneD

Badges
Extracted from project README
Benchmark Results Using Pathlib can make your project 50x Slower