drf-shapeless-serializers: Escape Django's Serializer Hell with Dynamic Runtime Magic
Hi
I built drf-shapeless-serializers to solve Django REST Framework's serializer hell. No more creating endless serializer classes for minor variations!
# What My Project Does
Eliminates serializer hell by enabling dynamic runtime configuration of DRF serializers, reducing boilerplate by up to 80% while maintaining full functionality.
# Target Audience
Production-ready for Django developers who need:
Multiple API versions
Flexible data representations
Complex nested serialization
Rapid API development
# Comparison
Unlike traditional DRF serializers that require static class definitions, drf-shapeless-serializers offers:
Runtime configuration instead of class-based
Dynamic nesting instead of fixed relationships
Minimal boilerplate instead of repetitive class definitions
Field-level control without subclassing
# Samples
# Comprehensive dynamic example
BookSerializer(
book,
fields='title', 'author', 'price',
renamefields={'price': 'retailprice'},
nested={
'author': {
'serializer': AuthorSerializer,
/r/Python
https://redd.it/1mloud2
Hi
I built drf-shapeless-serializers to solve Django REST Framework's serializer hell. No more creating endless serializer classes for minor variations!
# What My Project Does
Eliminates serializer hell by enabling dynamic runtime configuration of DRF serializers, reducing boilerplate by up to 80% while maintaining full functionality.
# Target Audience
Production-ready for Django developers who need:
Multiple API versions
Flexible data representations
Complex nested serialization
Rapid API development
# Comparison
Unlike traditional DRF serializers that require static class definitions, drf-shapeless-serializers offers:
Runtime configuration instead of class-based
Dynamic nesting instead of fixed relationships
Minimal boilerplate instead of repetitive class definitions
Field-level control without subclassing
# Samples
# Comprehensive dynamic example
BookSerializer(
book,
fields='title', 'author', 'price',
renamefields={'price': 'retailprice'},
nested={
'author': {
'serializer': AuthorSerializer,
/r/Python
https://redd.it/1mloud2
Reddit
From the Python community on Reddit: drf-shapeless-serializers: Escape Django's Serializer Hell with Dynamic Runtime Magic
Explore this post and more from the Python community
BS4 vs Selenium
In terms of web scraping capabilities, do they both basically do the same thing?
With Selenium being slower, but able to interact with JS websites, or sites that require clicking, etc
Compared to BS4 which is faster, but doesn't allow you to scrape from JS websites
Or am I wrong somewhere?
For my specific project, I'm using Selenium because I need to. Just wondering about the differences
Other questions:
1. Do people usually use them together?
2. How difficult are both to use? I'm still beginning on learning the docs for each
/r/Python
https://redd.it/1mlquvv
In terms of web scraping capabilities, do they both basically do the same thing?
With Selenium being slower, but able to interact with JS websites, or sites that require clicking, etc
Compared to BS4 which is faster, but doesn't allow you to scrape from JS websites
Or am I wrong somewhere?
For my specific project, I'm using Selenium because I need to. Just wondering about the differences
Other questions:
1. Do people usually use them together?
2. How difficult are both to use? I'm still beginning on learning the docs for each
/r/Python
https://redd.it/1mlquvv
Reddit
From the Python community on Reddit
Explore this post and more from the Python community
Why there is no polygon screenshot tool in the market? I had to make it myself
What My Project Does - Take a screenshot by drawing a precise polygon rather than being limited to a rectangular or manual free-form shape
Target Audience - Meant for production
Comparison - I was tired of windows built in screenshot where I had to draw the shape manually
Open sourced the proj. you can get it here: https://github.com/sultanate-sultan/polygon-screenshot-tool
/r/Python
https://redd.it/1mlizot
What My Project Does - Take a screenshot by drawing a precise polygon rather than being limited to a rectangular or manual free-form shape
Target Audience - Meant for production
Comparison - I was tired of windows built in screenshot where I had to draw the shape manually
Open sourced the proj. you can get it here: https://github.com/sultanate-sultan/polygon-screenshot-tool
/r/Python
https://redd.it/1mlizot
GitHub
GitHub - sultanate-sultan/polygon-screenshot-tool: There aren't any screenshot tool in market that has polygon feature, like you…
There aren't any screenshot tool in market that has polygon feature, like you draw bunch of straight lines to enclsoe the area you want to take screenshot of - sultanate-sultan/polygon-scre...
drf-shapeless-serializers: Escape Django's Serializer Hell with Dynamic Runtime Magic
Hi
I built drf-shapeless-serializers to solve Django REST Framework's serializer hell. No more creating endless serializer classes for minor variations!
# What this Project Does
Eliminates serializer hell by enabling dynamic runtime configuration of DRF serializers, reducing boilerplate by up to 80% while maintaining full functionality.
# Target Audience
Production-ready for Django developers who need:
Multiple API versions
Flexible data representations
Complex nested serialization
Rapid API development
# Comparison
Unlike traditional DRF serializers that require static class definitions, drf-shapeless-serializers offers:
Runtime configuration instead of class-based
Dynamic nesting instead of fixed relationships
Minimal boilerplate instead of repetitive class definitions
Field-level control without subclassing
# Samples
# Comprehensive dynamic example
BookSerializer(
book,
fields='title', 'author', 'price',
renamefields={'price': 'retailprice'},
nested={
'author': {
'serializer': AuthorSerializer,
/r/django
https://redd.it/1mlol6i
Hi
I built drf-shapeless-serializers to solve Django REST Framework's serializer hell. No more creating endless serializer classes for minor variations!
# What this Project Does
Eliminates serializer hell by enabling dynamic runtime configuration of DRF serializers, reducing boilerplate by up to 80% while maintaining full functionality.
# Target Audience
Production-ready for Django developers who need:
Multiple API versions
Flexible data representations
Complex nested serialization
Rapid API development
# Comparison
Unlike traditional DRF serializers that require static class definitions, drf-shapeless-serializers offers:
Runtime configuration instead of class-based
Dynamic nesting instead of fixed relationships
Minimal boilerplate instead of repetitive class definitions
Field-level control without subclassing
# Samples
# Comprehensive dynamic example
BookSerializer(
book,
fields='title', 'author', 'price',
renamefields={'price': 'retailprice'},
nested={
'author': {
'serializer': AuthorSerializer,
/r/django
https://redd.it/1mlol6i
Reddit
From the django community on Reddit: drf-shapeless-serializers: Escape Django's Serializer Hell with Dynamic Runtime Magic
Explore this post and more from the django community
The Recursive Leap of Faith, Explained (with examples in Python)
https://inventwithpython.com/blog/leap-of-faith.html
I've written a short tutorial about what exactly the vague "leap of faith" technique for writing recursive functions means, with factorial and permutation examples. The code is written in Python.
TL;DR:
1. Start by figuring out the data types of the parameters and return value.
2. Next, implement the base case.
3. Take a leap of faith and assume your recursive function magically returns the correct value, and write your recursive case.
4. First Caveat: The argument to the recursive function call cannot be the original argument.
5. Second Caveat: The argument to the recursive function call must ALWAYS get closer to the base case.
I also go into why so many other tutorials fail to explain what "leap of faith" actually is and the unstated assumptions they make. There's also the explanation for the concept that ChatGPT gives, and how it matches the deficiencies of other recursion tutorials.
I also have this absolutely demented (but technically correct!) implementation of recursive factorial:
def factorial(number):
if number < 0: raise Exception('number must be a positive integer')
if number % 1 != 0: raise Exception('number must be an integer')
/r/Python
https://redd.it/1mlys26
https://inventwithpython.com/blog/leap-of-faith.html
I've written a short tutorial about what exactly the vague "leap of faith" technique for writing recursive functions means, with factorial and permutation examples. The code is written in Python.
TL;DR:
1. Start by figuring out the data types of the parameters and return value.
2. Next, implement the base case.
3. Take a leap of faith and assume your recursive function magically returns the correct value, and write your recursive case.
4. First Caveat: The argument to the recursive function call cannot be the original argument.
5. Second Caveat: The argument to the recursive function call must ALWAYS get closer to the base case.
I also go into why so many other tutorials fail to explain what "leap of faith" actually is and the unstated assumptions they make. There's also the explanation for the concept that ChatGPT gives, and how it matches the deficiencies of other recursion tutorials.
I also have this absolutely demented (but technically correct!) implementation of recursive factorial:
def factorial(number):
if number < 0: raise Exception('number must be a positive integer')
if number % 1 != 0: raise Exception('number must be an integer')
/r/Python
https://redd.it/1mlys26
Inventwithpython
The Recursive Leap of Faith, Explained - Invent with Python
djhtmx: Stateful components using HTMX
When writing an app with HTMX, there are recurrent patterns that you deal with:
\- Endpoints for hx-post, hx-get, ...
\- Parameters that need to be validated when passed to those enpoints.
\- Certain template rendering patterns, where some templates render partially with the same context.
So 4 years ago I thought what if we make React/Vue like components that have, state, parameters, event handlers, and a template, and this is what you get.
DjHTMX: github.com/edelvalle/djhtmx
I had been using this for 5 years now in production, it had evolved a lot over the years and just published it as 1.0.0 last week.
At first it had all the state of the component on the front-end and was quite simple, but as the system I develop with this became more complex sometimes a single click was sending 1Mb in post to the back-end. That's why now the state of the components is stored in Redis.
This is an opinionated way on how to use HTMX, so it will have some drawbacks, but it will not prevent you from using HTMX on whatever way you are using it already.
Hope to get some feedback.
/r/django
https://redd.it/1mlw5i0
When writing an app with HTMX, there are recurrent patterns that you deal with:
\- Endpoints for hx-post, hx-get, ...
\- Parameters that need to be validated when passed to those enpoints.
\- Certain template rendering patterns, where some templates render partially with the same context.
So 4 years ago I thought what if we make React/Vue like components that have, state, parameters, event handlers, and a template, and this is what you get.
DjHTMX: github.com/edelvalle/djhtmx
I had been using this for 5 years now in production, it had evolved a lot over the years and just published it as 1.0.0 last week.
At first it had all the state of the component on the front-end and was quite simple, but as the system I develop with this became more complex sometimes a single click was sending 1Mb in post to the back-end. That's why now the state of the components is stored in Redis.
This is an opinionated way on how to use HTMX, so it will have some drawbacks, but it will not prevent you from using HTMX on whatever way you are using it already.
Hope to get some feedback.
/r/django
https://redd.it/1mlw5i0
GitHub
GitHub - edelvalle/djhtmx: Interactive UI components for Django using htmx.org
Interactive UI components for Django using htmx.org - edelvalle/djhtmx
Sunday Daily Thread: What's everyone working on this week?
# Weekly Thread: What's Everyone Working On This Week? 🛠️
Hello /r/Python! It's time to share what you've been working on! Whether it's a work-in-progress, a completed masterpiece, or just a rough idea, let us know what you're up to!
## How it Works:
1. Show & Tell: Share your current projects, completed works, or future ideas.
2. Discuss: Get feedback, find collaborators, or just chat about your project.
3. Inspire: Your project might inspire someone else, just as you might get inspired here.
## Guidelines:
Feel free to include as many details as you'd like. Code snippets, screenshots, and links are all welcome.
Whether it's your job, your hobby, or your passion project, all Python-related work is welcome here.
## Example Shares:
1. Machine Learning Model: Working on a ML model to predict stock prices. Just cracked a 90% accuracy rate!
2. Web Scraping: Built a script to scrape and analyze news articles. It's helped me understand media bias better.
3. Automation: Automated my home lighting with Python and Raspberry Pi. My life has never been easier!
Let's build and grow together! Share your journey and learn from others. Happy coding! 🌟
/r/Python
https://redd.it/1mm446r
# Weekly Thread: What's Everyone Working On This Week? 🛠️
Hello /r/Python! It's time to share what you've been working on! Whether it's a work-in-progress, a completed masterpiece, or just a rough idea, let us know what you're up to!
## How it Works:
1. Show & Tell: Share your current projects, completed works, or future ideas.
2. Discuss: Get feedback, find collaborators, or just chat about your project.
3. Inspire: Your project might inspire someone else, just as you might get inspired here.
## Guidelines:
Feel free to include as many details as you'd like. Code snippets, screenshots, and links are all welcome.
Whether it's your job, your hobby, or your passion project, all Python-related work is welcome here.
## Example Shares:
1. Machine Learning Model: Working on a ML model to predict stock prices. Just cracked a 90% accuracy rate!
2. Web Scraping: Built a script to scrape and analyze news articles. It's helped me understand media bias better.
3. Automation: Automated my home lighting with Python and Raspberry Pi. My life has never been easier!
Let's build and grow together! Share your journey and learn from others. Happy coding! 🌟
/r/Python
https://redd.it/1mm446r
Reddit
From the Python community on Reddit
Explore this post and more from the Python community
YAMosse - find timestamps for common sounds in sound files
What My Project Does:
YAMosse is my interface for TensorFlow's YAMNet model. It can be used to identify the timestamps of specific sounds, or create a transcript of the sounds in a sound file. For example, you could use it to tell which parts of a sound file contain music, or which parts contain speech. You can use it as a GUI or use it on the command line.
https://github.com/tomysshadow/YAMosse
I created this application because a while back, I wanted an app that could give me a list of timestamps of some sounds in a sound file. I knew the technology for this definitely existed, what with machine learning and all, but I was surprised to find there didn't seem to be any existing program I could just drag and drop a file into, in order to detect the sounds that were in it. Instead, when I Googled how to get a list of timestamps of sounds in a sound file, all I got were tutorials about how to write code to do it yourself in Python.
Perhaps Google was catering to me because I usually use it to look up programming questions, but I didn't want to have to write a bunch of
/r/Python
https://redd.it/1mli3b5
What My Project Does:
YAMosse is my interface for TensorFlow's YAMNet model. It can be used to identify the timestamps of specific sounds, or create a transcript of the sounds in a sound file. For example, you could use it to tell which parts of a sound file contain music, or which parts contain speech. You can use it as a GUI or use it on the command line.
https://github.com/tomysshadow/YAMosse
I created this application because a while back, I wanted an app that could give me a list of timestamps of some sounds in a sound file. I knew the technology for this definitely existed, what with machine learning and all, but I was surprised to find there didn't seem to be any existing program I could just drag and drop a file into, in order to detect the sounds that were in it. Instead, when I Googled how to get a list of timestamps of sounds in a sound file, all I got were tutorials about how to write code to do it yourself in Python.
Perhaps Google was catering to me because I usually use it to look up programming questions, but I didn't want to have to write a bunch of
/r/Python
https://redd.it/1mli3b5
GitHub
GitHub - tomysshadow/YAMosse: Get timestamps for sound files by harnessing the power of pristine quality yams.
Get timestamps for sound files by harnessing the power of pristine quality yams. - tomysshadow/YAMosse
Building a Django IDE... with Django itself (starting Sept 1st, live on stream)
Hey Django devs 👋
I'm about to attempt something absolutely META: building a Django IDE using Django as the backend + PyQt for the desktop frontend.
What I'm building:
- Visual model editor that auto-updates your model.py files in real-time
- One-click Django app creation and management
- API builder with automatic routing generation
- Serializer creation and management
- All the repetitive Django stuff automated with a proper desktop GUI
- IDE to have fun coding
I'm building this completely in public, live streaming the entire development process starting September 1st. No polished tutorials - just raw problem-solving, PyQt struggles, and hopefully some breakthrough moments.
Why this matters:
I want to prove Python can build industrial-grade desktop applications that people will actually use and pay for. Plus, Django deserves better tooling than constantly switching between terminal, editor, and browser.
I already built a proof-of-concept web version in a week, but the desktop version with PyQt is... well, let's just say it's humbling 😅
What you'll see:
- Real PyQt learning curve (it's brutal)
- Django powering Django development
- Architecture decisions made in real-time
- Community collaboration and feedback
- The full journey from code to paying customers
Anyone interested in following along or contributing? I'll be documenting everything and open to collaboration.
Tech stack:
- Backend: Django +
/r/django
https://redd.it/1ml94xn
Hey Django devs 👋
I'm about to attempt something absolutely META: building a Django IDE using Django as the backend + PyQt for the desktop frontend.
What I'm building:
- Visual model editor that auto-updates your model.py files in real-time
- One-click Django app creation and management
- API builder with automatic routing generation
- Serializer creation and management
- All the repetitive Django stuff automated with a proper desktop GUI
- IDE to have fun coding
I'm building this completely in public, live streaming the entire development process starting September 1st. No polished tutorials - just raw problem-solving, PyQt struggles, and hopefully some breakthrough moments.
Why this matters:
I want to prove Python can build industrial-grade desktop applications that people will actually use and pay for. Plus, Django deserves better tooling than constantly switching between terminal, editor, and browser.
I already built a proof-of-concept web version in a week, but the desktop version with PyQt is... well, let's just say it's humbling 😅
What you'll see:
- Real PyQt learning curve (it's brutal)
- Django powering Django development
- Architecture decisions made in real-time
- Community collaboration and feedback
- The full journey from code to paying customers
Anyone interested in following along or contributing? I'll be documenting everything and open to collaboration.
Tech stack:
- Backend: Django +
/r/django
https://redd.it/1ml94xn
Reddit
From the django community on Reddit: Building a Django IDE... with Django itself (starting Sept 1st, live on stream)
Explore this post and more from the django community
Question about Django Ninja and method order for POST/GET
Hey everyone. Yesterday I had a weird issue while working with Django Ninja. I created an API instance then registered my controllers all pretty standard. One of my controllers had a few
The problem is that whenever I tried calling the
# Response body
Method not allowed
# Response headers
access-control-allow-credentials: true
access-control-allow-origin: http://localhost:8000
allow: GET
content-length: 18
content-type: text/html; charset=utf-8
cross-origin-opener-policy: same-origin
date: Fri,08 Aug 2025 12:52:29 GMT
referrer-policy: same-origin
server: WSGIServer/0.2 CPython/3.13.6
vary: origin
x-content-type-options: nosniff
x-frame-options: DENY
After hours of debugging, I found a Stack Overflow answer suggesting that the order of method definitions in the controller matters, but also doesn't know why. I moved my POST method above the GET ones in the same controller, and suddenly it worked without changing anything else.
Now I’m wondering:
Why would Django Ninja behave this way?
Is this a known quirk of the framework or related to how
/r/djangolearning
https://redd.it/1mkumo4
Hey everyone. Yesterday I had a weird issue while working with Django Ninja. I created an API instance then registered my controllers all pretty standard. One of my controllers had a few
GET endpoints first, and then a POST endpoint defined below them.The problem is that whenever I tried calling the
POST endpoint, I got this response:# Response body
Method not allowed
# Response headers
access-control-allow-credentials: true
access-control-allow-origin: http://localhost:8000
allow: GET
content-length: 18
content-type: text/html; charset=utf-8
cross-origin-opener-policy: same-origin
date: Fri,08 Aug 2025 12:52:29 GMT
referrer-policy: same-origin
server: WSGIServer/0.2 CPython/3.13.6
vary: origin
x-content-type-options: nosniff
x-frame-options: DENY
After hours of debugging, I found a Stack Overflow answer suggesting that the order of method definitions in the controller matters, but also doesn't know why. I moved my POST method above the GET ones in the same controller, and suddenly it worked without changing anything else.
Now I’m wondering:
Why would Django Ninja behave this way?
Is this a known quirk of the framework or related to how
/r/djangolearning
https://redd.it/1mkumo4
Stack Overflow
Method not allowed in fresh django-ninja-extra project
I cant make a post request in my project, now i created a fresh project, because i thought it was a configuration problem. But the Problem persists.
The problem is that when i try to make a post re...
The problem is that when i try to make a post re...
DRF Auth Kit - The complete DRF auth package you'll ever need
Hi all, I recently released the DRF Auth Kit package, which is an improvement over existing auth solutions like dj-rest-auth and django-trench. Although it's still in beta (I've completed all the work, but need a bit more testing to ensure it works correctly in production).
Key Features:
- Multiple Authentication Types (JWT, DRF Token, Custom)
- Complete User Management (registration, password reset, email verification)
- Multi-Factor Authentication with backup codes
- Social Authentication (50+ providers via Django Allauth)
- Full Type Safety with mypy/pyright compatibility
- Automatic OpenAPI schema generation with DRF Spectacular
- Internationalization support for 57 languages
- Enhanced HTTP-only cookies with modern security
- Zero configuration setup with intelligent defaults
- Easy customization without breaking functionality
What makes it different:
- Conditional URL patterns based on settings
- Dynamic settings system with lazy imports
- Interactive API documentation out of the box
- Full type safety.
Perfect for projects needing modern authentication with type safety, comprehensive API documentation, and enhanced security, but easy to customize the auth flow to your needs.
Resources:
- Documentation: https://drf-auth-kit.readthedocs.io
- GitHub: https://github.com/forthecraft/drf-auth-kit
- Installation: pip install drf-auth-kitall
Would love to hear your feedback and contributions!
/r/django
https://redd.it/1mmcw7r
Hi all, I recently released the DRF Auth Kit package, which is an improvement over existing auth solutions like dj-rest-auth and django-trench. Although it's still in beta (I've completed all the work, but need a bit more testing to ensure it works correctly in production).
Key Features:
- Multiple Authentication Types (JWT, DRF Token, Custom)
- Complete User Management (registration, password reset, email verification)
- Multi-Factor Authentication with backup codes
- Social Authentication (50+ providers via Django Allauth)
- Full Type Safety with mypy/pyright compatibility
- Automatic OpenAPI schema generation with DRF Spectacular
- Internationalization support for 57 languages
- Enhanced HTTP-only cookies with modern security
- Zero configuration setup with intelligent defaults
- Easy customization without breaking functionality
What makes it different:
- Conditional URL patterns based on settings
- Dynamic settings system with lazy imports
- Interactive API documentation out of the box
- Full type safety.
Perfect for projects needing modern authentication with type safety, comprehensive API documentation, and enhanced security, but easy to customize the auth flow to your needs.
Resources:
- Documentation: https://drf-auth-kit.readthedocs.io
- GitHub: https://github.com/forthecraft/drf-auth-kit
- Installation: pip install drf-auth-kitall
Would love to hear your feedback and contributions!
/r/django
https://redd.it/1mmcw7r
Kreuzberg v3.11: the ultimate Python text extraction library
Hi Peeps,
I'm excited to share Kreuzberg v3.11, which has evolved significantly since the v3.1 release I shared here last time. We've been hard at work improving performance, adding features, and most importantly - benchmarking against competitors. You can see the full benchmarks here and the changelog here.
For those unfamiliar - Kreuzberg is a document intelligence framework that offers fast, lightweight, and highly performant CPU-based text extraction from virtually any document format.
## Major Improvements Since v3.1:
- Performance overhaul: 30-50% faster extraction based on deep profiling (v3.8)
- Document classification: AI-powered automatic document type detection - invoices, contracts, forms, etc. (v3.9)
- MCP server integration: Direct integration with Claude and other AI assistants (v3.7)
- PDF password support: Handle encrypted documents with the crypto extra (v3.10)
- Python 3.10+ optimizations: Match statements, dict merge operators for cleaner code (v3.11)
- CLI tool: Extract documents directly via
- REST API: Dockerized API server for microservice architectures
- License cleanup: Removed GPL dependencies for pure MIT compatibility (v3.5)
## Target Audience
The library is ideal for developers building RAG (Retrieval-Augmented Generation) applications, document processing pipelines, or anyone needing reliable text extraction. It's particularly suited for:
- Teams needing local processing without cloud dependencies
- Serverless/containerized deployments (71MB footprint)
- Applications requiring both sync
/r/Python
https://redd.it/1mmcufh
Hi Peeps,
I'm excited to share Kreuzberg v3.11, which has evolved significantly since the v3.1 release I shared here last time. We've been hard at work improving performance, adding features, and most importantly - benchmarking against competitors. You can see the full benchmarks here and the changelog here.
For those unfamiliar - Kreuzberg is a document intelligence framework that offers fast, lightweight, and highly performant CPU-based text extraction from virtually any document format.
## Major Improvements Since v3.1:
- Performance overhaul: 30-50% faster extraction based on deep profiling (v3.8)
- Document classification: AI-powered automatic document type detection - invoices, contracts, forms, etc. (v3.9)
- MCP server integration: Direct integration with Claude and other AI assistants (v3.7)
- PDF password support: Handle encrypted documents with the crypto extra (v3.10)
- Python 3.10+ optimizations: Match statements, dict merge operators for cleaner code (v3.11)
- CLI tool: Extract documents directly via
uvx kreuzberg extract- REST API: Dockerized API server for microservice architectures
- License cleanup: Removed GPL dependencies for pure MIT compatibility (v3.5)
## Target Audience
The library is ideal for developers building RAG (Retrieval-Augmented Generation) applications, document processing pipelines, or anyone needing reliable text extraction. It's particularly suited for:
- Teams needing local processing without cloud dependencies
- Serverless/containerized deployments (71MB footprint)
- Applications requiring both sync
/r/Python
https://redd.it/1mmcufh
GitHub
Releases · Goldziher/kreuzberg
Document intelligence framework for Python - Extract text, metadata, and structured data from PDFs, images, Office documents, and more. Built on Pandoc, PDFium, and Tesseract. - Goldziher/kreuzberg
Limekit – Build cross-platform GUIs in lua with PySide6
Hi Python community! 👋
I’ve just released **Limekit** — a wrapper framework for PySide6 that lets you build cross-platform desktop GUIs in Lua… and you can have a window on screen with just 2 lines of code. 🚀
# What my project does
Limekit lets developers write GUI apps entirely in Lua while using Python’s PySide6 under the hood. The Python layer runs entirely inside the engine — Lua developers never have to touch Python code. Just:
1. Install Python
2. Install Limekit (distributed as wheel for now)
3. Forget about Python and start coding in Lua
I even built a 100% Lua IDE (Limer-Limekit) to prove it works.
# Target audience
Lua developers who want native, cross-platform GUI apps without dealing with C++ bindings or complex cross-compilation setups
Python developers curious about embedding Lua and mixing languages for fun or lightweight scripting in their apps
Hobbyists who want a fast, small-footprint language with access to a modern GUI toolkit
# Comparison
Against Lua GUI bindings in C/C++: No need to compile or configure for each platform — Python acts as the bridge
To appreciate how the engine works or how the "magic" really happens , head over to https://github.com/mitosisX/Limekit/
THE IDE (for developing the Limekit apps, 100% lua)
https://github.com/mitosisX/Limer-Limekit
/r/Python
https://redd.it/1mmea2j
Hi Python community! 👋
I’ve just released **Limekit** — a wrapper framework for PySide6 that lets you build cross-platform desktop GUIs in Lua… and you can have a window on screen with just 2 lines of code. 🚀
# What my project does
Limekit lets developers write GUI apps entirely in Lua while using Python’s PySide6 under the hood. The Python layer runs entirely inside the engine — Lua developers never have to touch Python code. Just:
1. Install Python
2. Install Limekit (distributed as wheel for now)
3. Forget about Python and start coding in Lua
I even built a 100% Lua IDE (Limer-Limekit) to prove it works.
# Target audience
Lua developers who want native, cross-platform GUI apps without dealing with C++ bindings or complex cross-compilation setups
Python developers curious about embedding Lua and mixing languages for fun or lightweight scripting in their apps
Hobbyists who want a fast, small-footprint language with access to a modern GUI toolkit
# Comparison
Against Lua GUI bindings in C/C++: No need to compile or configure for each platform — Python acts as the bridge
To appreciate how the engine works or how the "magic" really happens , head over to https://github.com/mitosisX/Limekit/
THE IDE (for developing the Limekit apps, 100% lua)
https://github.com/mitosisX/Limer-Limekit
/r/Python
https://redd.it/1mmea2j
GitHub
GitHub - mitosisX/Limekit: Behold! The engine for cross platform GUI development in lua; the miracle we've all been waiting for.…
Behold! The engine for cross platform GUI development in lua; the miracle we've all been waiting for. Right? - mitosisX/Limekit
Simple tool : ImageDraw() UI helper - draw shapes and get x0y0
In a Python project I needed to draw a few shapes and I found it quite cumbersome to make up coordinates (x0 y0) and such.
I made this little UI helper so maybe it'll help someone else : https://github.com/ozh/drawuihelper
/r/Python
https://redd.it/1mmh9gl
In a Python project I needed to draw a few shapes and I found it quite cumbersome to make up coordinates (x0 y0) and such.
I made this little UI helper so maybe it'll help someone else : https://github.com/ozh/drawuihelper
/r/Python
https://redd.it/1mmh9gl
Reddit
From the Python community on Reddit: Simple tool : ImageDraw() UI helper - draw shapes and get x0y0
Explore this post and more from the Python community
Pybotchi 101: Simple MCP Integration
https://github.com/amadolid/pybotchi
- What My Project Does
- Nested Intent-Based Supervisor Agent Builder
- Target Audience
- for production
- Comparison
- lightweight, framework agnostic and simpler way of declaring graph.
# Topic: MCP Integration
# As Client
### Prerequisite
- LLM Declaration
```python
from pybotchi import LLM
from langchain_openai import ChatOpenAI
LLM.add(
base = ChatOpenAI(.....)
)
```
- MCP Server (`MCP-Atlassian`)
> docker run --rm -p 9000:9000 -i --env-file your-env.env ghcr.io/sooperset/mcp-atlassian:latest --transport streamable-http --port 9000 -vv
### Simple Pybotchi Action
```python
from pybotchi import ActionReturn, MCPAction, MCPConnection
class AtlassianAgent(MCPAction):
"""Atlassian query."""
__mcp_connections__ = [
MCPConnection("jira", "http://0.0.0.0:9000/mcp", require_integration=False)
]
async def post(self, context):
readable_response = await context.llm.ainvoke(context.prompts)
await context.add_response(self, readable_response.content)
return ActionReturn.END
```
- `post` is only recommended if mcp tools responses is not in natural language yet.
- You can leverage `post` or `commit_context` for final response generation
### View Graph
```python
from asyncio import run
from pybotchi import graph
print(run(graph(AtlassianAgent)))
```
#### **Result**
```
flowchart TD
mcp.jira.JiraCreateIssueLink[mcp.jira.JiraCreateIssueLink]
mcp.jira.JiraUpdateSprint[mcp.jira.JiraUpdateSprint]
mcp.jira.JiraDownloadAttachments[mcp.jira.JiraDownloadAttachments]
mcp.jira.JiraDeleteIssue[mcp.jira.JiraDeleteIssue]
mcp.jira.JiraGetTransitions[mcp.jira.JiraGetTransitions]
mcp.jira.JiraUpdateIssue[mcp.jira.JiraUpdateIssue]
mcp.jira.JiraSearch[mcp.jira.JiraSearch]
mcp.jira.JiraGetAgileBoards[mcp.jira.JiraGetAgileBoards]
mcp.jira.JiraAddComment[mcp.jira.JiraAddComment]
mcp.jira.JiraGetSprintsFromBoard[mcp.jira.JiraGetSprintsFromBoard]
mcp.jira.JiraGetSprintIssues[mcp.jira.JiraGetSprintIssues]
__main__.AtlassianAgent[__main__.AtlassianAgent]
mcp.jira.JiraLinkToEpic[mcp.jira.JiraLinkToEpic]
mcp.jira.JiraCreateIssue[mcp.jira.JiraCreateIssue]
mcp.jira.JiraBatchCreateIssues[mcp.jira.JiraBatchCreateIssues]
mcp.jira.JiraSearchFields[mcp.jira.JiraSearchFields]
mcp.jira.JiraGetWorklog[mcp.jira.JiraGetWorklog]
mcp.jira.JiraTransitionIssue[mcp.jira.JiraTransitionIssue]
mcp.jira.JiraGetProjectVersions[mcp.jira.JiraGetProjectVersions]
mcp.jira.JiraGetUserProfile[mcp.jira.JiraGetUserProfile]
mcp.jira.JiraGetBoardIssues[mcp.jira.JiraGetBoardIssues]
mcp.jira.JiraGetProjectIssues[mcp.jira.JiraGetProjectIssues]
mcp.jira.JiraAddWorklog[mcp.jira.JiraAddWorklog]
mcp.jira.JiraCreateSprint[mcp.jira.JiraCreateSprint]
mcp.jira.JiraGetLinkTypes[mcp.jira.JiraGetLinkTypes]
mcp.jira.JiraRemoveIssueLink[mcp.jira.JiraRemoveIssueLink]
mcp.jira.JiraGetIssue[mcp.jira.JiraGetIssue]
mcp.jira.JiraBatchGetChangelogs[mcp.jira.JiraBatchGetChangelogs]
__main__.AtlassianAgent --> mcp.jira.JiraCreateIssueLink
__main__.AtlassianAgent --> mcp.jira.JiraGetLinkTypes
__main__.AtlassianAgent --> mcp.jira.JiraDownloadAttachments
__main__.AtlassianAgent --> mcp.jira.JiraAddWorklog
__main__.AtlassianAgent --> mcp.jira.JiraRemoveIssueLink
__main__.AtlassianAgent --> mcp.jira.JiraCreateIssue
__main__.AtlassianAgent --> mcp.jira.JiraLinkToEpic
__main__.AtlassianAgent --> mcp.jira.JiraGetSprintsFromBoard
__main__.AtlassianAgent --> mcp.jira.JiraGetAgileBoards
__main__.AtlassianAgent --> mcp.jira.JiraBatchCreateIssues
__main__.AtlassianAgent --> mcp.jira.JiraSearchFields
__main__.AtlassianAgent --> mcp.jira.JiraGetSprintIssues
__main__.AtlassianAgent --> mcp.jira.JiraSearch
__main__.AtlassianAgent
/r/Python
https://redd.it/1mmo3gx
https://github.com/amadolid/pybotchi
- What My Project Does
- Nested Intent-Based Supervisor Agent Builder
- Target Audience
- for production
- Comparison
- lightweight, framework agnostic and simpler way of declaring graph.
# Topic: MCP Integration
# As Client
### Prerequisite
- LLM Declaration
```python
from pybotchi import LLM
from langchain_openai import ChatOpenAI
LLM.add(
base = ChatOpenAI(.....)
)
```
- MCP Server (`MCP-Atlassian`)
> docker run --rm -p 9000:9000 -i --env-file your-env.env ghcr.io/sooperset/mcp-atlassian:latest --transport streamable-http --port 9000 -vv
### Simple Pybotchi Action
```python
from pybotchi import ActionReturn, MCPAction, MCPConnection
class AtlassianAgent(MCPAction):
"""Atlassian query."""
__mcp_connections__ = [
MCPConnection("jira", "http://0.0.0.0:9000/mcp", require_integration=False)
]
async def post(self, context):
readable_response = await context.llm.ainvoke(context.prompts)
await context.add_response(self, readable_response.content)
return ActionReturn.END
```
- `post` is only recommended if mcp tools responses is not in natural language yet.
- You can leverage `post` or `commit_context` for final response generation
### View Graph
```python
from asyncio import run
from pybotchi import graph
print(run(graph(AtlassianAgent)))
```
#### **Result**
```
flowchart TD
mcp.jira.JiraCreateIssueLink[mcp.jira.JiraCreateIssueLink]
mcp.jira.JiraUpdateSprint[mcp.jira.JiraUpdateSprint]
mcp.jira.JiraDownloadAttachments[mcp.jira.JiraDownloadAttachments]
mcp.jira.JiraDeleteIssue[mcp.jira.JiraDeleteIssue]
mcp.jira.JiraGetTransitions[mcp.jira.JiraGetTransitions]
mcp.jira.JiraUpdateIssue[mcp.jira.JiraUpdateIssue]
mcp.jira.JiraSearch[mcp.jira.JiraSearch]
mcp.jira.JiraGetAgileBoards[mcp.jira.JiraGetAgileBoards]
mcp.jira.JiraAddComment[mcp.jira.JiraAddComment]
mcp.jira.JiraGetSprintsFromBoard[mcp.jira.JiraGetSprintsFromBoard]
mcp.jira.JiraGetSprintIssues[mcp.jira.JiraGetSprintIssues]
__main__.AtlassianAgent[__main__.AtlassianAgent]
mcp.jira.JiraLinkToEpic[mcp.jira.JiraLinkToEpic]
mcp.jira.JiraCreateIssue[mcp.jira.JiraCreateIssue]
mcp.jira.JiraBatchCreateIssues[mcp.jira.JiraBatchCreateIssues]
mcp.jira.JiraSearchFields[mcp.jira.JiraSearchFields]
mcp.jira.JiraGetWorklog[mcp.jira.JiraGetWorklog]
mcp.jira.JiraTransitionIssue[mcp.jira.JiraTransitionIssue]
mcp.jira.JiraGetProjectVersions[mcp.jira.JiraGetProjectVersions]
mcp.jira.JiraGetUserProfile[mcp.jira.JiraGetUserProfile]
mcp.jira.JiraGetBoardIssues[mcp.jira.JiraGetBoardIssues]
mcp.jira.JiraGetProjectIssues[mcp.jira.JiraGetProjectIssues]
mcp.jira.JiraAddWorklog[mcp.jira.JiraAddWorklog]
mcp.jira.JiraCreateSprint[mcp.jira.JiraCreateSprint]
mcp.jira.JiraGetLinkTypes[mcp.jira.JiraGetLinkTypes]
mcp.jira.JiraRemoveIssueLink[mcp.jira.JiraRemoveIssueLink]
mcp.jira.JiraGetIssue[mcp.jira.JiraGetIssue]
mcp.jira.JiraBatchGetChangelogs[mcp.jira.JiraBatchGetChangelogs]
__main__.AtlassianAgent --> mcp.jira.JiraCreateIssueLink
__main__.AtlassianAgent --> mcp.jira.JiraGetLinkTypes
__main__.AtlassianAgent --> mcp.jira.JiraDownloadAttachments
__main__.AtlassianAgent --> mcp.jira.JiraAddWorklog
__main__.AtlassianAgent --> mcp.jira.JiraRemoveIssueLink
__main__.AtlassianAgent --> mcp.jira.JiraCreateIssue
__main__.AtlassianAgent --> mcp.jira.JiraLinkToEpic
__main__.AtlassianAgent --> mcp.jira.JiraGetSprintsFromBoard
__main__.AtlassianAgent --> mcp.jira.JiraGetAgileBoards
__main__.AtlassianAgent --> mcp.jira.JiraBatchCreateIssues
__main__.AtlassianAgent --> mcp.jira.JiraSearchFields
__main__.AtlassianAgent --> mcp.jira.JiraGetSprintIssues
__main__.AtlassianAgent --> mcp.jira.JiraSearch
__main__.AtlassianAgent
/r/Python
https://redd.it/1mmo3gx
GitHub
GitHub - amadolid/pybotchi
Contribute to amadolid/pybotchi development by creating an account on GitHub.
Thin view fat model, mixins, repository/service pattern, which to use for growing project ?
I have created a SaaS 5 years ago when I was not as skilled as today and the project was still fairly small in LOC. Fast forward to today I want to take the end of the year to fully refactor my codebase that is getting harder to manage with lot of boilerplate.
I have been using Go and Flutter and was happy with the repository/service layer but feel like it might be anti-Django.
For big growing project, what is your best approach to organize your code ?
For instance my project both handle Api and HTMX/HTML request
/r/django
https://redd.it/1mmk5ue
I have created a SaaS 5 years ago when I was not as skilled as today and the project was still fairly small in LOC. Fast forward to today I want to take the end of the year to fully refactor my codebase that is getting harder to manage with lot of boilerplate.
I have been using Go and Flutter and was happy with the repository/service layer but feel like it might be anti-Django.
For big growing project, what is your best approach to organize your code ?
For instance my project both handle Api and HTMX/HTML request
/r/django
https://redd.it/1mmk5ue
Reddit
From the django community on Reddit
Explore this post and more from the django community
PyWine - Containerized Wine with Python to test project under Windows environment
- What My Project Does - PyWine allows to test Python code under Windows environment using containerized Wine. Useful during local development when you natively use Linux or macOS without need of using heavy Virtual Machine. Also it can be used in CI without need of using Windows CI runners. It unifies local development with CI.
- Target Audience - Linux/macOS Python developers that want to test their Python code under Windows environment. For example to test native Windows named pipes when using Python built-in multiprocessing.connection module.
- Comparison - https://github.com/webcomics/pywine, project with the same name but it doesn't provide the same seamless experience. Like running it out-of-box with the same defined CI job for
- Check the GitLab project for usage: https://gitlab.com/tymonx/pywine
- Check the real usage example from gitlab.com/tymonx/pytcl/.gitlab-ci.yml with GitLab CI job pytest-windows
/r/Python
https://redd.it/1mmow8a
- What My Project Does - PyWine allows to test Python code under Windows environment using containerized Wine. Useful during local development when you natively use Linux or macOS without need of using heavy Virtual Machine. Also it can be used in CI without need of using Windows CI runners. It unifies local development with CI.
- Target Audience - Linux/macOS Python developers that want to test their Python code under Windows environment. For example to test native Windows named pipes when using Python built-in multiprocessing.connection module.
- Comparison - https://github.com/webcomics/pywine, project with the same name but it doesn't provide the same seamless experience. Like running it out-of-box with the same defined CI job for
pytest or locally without need of executing some magic script like /opt/mkuserwineprefix- Check the GitLab project for usage: https://gitlab.com/tymonx/pywine
- Check the real usage example from gitlab.com/tymonx/pytcl/.gitlab-ci.yml with GitLab CI job pytest-windows
/r/Python
https://redd.it/1mmow8a
GitLab
Tymoteusz Blazejczyk / PyWine · GitLab
Containerized Wine with Windows version of Python. Test your Python...
Zero to hero and where to start?
As you can see from the title I’m currently a zero with dreams to be a hero lol. I’m new to the world of coding and have always heard about python being one of the most useful languages. Any advice for a beginner or good places to start? From what I’ve gathered it’s best to just throw yourself into it and pick a project/figure it out vs wasting time with boot camps and all of that jazz. Any resources that have helped you along your journey would be greatly appreciated. 💯🙏😁
/r/Python
https://redd.it/1mmu0qk
As you can see from the title I’m currently a zero with dreams to be a hero lol. I’m new to the world of coding and have always heard about python being one of the most useful languages. Any advice for a beginner or good places to start? From what I’ve gathered it’s best to just throw yourself into it and pick a project/figure it out vs wasting time with boot camps and all of that jazz. Any resources that have helped you along your journey would be greatly appreciated. 💯🙏😁
/r/Python
https://redd.it/1mmu0qk
Reddit
From the Python community on Reddit
Explore this post and more from the Python community
DRF and JWT Authentication
Hello guys, i just made an app for JWT authentication in Django Rest Framework.
I would be pleased if you can check and give be feedbacks. Thank you
The GitHub link: https://github.com/JulesC836/drf_auth_with_jwt.git
/r/django
https://redd.it/1mmllht
Hello guys, i just made an app for JWT authentication in Django Rest Framework.
I would be pleased if you can check and give be feedbacks. Thank you
The GitHub link: https://github.com/JulesC836/drf_auth_with_jwt.git
/r/django
https://redd.it/1mmllht
GitHub
GitHub - JulesC836/drf_auth_with_jwt: A django auth app using Json Web Token
A django auth app using Json Web Token. Contribute to JulesC836/drf_auth_with_jwt development by creating an account on GitHub.
AFDebugging help: Flaskapp can't find static files
I'm running flask 3.0.3 with python 3.11 and have a strange issue where it can't find a simple css file I have in there. When I give a path to my static file I get a 404 can't be found.
my file structure is like the below:
project
init.py
controller.py
config.py
templates
templatefile.html
static
style.css
I haven't tried a lot yet, I started seeing if I made a mistake compared to how it's done in the flask tutorial but I can't see where I've gone wrong, I also looked on stack overflow a bit. I've tried setting a path directly to the static folder, inside __init__.py
Is there a way I can debug this and find what path it is looking for static files in?
# Edit: Additional info from questions in comments.
- I am using
/r/flask
https://redd.it/1mmptbh
I'm running flask 3.0.3 with python 3.11 and have a strange issue where it can't find a simple css file I have in there. When I give a path to my static file I get a 404 can't be found.
my file structure is like the below:
project
init.py
controller.py
config.py
templates
templatefile.html
static
style.css
I haven't tried a lot yet, I started seeing if I made a mistake compared to how it's done in the flask tutorial but I can't see where I've gone wrong, I also looked on stack overflow a bit. I've tried setting a path directly to the static folder, inside __init__.py
app = Flask(__name__, static_folder=STATIC_DIR)Is there a way I can debug this and find what path it is looking for static files in?
# Edit: Additional info from questions in comments.
- I am using
/r/flask
https://redd.it/1mmptbh