Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/amarshall/boiga
Type-safe functional programming for Python
https://github.com/amarshall/boiga
functional-programming mypy python type-safe
Last synced: 3 months ago
JSON representation
Type-safe functional programming for Python
- Host: GitHub
- URL: https://github.com/amarshall/boiga
- Owner: amarshall
- License: mit
- Created: 2018-10-26T05:21:27.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2020-03-31T00:02:28.000Z (almost 5 years ago)
- Last Synced: 2024-10-09T09:59:02.024Z (4 months ago)
- Topics: functional-programming, mypy, python, type-safe
- Language: Python
- Homepage:
- Size: 28.3 KB
- Stars: 4
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Boiga: type-safe functional Python
[![PyPI package](https://img.shields.io/pypi/v/boiga.svg)](https://pypi.org/project/boiga/)
[![Build Status](https://secure.travis-ci.org/amarshall/boiga.svg?branch=master)](https://travis-ci.org/amarshall/boiga)Unlike most functional programming and monad libraries for Python, this is well-typed thanks to [PEP 484](https://www.python.org/dev/peps/pep-0484/) and [mypy](http://www.mypy-lang.org/).
## Type-safety
Boiga is only as type-safe as mypy permits. However, Boiga makes every attempt to ensure maximal type-safety. This includes:
- Enabling various mypy flags to increase strictness
- Type-checking all test code
- Having tests which programatically run mypy and ensure that expected type-check failures do indeed fail to type-check## Why “Boiga”?
Boiga is a genus of snake, often nicknamed “cat snakes”. The level of functional *cat*egory theory in this library is perhaps “un-Pythonic”. But it’s still a snake, just not a Python—a cat-eyed snake, perhaps. Also, most of the obvious package names were already taken.
## Mypy bugs found
- [Lambda as RHS for operator always gets inferred as Any](https://github.com/python/mypy/issues/5843)