Skip to content

Commit

Permalink
New port: www/py-fastapi: High-performance Python API Framework
Browse files Browse the repository at this point in the history
  • Loading branch information
neelchauhan committed May 13, 2021
1 parent 65b112f commit 432ac2b
Show file tree
Hide file tree
Showing 5 changed files with 60 additions and 0 deletions.
1 change: 1 addition & 0 deletions www/Makefile
Expand Up @@ -1574,6 +1574,7 @@
SUBDIR += py-enmerkar
SUBDIR += py-fake-useragent
SUBDIR += py-falcon
SUBDIR += py-fastapi
SUBDIR += py-feedgenerator
SUBDIR += py-flask
SUBDIR += py-flask-admin
Expand Down
21 changes: 21 additions & 0 deletions www/py-fastapi/Makefile
@@ -0,0 +1,21 @@
PORTNAME= fastapi
PORTVERSION= 0.65.1
CATEGORIES= www python
MASTER_SITES= CHEESESHOP
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}

MAINTAINER= nc@FreeBSD.org
COMMENT= High-performance Python API Framework

LICENSE= MIT
LICENSE_FILE= ${WRKSRC}/LICENSE

RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pydantic>0:devel/py-pydantic@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}starlette>0:www/py-starlette@${PY_FLAVOR}

USES= python:3.6+
USE_PYTHON= autoplist concurrent distutils

NO_ARCH= yes

.include <bsd.port.mk>
3 changes: 3 additions & 0 deletions www/py-fastapi/distinfo
@@ -0,0 +1,3 @@
TIMESTAMP = 1620940704
SHA256 (fastapi-0.65.1.tar.gz) = 478b7e0cbb52c9913b9903d88ae14195cb8a479c4596e0b2f2238d317840a7dc
SIZE (fastapi-0.65.1.tar.gz) = 5519965
11 changes: 11 additions & 0 deletions www/py-fastapi/files/patch-setup.py
@@ -0,0 +1,11 @@
--- setup.py.orig 1970-01-01 00:00:00 UTC
+++ setup.py
@@ -15,7 +15,7 @@ package_data = \
install_requires = \
['starlette ==0.14.2',
- 'pydantic >=1.6.2,!=1.7,!=1.7.1,!=1.7.2,!=1.7.3,!=1.8,!=1.8.1,<2.0.0']
+ 'pydantic >=1.6.2,<2.0.0']

extras_require = \
{'all': ['requests >=2.24.0,<3.0.0',
24 changes: 24 additions & 0 deletions www/py-fastapi/pkg-descr
@@ -0,0 +1,24 @@
FastAPI is a modern, fast (high-performance), web framework for building APIs
with Python 3.6+ based on standard Python type hints.

The key features are:

* Fast: Very high performance, on par with NodeJS and Go.

* Fast to code: Increase the speed to develop features by about 200% to 300%.

* Fewer bugs: Reduce about 40% of human (developer) induced errors.

* Intuitive: Great editor support. Completion everywhere. Less time debugging.

* Easy: Designed to be easy to use and learn. Less time reading docs.

* Short: Minimize code duplication. Multiple features from each parameter
declaration. Fewer bugs.

* Robust: Get production-ready code. With automatic interactive documentation.

* Standards-based: Based on (and fully compatible with) the open standards for
APIs: OpenAPI (previously known as Swagger) and JSON Schema.

WWW: https://github.com/tiangolo/fastapi

0 comments on commit 432ac2b

Please sign in to comment.