Why is there no python auto-instrument module for open telemetry ?
Hi all,
I use open telemetry auto-instrumentors to get insights of my python application. These auto-instrumentors will instrument particular modules:
* [fast-api auto instrumentor](https://github.com/open-telemetry/opentelemetry-python-contrib/tree/main/instrumentation/opentelemetry-instrumentation-fastapi)
* [openai auto instrumentor](https://github.com/open-telemetry/opentelemetry-python-contrib/tree/main/instrumentation-genai/opentelemetry-instrumentation-openai-v2)
* etc...
As far as I understand, these modules will create spans for different events (fastapi request, openai llm call etc..), adding inputs and outputs of event as span attributes
# My question:
Why isn't there a python auto instrumentor that will create a span for each function, adding arguments and return values as attributes ?
Is it a bad idea to do such auto instrumentor ? Is it just not feasible ?
## Edit :
For those who are interested, I have coded an auto-instrumentor that will automatically create a span for the functions that are called **in user code** (not in imported modules etc...)
Check it ou there [repo](https://github.com/le-codeur-rapide/opentelemetry-instrumentation-python/tree/main/examples)
/r/Python
https://redd.it/1l6crs2
Hi all,
I use open telemetry auto-instrumentors to get insights of my python application. These auto-instrumentors will instrument particular modules:
* [fast-api auto instrumentor](https://github.com/open-telemetry/opentelemetry-python-contrib/tree/main/instrumentation/opentelemetry-instrumentation-fastapi)
* [openai auto instrumentor](https://github.com/open-telemetry/opentelemetry-python-contrib/tree/main/instrumentation-genai/opentelemetry-instrumentation-openai-v2)
* etc...
As far as I understand, these modules will create spans for different events (fastapi request, openai llm call etc..), adding inputs and outputs of event as span attributes
# My question:
Why isn't there a python auto instrumentor that will create a span for each function, adding arguments and return values as attributes ?
Is it a bad idea to do such auto instrumentor ? Is it just not feasible ?
## Edit :
For those who are interested, I have coded an auto-instrumentor that will automatically create a span for the functions that are called **in user code** (not in imported modules etc...)
Check it ou there [repo](https://github.com/le-codeur-rapide/opentelemetry-instrumentation-python/tree/main/examples)
/r/Python
https://redd.it/1l6crs2
GitHub
opentelemetry-python-contrib/instrumentation/opentelemetry-instrumentation-fastapi at main · open-telemetry/opentelemetry-python…
OpenTelemetry instrumentation for Python modules. Contribute to open-telemetry/opentelemetry-python-contrib development by creating an account on GitHub.
Monday Daily Thread: Project ideas!
# Weekly Thread: Project Ideas 💡
Welcome to our weekly Project Ideas thread! Whether you're a newbie looking for a first project or an expert seeking a new challenge, this is the place for you.
## How it Works:
1. **Suggest a Project**: Comment your project idea—be it beginner-friendly or advanced.
2. **Build & Share**: If you complete a project, reply to the original comment, share your experience, and attach your source code.
3. **Explore**: Looking for ideas? Check out Al Sweigart's ["The Big Book of Small Python Projects"](https://www.amazon.com/Big-Book-Small-Python-Programming/dp/1718501242) for inspiration.
## Guidelines:
* Clearly state the difficulty level.
* Provide a brief description and, if possible, outline the tech stack.
* Feel free to link to tutorials or resources that might help.
# Example Submissions:
## Project Idea: Chatbot
**Difficulty**: Intermediate
**Tech Stack**: Python, NLP, Flask/FastAPI/Litestar
**Description**: Create a chatbot that can answer FAQs for a website.
**Resources**: [Building a Chatbot with Python](https://www.youtube.com/watch?v=a37BL0stIuM)
# Project Idea: Weather Dashboard
**Difficulty**: Beginner
**Tech Stack**: HTML, CSS, JavaScript, API
**Description**: Build a dashboard that displays real-time weather information using a weather API.
**Resources**: [Weather API Tutorial](https://www.youtube.com/watch?v=9P5MY_2i7K8)
## Project Idea: File Organizer
**Difficulty**: Beginner
**Tech Stack**: Python, File I/O
**Description**: Create a script that organizes files in a directory into sub-folders based on file type.
**Resources**: [Automate the Boring Stuff: Organizing Files](https://automatetheboringstuff.com/2e/chapter9/)
Let's help each other grow. Happy
/r/Python
https://redd.it/1l6qq6d
# Weekly Thread: Project Ideas 💡
Welcome to our weekly Project Ideas thread! Whether you're a newbie looking for a first project or an expert seeking a new challenge, this is the place for you.
## How it Works:
1. **Suggest a Project**: Comment your project idea—be it beginner-friendly or advanced.
2. **Build & Share**: If you complete a project, reply to the original comment, share your experience, and attach your source code.
3. **Explore**: Looking for ideas? Check out Al Sweigart's ["The Big Book of Small Python Projects"](https://www.amazon.com/Big-Book-Small-Python-Programming/dp/1718501242) for inspiration.
## Guidelines:
* Clearly state the difficulty level.
* Provide a brief description and, if possible, outline the tech stack.
* Feel free to link to tutorials or resources that might help.
# Example Submissions:
## Project Idea: Chatbot
**Difficulty**: Intermediate
**Tech Stack**: Python, NLP, Flask/FastAPI/Litestar
**Description**: Create a chatbot that can answer FAQs for a website.
**Resources**: [Building a Chatbot with Python](https://www.youtube.com/watch?v=a37BL0stIuM)
# Project Idea: Weather Dashboard
**Difficulty**: Beginner
**Tech Stack**: HTML, CSS, JavaScript, API
**Description**: Build a dashboard that displays real-time weather information using a weather API.
**Resources**: [Weather API Tutorial](https://www.youtube.com/watch?v=9P5MY_2i7K8)
## Project Idea: File Organizer
**Difficulty**: Beginner
**Tech Stack**: Python, File I/O
**Description**: Create a script that organizes files in a directory into sub-folders based on file type.
**Resources**: [Automate the Boring Stuff: Organizing Files](https://automatetheboringstuff.com/2e/chapter9/)
Let's help each other grow. Happy
/r/Python
https://redd.it/1l6qq6d
Real world flask projects
Hey. I’m learning flask as of now and tutorials focus on simpler task/projects that don’t show using of flask on its full extend. Additionally to that each tutorial skips or copy pastes all other things that aren’t of directional relation to flask. It is ok I guess since they are trying to teach me flask, but would want to see a real flask project to understand how devs use it in real world applications and how they couple it with other tools/frameworks. Could anyone share a GitHub link where I could find it?
/r/Python
https://redd.it/1l6g3eg
Hey. I’m learning flask as of now and tutorials focus on simpler task/projects that don’t show using of flask on its full extend. Additionally to that each tutorial skips or copy pastes all other things that aren’t of directional relation to flask. It is ok I guess since they are trying to teach me flask, but would want to see a real flask project to understand how devs use it in real world applications and how they couple it with other tools/frameworks. Could anyone share a GitHub link where I could find it?
/r/Python
https://redd.it/1l6g3eg
Reddit
From the Python community on Reddit
Explore this post and more from the Python community
Looking for senior python API developer
Looking for a remote Python developer to build and maintain APIs (Django), automate SSL checks, and scale backend systems.
• 🛠 Stack: Python, Django, FastAPI, Docker, PostgreSQL, ASB
• 🌍 Fully remote (worldwide)
• 💰 Competitive pay + equity potential
DM for details
/r/Python
https://redd.it/1l6u1ig
Looking for a remote Python developer to build and maintain APIs (Django), automate SSL checks, and scale backend systems.
• 🛠 Stack: Python, Django, FastAPI, Docker, PostgreSQL, ASB
• 🌍 Fully remote (worldwide)
• 💰 Competitive pay + equity potential
DM for details
/r/Python
https://redd.it/1l6u1ig
Reddit
From the Python community on Reddit
Explore this post and more from the Python community
Deploying to VPS , Postgres slowdown
Hi everyone,
I'm using django-debug-toolbar to look at my query times on my local machine and i'm trying to optimize it as best i can so i keep my load times as low as possible.
On my local machine debug-toolbar states '12 queries in 2.73ms'.
I ran the same settings, same project, same DB copy on a \~25 EUR VPS on hetzner and i got this: '12 queries ran in 28.1ms'.
Now, my logic is that if i have the webserver (django+nginx) and the database (postgres) on the same machine, then the query times should be relatively close, since django communicates with the DB on localhost, so no reason for a slowdown.
I get that the final HTML will be sent much slower since the server is \~500km from me and not 50cm.
Again, Postgres and Django is on the same machine, and the same query takes 10x as much time for some reason.
Is my logic wrong or am i doing something very wrong when deploying to a VPS?
/r/django
https://redd.it/1l6oy53
Hi everyone,
I'm using django-debug-toolbar to look at my query times on my local machine and i'm trying to optimize it as best i can so i keep my load times as low as possible.
On my local machine debug-toolbar states '12 queries in 2.73ms'.
I ran the same settings, same project, same DB copy on a \~25 EUR VPS on hetzner and i got this: '12 queries ran in 28.1ms'.
Now, my logic is that if i have the webserver (django+nginx) and the database (postgres) on the same machine, then the query times should be relatively close, since django communicates with the DB on localhost, so no reason for a slowdown.
I get that the final HTML will be sent much slower since the server is \~500km from me and not 50cm.
Again, Postgres and Django is on the same machine, and the same query takes 10x as much time for some reason.
Is my logic wrong or am i doing something very wrong when deploying to a VPS?
/r/django
https://redd.it/1l6oy53
Reddit
From the django community on Reddit
Explore this post and more from the django community
Robyn (finally) supports Python 3.13 🎉
For the unaware - Robyn is a fast, async Python web framework built on a Rust runtime.
Python 3.13 support has been one of the top requests, and after some heavy lifting (cc:
Wanted to share it with folks outside the Robyn bubble.
You can check out the release at - https://github.com/sparckles/Robyn/releases/tag/v0.68.0
/r/Python
https://redd.it/1l6ww94
For the unaware - Robyn is a fast, async Python web framework built on a Rust runtime.
Python 3.13 support has been one of the top requests, and after some heavy lifting (cc:
cffi woes), it’s finally here.Wanted to share it with folks outside the Robyn bubble.
You can check out the release at - https://github.com/sparckles/Robyn/releases/tag/v0.68.0
/r/Python
https://redd.it/1l6ww94
GitHub
GitHub - sparckles/Robyn: Robyn is a Super Fast Async Python Web Framework with a Rust runtime.
Robyn is a Super Fast Async Python Web Framework with a Rust runtime. - sparckles/Robyn
Built my another full-stack e-bike rental platform - Django + React
Hey everyone!
[Home page](https://preview.redd.it/yrne6e32pu5f1.png?width=1850&format=png&auto=webp&s=5523c760fc503db8242252ede36f40e38dcb99bb)
I just finished **building an e-bike rental platform** and wanted to share it with you all. It's basically like Airbnb but for electric bikes.What it does:
* People can list their e-bikes for rent
* Others can search and book those bikes
* Has a booking system with calendar dates
* Photo uploads for bike listings
* User reviews and ratings
* Mobile responsive design
Tech I used:
* Backend: Django REST Framework + PostgreSQL
* Frontend: React + TypeScript + Tailwind CSS
* Authentication with JWT tokens
Features I'm proud of:
* You can filter bikes by type, location, and price
* The booking process is pretty smooth (date picker, payment info, confirmation)
* Bike owners can manage their listings and see booking requests
* Added a favorites system so users can save bikes they like
I built this project in my free time.
GitHub: [https://github.com/manjurulhoque/BoltBike](https://github.com/manjurulhoque/BoltBike)
I put screenshots in the repo so you can see how it looks.
Would love to hear what you think or if you have any suggestions for improvements!
Thanks for checking it out 🚴♂
/r/django
https://redd.it/1l6y8q5
Hey everyone!
[Home page](https://preview.redd.it/yrne6e32pu5f1.png?width=1850&format=png&auto=webp&s=5523c760fc503db8242252ede36f40e38dcb99bb)
I just finished **building an e-bike rental platform** and wanted to share it with you all. It's basically like Airbnb but for electric bikes.What it does:
* People can list their e-bikes for rent
* Others can search and book those bikes
* Has a booking system with calendar dates
* Photo uploads for bike listings
* User reviews and ratings
* Mobile responsive design
Tech I used:
* Backend: Django REST Framework + PostgreSQL
* Frontend: React + TypeScript + Tailwind CSS
* Authentication with JWT tokens
Features I'm proud of:
* You can filter bikes by type, location, and price
* The booking process is pretty smooth (date picker, payment info, confirmation)
* Bike owners can manage their listings and see booking requests
* Added a favorites system so users can save bikes they like
I built this project in my free time.
GitHub: [https://github.com/manjurulhoque/BoltBike](https://github.com/manjurulhoque/BoltBike)
I put screenshots in the repo so you can see how it looks.
Would love to hear what you think or if you have any suggestions for improvements!
Thanks for checking it out 🚴♂
/r/django
https://redd.it/1l6y8q5
Football Tournament Maker V1.0
It is an open source web program designed by me you can modify it easily
🔹html
🔹css
🔹javascript
🔹python-flask
https://youtu.be/SMvMQYZiggQ
/r/Python
https://redd.it/1l72ucz
It is an open source web program designed by me you can modify it easily
🔹html
🔹css
🔹javascript
🔹python-flask
https://youtu.be/SMvMQYZiggQ
/r/Python
https://redd.it/1l72ucz
YouTube
شرح تحميل و تنصيب برنامج لإدارة مباريات كرة القدم من تصميمى فقط وحصريا على github
#github #open_source #football #كرة_القدم #tournament_maker
https://github.com/mahgad/Football-Tournament-Maker v1.0
⚽ نظام إدارة بطولات كرة القدم
نظام ويب شامل ومتطور لإدارة بطولات كرة القدم، الفرق، اللاعبين والمباريات باللغة العربية.
🌟 الميزات الرئيسية…
https://github.com/mahgad/Football-Tournament-Maker v1.0
⚽ نظام إدارة بطولات كرة القدم
نظام ويب شامل ومتطور لإدارة بطولات كرة القدم، الفرق، اللاعبين والمباريات باللغة العربية.
🌟 الميزات الرئيسية…
Have you ever migrated from Stripe to Ryft Pay?
How was the process, and how was handling large volume/throughput of payments after moving away from stripe?
/r/django
https://redd.it/1l695sn
How was the process, and how was handling large volume/throughput of payments after moving away from stripe?
/r/django
https://redd.it/1l695sn
Reddit
From the django community on Reddit
Explore this post and more from the django community
Why Django Feels Underrated in Modern Development — A Take on Its Limitations and Future Potential
>I’m a Full Stack developer and have been using Django seriously for the past few year for my personal and organization projects. The more I use it, the more I feel it’s one of the most powerful and reliable web frameworks out there. But at the same time, I keep noticing that Django doesn’t get the hype or recognition it deserves in modern development circles.
Here’s my perspective on why Django feels underrated today, what limitations I’ve personally run into, and what I think could make it the go-to framework again in the modern dev world.
1. Django isn't designed for SPAs by default Right now, the industry heavily leans toward frontend frameworks like React, Vue, Svelte, etc. Django is still very template-focused out of the box. And yes, Django REST Framework (DRF) helps a lot, but it doesn’t feel like the framework is meant to play well with modern JS apps by default. I’ve had to glue a lot of things together manually to make Django work as a backend for SPAs.
2. Async support came too late and still feels half-baked I know Django now supports async views and middleware, but async ORM is still not fully stable, and a lot
/r/django
https://redd.it/1l77epz
>I’m a Full Stack developer and have been using Django seriously for the past few year for my personal and organization projects. The more I use it, the more I feel it’s one of the most powerful and reliable web frameworks out there. But at the same time, I keep noticing that Django doesn’t get the hype or recognition it deserves in modern development circles.
Here’s my perspective on why Django feels underrated today, what limitations I’ve personally run into, and what I think could make it the go-to framework again in the modern dev world.
1. Django isn't designed for SPAs by default Right now, the industry heavily leans toward frontend frameworks like React, Vue, Svelte, etc. Django is still very template-focused out of the box. And yes, Django REST Framework (DRF) helps a lot, but it doesn’t feel like the framework is meant to play well with modern JS apps by default. I’ve had to glue a lot of things together manually to make Django work as a backend for SPAs.
2. Async support came too late and still feels half-baked I know Django now supports async views and middleware, but async ORM is still not fully stable, and a lot
/r/django
https://redd.it/1l77epz
Reddit
From the django community on Reddit
Explore this post and more from the django community
Does it make sense to use fully synchronous Django REST APIs with Gunicorn using the gthread worker class?
I have Django REST APIs that only make database calls using the ORM and external API calls using the Python
Is it really worth using the
I am using 2 workers with 4 threads.
/r/django
https://redd.it/1l78ovj
I have Django REST APIs that only make database calls using the ORM and external API calls using the Python
requests package. Is it really worth using the
gthread class? I am using 2 workers with 4 threads.
/r/django
https://redd.it/1l78ovj
Reddit
From the django community on Reddit
Explore this post and more from the django community
pyfuze 2.0.2 – A New Cross-Platform Packaging Tool for Python
# What My Project Does
**pyfuze** packages your Python project into a **single executable**, and now supports **three distinct modes**:
|Mode|Standalone|Cross-Platform|Size|Compatibility|
|:-|:-|:-|:-|:-|
|**Bundle** *(default)*|✅|❌|🔴 Large|🟢 High|
|**Online**|❌|✅|🟢 Small|🟢 High|
|**Portable**|✅|✅|🟡 Medium|🔴 Low|
* **Bundle mode** is similar to PyInstaller's `--onefile` option. It includes Python and all dependencies, and extracts them at runtime.
* **Online mode** works like bundle mode, except it **downloads Python and dependencies at runtime**, keeping the package size small.
* **Portable mode** is significantly different. Based on [python.com](https://github.com/jart/cosmopolitan/wiki/python.com), it creates a truly standalone executable that **does not extract or download anything**. However, it only supports **pure Python projects and dependencies**.
# Target Audience
This tool is for Python developers who want to **package and distribute** their projects as standalone executables.
# Comparison
The most well-known tool for packaging Python projects is **PyInstaller**. Compared to it, **pyfuze** offers two additional modes:
* **Online mode** is ideal when your users have reliable network access — the final executable is only a few hundred kilobytes in size.
* **Portable mode** is great for simple pure-Python projects and requires **no extraction, no downloads**, and works across platforms.
Both modes offer **cross-platform compatibility**, making **pyfuze** a flexible choice for distributing Python applications across Windows, macOS, and Linux. This is made possible by the excellent work of the [uv](https://github.com/astral-sh/uv)
/r/Python
https://redd.it/1l7dwei
# What My Project Does
**pyfuze** packages your Python project into a **single executable**, and now supports **three distinct modes**:
|Mode|Standalone|Cross-Platform|Size|Compatibility|
|:-|:-|:-|:-|:-|
|**Bundle** *(default)*|✅|❌|🔴 Large|🟢 High|
|**Online**|❌|✅|🟢 Small|🟢 High|
|**Portable**|✅|✅|🟡 Medium|🔴 Low|
* **Bundle mode** is similar to PyInstaller's `--onefile` option. It includes Python and all dependencies, and extracts them at runtime.
* **Online mode** works like bundle mode, except it **downloads Python and dependencies at runtime**, keeping the package size small.
* **Portable mode** is significantly different. Based on [python.com](https://github.com/jart/cosmopolitan/wiki/python.com), it creates a truly standalone executable that **does not extract or download anything**. However, it only supports **pure Python projects and dependencies**.
# Target Audience
This tool is for Python developers who want to **package and distribute** their projects as standalone executables.
# Comparison
The most well-known tool for packaging Python projects is **PyInstaller**. Compared to it, **pyfuze** offers two additional modes:
* **Online mode** is ideal when your users have reliable network access — the final executable is only a few hundred kilobytes in size.
* **Portable mode** is great for simple pure-Python projects and requires **no extraction, no downloads**, and works across platforms.
Both modes offer **cross-platform compatibility**, making **pyfuze** a flexible choice for distributing Python applications across Windows, macOS, and Linux. This is made possible by the excellent work of the [uv](https://github.com/astral-sh/uv)
/r/Python
https://redd.it/1l7dwei
GitHub
python.com
build-once run-anywhere c library. Contribute to jart/cosmopolitan development by creating an account on GitHub.
Flask flash() displaying JSON-like string instead of message text
I'm working on a Flask application and I am encountering an unexpected issue with `flash()`messages.
I'm using the standard Flask `flash()` function in my Python backend:
from flask import flash, redirect, url_for, render_template
# ... inside a route, e.g., after successful registration
flash("Registration successful! Please complete your profile", "success")
return redirect(url_for('complete_profile'))
My Jinja2 template (base.html, which other templates extend) is set up to display flashed messages as recommended in the Flask documentation:
<div class="container mt-3">
{% with messages = get_flashed_messages(with_categories=true) %}
{% if messages %}
{% for category, message in messages %}
<div class="alert alert-{{ category }} alert-dismissible fade show" role="alert">
{{ message }}
/r/flask
https://redd.it/1l7ggyj
I'm working on a Flask application and I am encountering an unexpected issue with `flash()`messages.
I'm using the standard Flask `flash()` function in my Python backend:
from flask import flash, redirect, url_for, render_template
# ... inside a route, e.g., after successful registration
flash("Registration successful! Please complete your profile", "success")
return redirect(url_for('complete_profile'))
My Jinja2 template (base.html, which other templates extend) is set up to display flashed messages as recommended in the Flask documentation:
<div class="container mt-3">
{% with messages = get_flashed_messages(with_categories=true) %}
{% if messages %}
{% for category, message in messages %}
<div class="alert alert-{{ category }} alert-dismissible fade show" role="alert">
{{ message }}
/r/flask
https://redd.it/1l7ggyj
Reddit
From the flask community on Reddit
Explore this post and more from the flask community
what’s the best AI workflow for Jupyter?
I recently discovered # %% in .py files create cells as .ipynb aren’t very compatible with cursor functions. but is there a gold standard already for Jupyter workflows?
/r/IPython
https://redd.it/1l7bviv
I recently discovered # %% in .py files create cells as .ipynb aren’t very compatible with cursor functions. but is there a gold standard already for Jupyter workflows?
/r/IPython
https://redd.it/1l7bviv
Reddit
From the IPython community on Reddit
Explore this post and more from the IPython community
Tuesday Daily Thread: Advanced questions
# Weekly Wednesday Thread: Advanced Questions 🐍
Dive deep into Python with our Advanced Questions thread! This space is reserved for questions about more advanced Python topics, frameworks, and best practices.
## How it Works:
1. **Ask Away**: Post your advanced Python questions here.
2. **Expert Insights**: Get answers from experienced developers.
3. **Resource Pool**: Share or discover tutorials, articles, and tips.
## Guidelines:
* This thread is for **advanced questions only**. Beginner questions are welcome in our [Daily Beginner Thread](#daily-beginner-thread-link) every Thursday.
* Questions that are not advanced may be removed and redirected to the appropriate thread.
## Recommended Resources:
* If you don't receive a response, consider exploring r/LearnPython or join the [Python Discord Server](https://discord.gg/python) for quicker assistance.
## Example Questions:
1. **How can you implement a custom memory allocator in Python?**
2. **What are the best practices for optimizing Cython code for heavy numerical computations?**
3. **How do you set up a multi-threaded architecture using Python's Global Interpreter Lock (GIL)?**
4. **Can you explain the intricacies of metaclasses and how they influence object-oriented design in Python?**
5. **How would you go about implementing a distributed task queue using Celery and RabbitMQ?**
6. **What are some advanced use-cases for Python's decorators?**
7. **How can you achieve real-time data streaming in Python with WebSockets?**
8. **What are the
/r/Python
https://redd.it/1l7kkp8
# Weekly Wednesday Thread: Advanced Questions 🐍
Dive deep into Python with our Advanced Questions thread! This space is reserved for questions about more advanced Python topics, frameworks, and best practices.
## How it Works:
1. **Ask Away**: Post your advanced Python questions here.
2. **Expert Insights**: Get answers from experienced developers.
3. **Resource Pool**: Share or discover tutorials, articles, and tips.
## Guidelines:
* This thread is for **advanced questions only**. Beginner questions are welcome in our [Daily Beginner Thread](#daily-beginner-thread-link) every Thursday.
* Questions that are not advanced may be removed and redirected to the appropriate thread.
## Recommended Resources:
* If you don't receive a response, consider exploring r/LearnPython or join the [Python Discord Server](https://discord.gg/python) for quicker assistance.
## Example Questions:
1. **How can you implement a custom memory allocator in Python?**
2. **What are the best practices for optimizing Cython code for heavy numerical computations?**
3. **How do you set up a multi-threaded architecture using Python's Global Interpreter Lock (GIL)?**
4. **Can you explain the intricacies of metaclasses and how they influence object-oriented design in Python?**
5. **How would you go about implementing a distributed task queue using Celery and RabbitMQ?**
6. **What are some advanced use-cases for Python's decorators?**
7. **How can you achieve real-time data streaming in Python with WebSockets?**
8. **What are the
/r/Python
https://redd.it/1l7kkp8
Discord
Join the Python Discord Server!
We're a large community focused around the Python programming language. We believe that anyone can learn to code. | 412982 members
Stockstir is a Python library to get stock information from any script at no cost CLI released!
Hello again!
Wanted to showcase my project, Stockstir, which may be of use to many of you that want to follow stock prices freely in any script. CLI has just been released!
What My Project Does
Stockstir is an easy way to instantly gather stock data from any of your Python scripts. Not only that, but it includes other features, such as multi data gathering, anti ban, a fail-safe mechanism, random user agents, and much more.
Target Audience
Stockstir is for everyone that needs to gather realtime company stock info from any of their scripts. It mostly differs from any other stock related project in the way that it is simple, and doesn't rely on APIs that cost money.
Comparison
Stockstir differs from other methods of gathering stock data in that it is has a very simple concept behind it. It is largely a GET wrapper in the Tools class, but initial API support such as Alpha Vantage, as well as gathering much more data of a Company stock through cnbc's JSON api, are under the API class. It mostly serves as a quick and simple way to gather stock data.
You can find installation instructions and other information under the project link provided below:
Link: Stockstir Project Link
To see
/r/Python
https://redd.it/1l7l0a7
Hello again!
Wanted to showcase my project, Stockstir, which may be of use to many of you that want to follow stock prices freely in any script. CLI has just been released!
What My Project Does
Stockstir is an easy way to instantly gather stock data from any of your Python scripts. Not only that, but it includes other features, such as multi data gathering, anti ban, a fail-safe mechanism, random user agents, and much more.
Target Audience
Stockstir is for everyone that needs to gather realtime company stock info from any of their scripts. It mostly differs from any other stock related project in the way that it is simple, and doesn't rely on APIs that cost money.
Comparison
Stockstir differs from other methods of gathering stock data in that it is has a very simple concept behind it. It is largely a GET wrapper in the Tools class, but initial API support such as Alpha Vantage, as well as gathering much more data of a Company stock through cnbc's JSON api, are under the API class. It mostly serves as a quick and simple way to gather stock data.
You can find installation instructions and other information under the project link provided below:
Link: Stockstir Project Link
To see
/r/Python
https://redd.it/1l7l0a7
GitHub
GitHub - PatzEdi/Stockstir: Easily gather stock data of any company in any of your Python projects
Easily gather stock data of any company in any of your Python projects - PatzEdi/Stockstir
No open ports detected error on Render
I made a simple flask application and was trying to deploy it on render, however there was this constant error that kept coming up saying "No open ports detected, continuing to scan..." until the memory usage exceeded and it had to terminate the process. I have tried everything, I looked up the official docs of render to fix it, changing the default port to 10000 as per the docs but nothing is working no matter what. The start command I'm using is- gunicorn app:app --bind 0.0.0.0:$PORT. However I have tried different iterations of this too, like ${PORT} instead of $PORT or even hardcoding the port value but nothing works.
Please help me figure out what's wrong with this, here's the github repo, the root directory is "backend".
https://github.com/rithinagraj/pdf-chatbot-backend.git
/r/flask
https://redd.it/1l70efj
I made a simple flask application and was trying to deploy it on render, however there was this constant error that kept coming up saying "No open ports detected, continuing to scan..." until the memory usage exceeded and it had to terminate the process. I have tried everything, I looked up the official docs of render to fix it, changing the default port to 10000 as per the docs but nothing is working no matter what. The start command I'm using is- gunicorn app:app --bind 0.0.0.0:$PORT. However I have tried different iterations of this too, like ${PORT} instead of $PORT or even hardcoding the port value but nothing works.
Please help me figure out what's wrong with this, here's the github repo, the root directory is "backend".
https://github.com/rithinagraj/pdf-chatbot-backend.git
/r/flask
https://redd.it/1l70efj
GitHub
GitHub - rithinagraj/pdf-chatbot-backend
Contribute to rithinagraj/pdf-chatbot-backend development by creating an account on GitHub.
A Python library to reliably detect captive portals and TLS interception (Man in the middle) attacks
Hey all,
For a personal project (a Raspberry Pi powered hotspot + VPN), I needed to solve a problem that basic connectivity checks can't handle: how do you really know if you're on the internet, or just stuck behind a smart captive portal?
**What My Project Does**
captive-portal-detector is a Python library that provides a fast high confidence verdict on the true state of a network connection. Instead of just checking for connectivity, it determines if the network is:
1. OK: Open, secure, and free from tampering.
2. CAPTIVE: Blocked by a captive portal (e.g., a hotel login page) or actively being intercepted by a Man-in-the-Middle (MITM) attack.
3. NO\_INTERNET: Genuinely disconnected or unable to reach any trusted endpoint.
The library uses a multi-layered strategy, running several types of probes in parallel for speed and accuracy:
* HTTP Probes: Checks against standard endpoints to detect simple captive portal redirects.
* Random Host Probe: Defeats "smart" whitelisting portals by testing against a dynamically generated, unknown domain.
* Redundant, Pinned TLS Probes: Uses SPKI Public Key Pinning against two independent, user-controlled servers. This is the core feature, enabling the detection of sophisticated interception attacks used by corporate or state-level firewalls.
Out of the box, it's pinned against two redundant servers I set up
/r/Python
https://redd.it/1l7howq
Hey all,
For a personal project (a Raspberry Pi powered hotspot + VPN), I needed to solve a problem that basic connectivity checks can't handle: how do you really know if you're on the internet, or just stuck behind a smart captive portal?
**What My Project Does**
captive-portal-detector is a Python library that provides a fast high confidence verdict on the true state of a network connection. Instead of just checking for connectivity, it determines if the network is:
1. OK: Open, secure, and free from tampering.
2. CAPTIVE: Blocked by a captive portal (e.g., a hotel login page) or actively being intercepted by a Man-in-the-Middle (MITM) attack.
3. NO\_INTERNET: Genuinely disconnected or unable to reach any trusted endpoint.
The library uses a multi-layered strategy, running several types of probes in parallel for speed and accuracy:
* HTTP Probes: Checks against standard endpoints to detect simple captive portal redirects.
* Random Host Probe: Defeats "smart" whitelisting portals by testing against a dynamically generated, unknown domain.
* Redundant, Pinned TLS Probes: Uses SPKI Public Key Pinning against two independent, user-controlled servers. This is the core feature, enabling the detection of sophisticated interception attacks used by corporate or state-level firewalls.
Out of the box, it's pinned against two redundant servers I set up
/r/Python
https://redd.it/1l7howq
Reddit
From the Python community on Reddit: A Python library to reliably detect captive portals and TLS interception (Man in the middle)…
Explore this post and more from the Python community
Hey learners! I'm starting a new coding + study grind — and you're invited to join. .
just real learning, helping each other, solving doubts, late-night sessions, and building cool stuff in this crazy AI era 🤖💻
if you’re learning to code (or want to start), join in!
python, web dev, AI tools, DSA – we’re figuring it out together.
let’s build skills, side projects & a study vibe that actually works 🧠
drop a “💬” if you’re in – i’ll send the group link.
https://discord.gg/faBnStU7
/r/Python
https://redd.it/1l7swi8
just real learning, helping each other, solving doubts, late-night sessions, and building cool stuff in this crazy AI era 🤖💻
if you’re learning to code (or want to start), join in!
python, web dev, AI tools, DSA – we’re figuring it out together.
let’s build skills, side projects & a study vibe that actually works 🧠
drop a “💬” if you’re in – i’ll send the group link.
https://discord.gg/faBnStU7
/r/Python
https://redd.it/1l7swi8
Discord
Join the Dsync_hub Discord Server!
Check out the Dsync_hub community on Discord - hang out with 2 other members and enjoy free voice and text chat.
How to exclude usablepassword field from AdminUserCreationForm
Django 5.1 introduced this new AdminUserCreationForm that comes with a password-based authentication field and im trying to disable:
class CustomUserCreationForm(AdminUserCreationForm):
class Meta:
model = getusermodel()
exclude = (usablepassword,)
But is not working, this field section always comes with form. How can I fix this? Sorry bad english
/r/django
https://redd.it/1l7oxlt
Django 5.1 introduced this new AdminUserCreationForm that comes with a password-based authentication field and im trying to disable:
class CustomUserCreationForm(AdminUserCreationForm):
class Meta:
model = getusermodel()
exclude = (usablepassword,)
But is not working, this field section always comes with form. How can I fix this? Sorry bad english
/r/django
https://redd.it/1l7oxlt
Reddit
From the django community on Reddit
Explore this post and more from the django community