Commit Graph

4 Commits

Author SHA1 Message Date
Chase Sterling 16fa3cdd90
Python SDK: change `merge_fragments` to take a string rather than list (#822)
* python sdk: change merge_fragments to take a string rather than list

* Change merge_fragments for fasthtml to accept a string rather than list
2025-04-11 13:01:09 -06:00
Chase Sterling e422bbdecc
Split various python SDK frameworks to different modules (#770)
* Allow passing arguments to the generator function in fastapi sdk

* Allow passing extra headers in FastAPI streaming response

* Keep method signature of upstream FastAPI streaming response

* Split out python sdk frameworks into their own modules
Make all python sdk frameworks mirror the native way of streaming responses

* Rename the sanic helper in python sdk to match sanic convention.
Add some type hinting to sanic helper

* ruff format new python sdk files
2025-03-29 08:05:42 -06:00
Jason Oppel f754ada278
Fix WSGI/ASGI issues in Django Example Project (#787)
* fix: support connection header over WSGI

Per spec, WSGI doesn't allow the connection header:
https://peps.python.org/pep-0333/#other-http-features

This commit works around that limitation and permits the connection
header over a WSGI connection.

* feat: add WSGI views/urls to Django example

* build(py-sdk): add django/datastar_py/daphne pkgs

Other related changes:
* Added "daphne" to INSTALLED_APPS to provide us with an ASGI runserver.
* Changed a setting to make ASGI the default.

* docs: add a README to the example Django project

The docs explain why Django devs should use ASGI and explain how to use
WSGI if needed.
2025-03-28 19:49:13 -06:00
Felix Ingram 3c6c29f3b9
SDK for python (#250) 2025-01-05 10:35:33 -06:00