diff --git a/test-django-rest-framework-streaming/pyproject.toml b/test-django-rest-framework-streaming/pyproject.toml new file mode 100644 index 0000000..15a2fa3 --- /dev/null +++ b/test-django-rest-framework-streaming/pyproject.toml @@ -0,0 +1,16 @@ +[project] +name = "test-django-rest-framework-streaming" +version = "0" +requires-python = ">=3.12" + +dependencies = [ + "django>=5.2", + "djangorestframework>=3.16.0", + "gunicorn>=23.0.0", + "ipdb>=0.13.13", + "sentry-sdk[django]", + "uvicorn>=0.34.0", +] + +[tool.uv.sources] +sentry-sdk = { path = "../../sentry-python", editable = true } diff --git a/test-django-rest-framework-streaming/requirements.txt b/test-django-rest-framework-streaming/requirements.txt deleted file mode 100644 index 9ffe332..0000000 --- a/test-django-rest-framework-streaming/requirements.txt +++ /dev/null @@ -1,9 +0,0 @@ -Django -djangorestframework - -ipdb - --e ../../../code/sentry-python # sdk in a sibling folder to this projects folder - -gunicorn -uvicorn \ No newline at end of file diff --git a/test-django-rest-framework-streaming/run.sh b/test-django-rest-framework-streaming/run.sh index 596147f..5b965f5 100755 --- a/test-django-rest-framework-streaming/run.sh +++ b/test-django-rest-framework-streaming/run.sh @@ -1,19 +1,8 @@ #!/usr/bin/env bash +set -euo pipefail -# exit on first error -set -xe +if ! command -v uv &> /dev/null; then + curl -LsSf https://astral.sh/uv/install.sh | sh +fi -# create and activate virtual environment -python -m venv .venv -source .venv/bin/activate - -# Install (or update) requirements -python -m pip install -r requirements.txt - -# run migrations -# ./manage.py migrate - -# Run Django application on localhost:8000 -# ./manage.py runserver 0.0.0.0:8000 -# uvicorn mysite.asgi:application -gunicorn mysite.wsgi:application \ No newline at end of file +uv run gunicorn mysite.wsgi:application