Pamela Fox · @pamelafox
2701 followers · 963 posts · Server fosstodon.org

Playing around with for streamed responses from ChatCompletions API. Swagger doesn't understand jsonlines natively, but the default display works pretty well!

#fastapi

Last updated 1 year ago

Pydantic · @pydantic
408 followers · 34 posts · Server fosstodon.org

Spreading the good vibes at the Sentry + FastAPI Berlin Meetup by @getsentry with the incredible trio: @marcelotryle, @samuelcolvin, and @hasanramezani! 💫✨

Learning, connecting, and having fun together as a team.

" 📸🤝😄

#meetup #pydantic #sentry #fastapi #opensource #goodvibesonly

Last updated 1 year ago

Snyk · @snyk
80 followers · 32 posts · Server masto.dsoc.io

👎 An insecure direct object reference () is a security vulnerability that occurs when a system’s implementation allows attackers to directly access & manipulate sensitive objects or resources without authorization checks.

Learn more about handling these vulnerabilities, including:

1️⃣ Types of IDOR
2️⃣ Creating a application with IDOR using
3️⃣ Identifying and fixing IDOR vulnerabilities

Read the full blog here: snyk.co/ufXcj

#idor #python #fastapi

Last updated 1 year ago

TechieChimp · @TechieChimp
1 followers · 32 posts · Server techhub.social

Learned about attaching debuggers to running processes early on, but understood its real value when dealing with a project's tangled startup scripts.

🔗 Read about it here:

medium.com/@_init_/how-to-atta

Ever encountered a similar situation? Let's chat!

#tdd #fastapi #python #softwareengineering #codingtips

Last updated 1 year ago

Snyk · @snyk
80 followers · 32 posts · Server masto.dsoc.io

👎 An insecure direct object reference () is a security vulnerability that occurs when a system’s implementation allows attackers to directly access & manipulate sensitive objects or resources without authorization checks.

Learn more about handling these vulnerabilities, including:

1️⃣ Types of IDOR
2️⃣ Creating a application with IDOR using
3️⃣ Identifying and fixing IDOR vulnerabilities

Read the full blog here: snyk.co/ufXci

#idor #python #fastapi

Last updated 1 year ago

Sergi · @sergi
34 followers · 520 posts · Server floss.social

Jinja2 Fragments 1.0.0 is out!
pypi.org/project/jinja2-fragme

Check it out if you use something like that benefits from template fragments.

#htmx #jinja #flask #sanic #fastapi #quart

Last updated 1 year ago

Mekuso · @mekuso
10 followers · 127 posts · Server fosstodon.org

Today's Python hot take: FastAPI is one of those sarcastic names, like Greenland (which isn't very green). The devs' claims of it being fast is some kind of joke. Because it's not actually very fast at all. A replacement package that's actually fast is Litestar, which also seems generally more wholesome.

#python #fastapi #LiteStar

Last updated 1 year ago

categulario 🐍 🦀 :manjaro: · @categulario
488 followers · 6348 posts · Server mstdn.mx

@toledano probé para un proyecto hace tiempo. No quedé encantado la verdad. A la fecha no tiene documentación de su y esto quiere decir que si quieres hacer algo que no cubre alguno de los tutoriales tienes que leer su código fuente.

Además está construido sobre la (falsa) premisa de que hay que reescribir todas las bibliotecas python usando

Ya teníamos async en python mucho antes de que la sintaxis entrara al lenguaje via y familia.

#fastapi #api #async #eventlet #greenlet

Last updated 1 year ago

derwaro :tux: :python: · @derwaro
16 followers · 163 posts · Server fosstodon.org

After extensive I found out, why I was not receiving callback request to my app: The callback requests were captured first by the complete stack running in which I forgot to shut down.... happy to still be sane :)

#debugging #fastapi #docker

Last updated 1 year ago

Estoy revisando la documentación de porque ¿qué mejor plan hay una noche de viernes en agosto que ponerme a estudiar documentación técnica? Así es mi vida: emociones fuertes y desenfreno 24/7 :blobcatgooglybongo:

El caso es que en prácticamente todos los ejemplos usan canciones de los y sólo con eso ya me tienen ganado.

Además el framework no tiene mala pinta. Está a medio camino entre y . Tendré que hacerme algún proyectillo a ver cómo se compara con éstos.

#fastapi #foofighters #django #flask

Last updated 1 year ago

Ketil Froyn · @kefir
161 followers · 449 posts · Server mas.to

So here's another pretty solid resource explicitly stating that WSGI URL routing treating %2F like / is unexpected.

Source: w3.org/Addressing/URL/4_URI_Re

#framework #web #flask #fastapi #wsgi #Python

Last updated 1 year ago

Ketil Froyn · @kefir
159 followers · 444 posts · Server mas.to

Many urldecode the url before doing url based routing. So they can't distinguish these URLs:

/users/tom/edit
/users/tom%2Fedit

I'm baffled. Does anyone have a quick reference describing why this is wrong? And as in this discussion, why a HTTP reverse proxy that unescapes URL-encodings before forwarding the request would be breaking all sorts of things, even though it is technically possible?


github.com/encode/starlette/pu

#flask #fastapi #Starlette #framework #frameworks #web #Python

Last updated 1 year ago

Luciano Ramalho · @ramgarlic
258 followers · 162 posts · Server fosstodon.org

@pamelafox I wrote "coroutine" 469 times in Fluent Python Second Edition.

The main chapter about asynchronous programming is framework-agnostic.

The examples use , , and , to show that `async/await` are not tied to a specific runtime event loop or library.

oreilly.com/library/view/fluen

#asyncio #fastapi #curio

Last updated 1 year ago

derwaro :tux: :python: · @derwaro
15 followers · 153 posts · Server fosstodon.org

Although I'm still torn between docs using emojis or not, I really really like the documentation for ! There is honestly no need for any tutorial. Everything's already there and explaining more than needed for fastapi only. Thanks, gracias, danke @tiangolo

#fastapi

Last updated 1 year ago

gram · @orsinium
105 followers · 448 posts · Server fosstodon.org

@ljmc

In general:
softwareengineering.stackexcha

In particular:
When running tests, you'd want to pass a connection created in a fixture so that each test is wrapped in a transaction that rolls back after each test. In your case, you'd need to monkey patch the global internal connection cache, which is implicit, error-prone, not thread-safe, and makes refactoring hard. A better option is if you can pass connection in the code you test explicitly or use dependency injection like the one has.

#fastapi

Last updated 1 year ago

Björn Ricks · @bjoernricks
45 followers · 233 posts · Server norden.social

Today I am going to play with and /#sqlalchemy. I am curious how it will work out because I am a big fan of the ORM. sqlalchemy always felt overengineered and more difficult to use.

#fastapi #sqlmodel #django #python

Last updated 1 year ago

David Vujic · @davidvujic
42 followers · 104 posts · Server mastodon.nu

A new post, about building modern FastAPI Microservices.

FastAPI is a good choice for developing Python APIs. It’s modern and easy to learn. When I think about it, I could say the same thing about Polylith. In the article, I describe how to combine the two for a nice developer experience.

davidvujic.blogspot.com/2023/0

#microservices #python #polylith #fastapi

Last updated 1 year ago

Riverfount :python_logo: · @riverfount
64 followers · 105 posts · Server hachyderm.io

Na pira por mais uma aula ao vivo no excelente curso da ministrado pelo fantástico @rochacbruno e

#pythonwebapi #linuxtips #vamosquevamos #python #fastapi #api #aprendersempre

Last updated 1 year ago

Riverfount :python_logo: · @riverfount
64 followers · 91 posts · Server hachyderm.io

Alguém aqui tb sente que a parte mais complexa ao se pensar um sistema, por mais simples que ele seja, é a modelagem de dados?? Surra dessas normalizações!

#python #postgresql #sqlmodel #fastapi

Last updated 1 year ago