GoogleCloudPlatform / GoogleCloudPlatform/functions-framework-python

Native support for Pydantic models for function_framework.typed

Abierto
#289 0 comentarios 1 reacción 0 asignados Ver en GitHub
enhancement P3
Lenguaje dominante
Python
Estrellas
968
Forks
128
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

Following https://github.com/GoogleCloudPlatform/functions-framework-python/pull/208#issuecomment-1832951749,
it will be great to have [Pydantic](https://docs.pydantic.dev/latest/) models supported natively. E.g.

```python

from pydantic import BaseModel

class HelloRequest(BaseModel):
name: str

@functions_framework.typed
def hello(hr: HelloRequest):
return f"Hello, {hr.name}"
```

Thank you!

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.