https://github.com/dynamic-graphics-inc/dgpy-libs
Dynamic Graphics Python libraries/modules
https://github.com/dynamic-graphics-inc/dgpy-libs
dgi library monorepo python3 type-annotations
Last synced: 10 months ago
JSON representation
Dynamic Graphics Python libraries/modules
- Host: GitHub
- URL: https://github.com/dynamic-graphics-inc/dgpy-libs
- Owner: dynamic-graphics-inc
- Created: 2020-05-29T19:14:56.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2025-03-27T08:03:33.000Z (11 months ago)
- Last Synced: 2025-04-02T08:11:08.672Z (11 months ago)
- Topics: dgi, library, monorepo, python3, type-annotations
- Language: Python
- Homepage: https://dgpy.dev/
- Size: 7.72 MB
- Stars: 24
- Watchers: 1
- Forks: 2
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- Changelog: changelog/changelog.json
Awesome Lists containing this project
README
# dgpy-libs
[](https://github.com/astral-sh/ruff)
Docs: [dynamic-graphics-inc.github.io/dgpy-libs](https://dynamic-graphics-inc.github.io/dgpy-libs/)
Repo: [github.com/dynamic-graphics-inc/dgpy-libs](https://github.com/dynamic-graphics-inc/dgpy-libs)
---
Dynamic Graphics python libraries, home of:
- Callable modules and packages
- Recursive list/gen comprehensions
- Nutty decorators
- Secret agent JSON Bourne
- The best package names around
- Notebooks with funky python
- Dynamic imports
## Libs
```
libs
├── aiopen
├── asyncify
├── dgpylibs
├── dgpytest
├── fmts
├── funkify
├── h5
├── jsonbourne
├── lager
├── listless
├── requires
├── shellfish
└── xtyping
```
**Install:** `pip install aiopen asyncify fmts funkify h5 jsonbourne lager listless requires shellfish xtyping`
### [aiopen](./libs/aiopen) ~ `pip install aiopen` ~ [](https://img.shields.io/pypi/wheel/aiopen.svg) [](https://img.shields.io/pypi/v/aiopen.svg) [](https://img.shields.io/pypi/pyversions/aiopen.svg)
### [asyncify](./libs/asyncify) ~ `pip install asyncify` ~ [](https://img.shields.io/pypi/wheel/asyncify.svg) [](https://img.shields.io/pypi/v/asyncify.svg) [](https://img.shields.io/pypi/pyversions/asyncify.svg)
### [dgpylibs](./libs/dgpylibs) ~ `pip install dgpylibs` ~ [](https://img.shields.io/pypi/wheel/dgpylibs.svg) [](https://img.shields.io/pypi/v/dgpylibs.svg) [](https://img.shields.io/pypi/pyversions/dgpylibs.svg)
### [dgpytest](./libs/dgpytest) ~ `pip install dgpytest` ~ [](https://img.shields.io/pypi/wheel/dgpytest.svg) [](https://img.shields.io/pypi/v/dgpytest.svg) [](https://img.shields.io/pypi/pyversions/dgpytest.svg)
### [fmts](./libs/fmts) ~ `pip install fmts` ~ [](https://img.shields.io/pypi/wheel/fmts.svg) [](https://img.shields.io/pypi/v/fmts.svg) [](https://img.shields.io/pypi/pyversions/fmts.svg)
### [funkify](./libs/funkify) ~ `pip install funkify` ~ [](https://img.shields.io/pypi/wheel/funkify.svg) [](https://img.shields.io/pypi/v/funkify.svg) [](https://img.shields.io/pypi/pyversions/funkify.svg)
### [h5](./libs/h5) ~ `pip install h5` ~ [](https://img.shields.io/pypi/wheel/h5.svg) [](https://img.shields.io/pypi/v/h5.svg) [](https://img.shields.io/pypi/pyversions/h5.svg)
### [jsonbourne](./libs/jsonbourne) ~ `pip install jsonbourne` ~ [](https://img.shields.io/pypi/wheel/jsonbourne.svg) [](https://img.shields.io/pypi/v/jsonbourne.svg) [](https://img.shields.io/pypi/pyversions/jsonbourne.svg)
### [lager](./libs/lager) ~ `pip install lager` ~ [](https://img.shields.io/pypi/wheel/lager.svg) [](https://img.shields.io/pypi/v/lager.svg) [](https://img.shields.io/pypi/pyversions/lager.svg)
### [listless](./libs/listless) ~ `pip install listless` ~ [](https://img.shields.io/pypi/wheel/listless.svg) [](https://img.shields.io/pypi/v/listless.svg) [](https://img.shields.io/pypi/pyversions/listless.svg)
### [requires](./libs/requires) ~ `pip install requires` ~ [](https://img.shields.io/pypi/wheel/requires.svg) [](https://img.shields.io/pypi/v/requires.svg) [](https://img.shields.io/pypi/pyversions/requires.svg)
### [shellfish](./libs/shellfish) ~ `pip install shellfish` ~ [](https://img.shields.io/pypi/wheel/shellfish.svg) [](https://img.shields.io/pypi/v/shellfish.svg) [](https://img.shields.io/pypi/pyversions/shellfish.svg)
### [xtyping](./libs/xtyping) ~ `pip install xtyping` ~ [](https://img.shields.io/pypi/wheel/xtyping.svg) [](https://img.shields.io/pypi/v/xtyping.svg) [](https://img.shields.io/pypi/pyversions/xtyping.svg)
## About
This repo (dgpy-libs) are the polished gems formed under intense pressure below the offices of [Dynamic Graphics Inc](http://dgi.com/). These pure-python libraries are all published on pip under the listed names.
### Design PhilosoPY
- dgpy-libs must have excellent names and be published on pip
- Embrace `async/await`
- Python 3.6 'n up, baby! (May move to 3.7 for `__future___.annotations`... tbd)
- Use type annotations everywhere
- No dead or commented out code
- Prefer pure-python & compiled-3rd-party-libs over writing packages with compiled extensions
- Use optional compiled-3rd-party-libs as optional dependencies to sneakily speed things up if present
- Offer integrations with the super-hot-fire modern python packages all the kids are using
- Optional dependencies are good! Missing optional deps should trigger an error msg that is helpful to installing the relevant dependency ONLY IF THE DEPENDENCY IS NEEDED.
- Test coverage is usually a dumb metric and 100% test coverage `!=` bug-free code (tests of dgpy-libs are slowly being migrated from internal/private repos to this repo)
### Third party friends
- [pydantic](https://pydantic-docs.helpmanual.io/); best python lib you will ever use
- [loguru](https://github.com/Delgan/loguru); base of lager
- [httpx](https://www.python-httpx.org/) ; don't use requests
- [attrs](https://github.com/python-attrs/attrs); pydantic alternative
- [poetry](https://github.com/python-poetry/poetry); best dep management python has to offer
- [orjson](https://github.com/ijl/orjson); fastest python json lib (opt dep of jsonbourne)
- [rapidjson/python-rapidjson](https://github.com/python-rapidjson/python-rapidjson); best mostly drop-in replacement for python's json module
- [h5py](https://github.com/h5py/h5py); base of h5
- [rich](https://github.com/willmcgugan/rich); best python console formatting lib
- [nox](https://github.com/theacodes/nox); like tox but less maddening
---
## Notebooks
```
notebooks/
├── cache_money.ipynb
├── filter_none.ipynb
├── json_parsing.ipynb
└── string_fmt.ipynb
```
- [Filtering None and False-y values](./notebooks/filter_none)
- [cache money! `functools.lru_cache`](./notebooks/cache_money)
- [String formatting funks](./notebooks/string_fmt)
- [JSON parsing vs plain-jane dictionaries](./notebooks/json_parsing)
---
## Contributor(s):
- [Jesse Rubin](https://github.com/jessekrubin) ~ `jesse@dgi.com` / `jessekrubin@gmail.com`
- [Dan Costello](https://github.com/dan-costello) ~ `dan@dgi.com` / `dan.costello2@gmail.com`
- Possibly you!?
## Contributing:
Plz do! Send me that PR!
---
## TODO:
- Have CI/CD auto build n publish
- Changelog (for real)
- Figure out why the combine-prs workflow doesn't trigger github actions...
- Update mkdocs to include all dgpy-libs