Python one-liner Python
/pixel.gif 요청에 빈 GIF로 응답하는 Python one-liner용 Python 스니펫입니다. GIF는 시작할 때 한 번만 디코딩합니다.
Python one-liner Python
python3 -c "import base64, pathlib; pathlib.Path('pixel.gif').write_bytes(base64.b64decode('R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw=='))"
이 스니펫은 실행해 보고, 반환된 바이트를 비교했습니다.
Python의 다른 예제
- AWS Lambda (Python)
- Google Cloud Run functions (Python)
- FastAPI
- Litestar
- Starlette
- Django
- Flask
- aiohttp
- Sanic
- Quart
- Falcon
- Robyn
- BlackSheep
- Tornado
- Bottle
- Pyramid
- Microdot (CPython and MicroPython)
- Raw ASGI (Uvicorn, Granian, Hypercorn)
- Raw WSGI (Gunicorn, uWSGI, mod_wsgi)
- Python standard library (http.server)
- FastHTML