Daily Python News Question, Tips and Tricks, Best Practices on Python Programming Language Find more reddit channels over at @r_channels
Django 101 - High-Level Overview of Django Project Components
https://www.youtube.com/watch?v=deMO0wIwJis
/r/django
https://redd.it/1l9l2p2
P: I reimplemented all of frontier deep learning from scratch to help you learn
Hey friends, the world needs more serious AI researchers. Many AI/LLM beginners mentioned to me that they learn better from implementations than from papers/math, but existing open-source examples rarely go beyond basic nanoGPT-level demos.
To help bridge the gap, I spent the last two months full-time reimplementing and open-sourcing a self-contained implementation of most modern deep learning techniques from scratch. The result is beyond-nanoGPT, containing 20k+ lines of handcrafted, minimal, and extensively annotated PyTorch code for your educational pleasure.
It contains a clean, working implementation + demo of everything from KV caching to linear attention to diffusion Transformers to AlphaZero to even a minimal coding agent that can make end-to-end PRs autonomously.
I'd love feedback on how to make it more helpful for people interested in transitioning into deep learning research. I will continue to add features and maintain the repo for the foreseeable future. The roaring 2020s are a surreal time to be alive, and we need all hands on deck.
/r/MachineLearning
https://redd.it/1l9lb0c
History of time and date
Hi all
Would anyone be so kind to write some sort of code to get me the results of when the NQ and ES made the daily high or low. The date and time of when this happened. Have a good day
Thank you
/r/Python
https://redd.it/1l9ku4j
What ever happened to "Zope"?!
This is just a question out of curiosity, but back in 1999 I had to work with Python and Zope, as time progressed, I noticed that Zope is hardly if ever mentioned anywhere. Is Zope still being used? Or has it kinda fallen into obscurity? Or has it evolved in to something else ?
/r/Python
https://redd.it/1l9furl
How can I access currentuser outside of an route.
Hello, im trying to make a polling mechanism, so im making a background process using "ThreadPoolExecutor", I added a status boolean to my users table so they will only be able to send 1 request at time, but i´ve ran into a problem where I cant change the current\user.status to False after the background process is over since its outside of an route.
def backgroundtranslation(filecontent, wmodel, transcription, model, pitch, speechrate, userid):
try:
srtfile = whispertranscribe(filecontent, wmodel, transcription)
audio = texttospeech(srtfile, model, pitch, speechrate)
output = addstream(audio, filecontent)
# Save as userid.mp4
destination = os.path.join(CONTENTFOLDER, f"{userid}.mp4")
shutil.move(output, destination)
print(f"Translation complete: saved to {destination}")
/r/flask
https://redd.it/1l8uuq3
Thursday Daily Thread: Python Careers, Courses, and Furthering Education!
# Weekly Thread: Professional Use, Jobs, and Education 🏢
Welcome to this week's discussion on Python in the professional world! This is your spot to talk about job hunting, career growth, and educational resources in Python. Please note, this thread is not for recruitment.
---
## How it Works:
1. Career Talk: Discuss using Python in your job, or the job market for Python roles.
2. Education Q&A: Ask or answer questions about Python courses, certifications, and educational resources.
3. Workplace Chat: Share your experiences, challenges, or success stories about using Python professionally.
---
## Guidelines:
- This thread is not for recruitment. For job postings, please see r/PythonJobs or the recruitment thread in the sidebar.
- Keep discussions relevant to Python in the professional and educational context.
---
## Example Topics:
1. Career Paths: What kinds of roles are out there for Python developers?
2. Certifications: Are Python certifications worth it?
3. Course Recommendations: Any good advanced Python courses to recommend?
4. Workplace Tools: What Python libraries are indispensable in your professional work?
5. Interview Tips: What types of Python questions are commonly asked in interviews?
---
Let's help each other grow in our careers and education. Happy discussing! 🌟
/r/Python
https://redd.it/1l987wu
How to deploy my flask web app
I used Google AI Studio to create a web-based customer management and payment collection dashboard, primarily designed for cable operators. It was built using Flask (Python) and Bootstrap (HTML/CSS). This application helps manage customers, track payments, generate reports, and provide actionable business insights. The website looks good and is useful to me, but I want to deploy it on the internet. I have watched many tutorials on YouTube, but none of them worked for me. I tried platforms like Vercel, Render, Railway, and more, but they gave me various errors. I am a beginner and not very familiar with the code, so can you please help me? I will provide the GitHub source code link.
/r/flask
https://redd.it/1l8uirt
Is Python really important for cybersecurity?
I've seen some people saying that Python isn't really necessary to get started in the field, but I began learning it specifically because I plan to move into cybersecurity in the future. I’d love to hear from people already working in the area — how much does Python actually matter?
/r/Python
https://redd.it/1l95skp
Juvio - UV Kernel for Jupyter
Hi everyone,
I would like to share a small open-source project that brings uv-powered ephemeral environments to Jupyter. In short, whenever you start a notebook, an isolated venv is created with dependencies stored directly within the notebook itself (PEP 723).
🔗 GitHub: https://github.com/OKUA1/juvio (MIT License)
What it does
💡 Inline Dependency Management
Install packages right from the notebook:%juvio install numpy pandas
Dependencies are saved directly in the notebook as metadata (PEP 723-style), like:
# /// script
# requires-python = "==3.10.17"
# dependencies =
# "numpy==2.2.5",
# "pandas==2.2.3"
#
# ///
⚙️ Automatic Environment Setup
When the notebook is opened, Juvio installs the dependencies automatically in an ephemeral virtual environment (using uv), ensuring that the notebook runs with the correct versions of the packages and Python.
📁 Git-Friendly Format
Notebooks are converted on the fly to a script-style format using # %% markers, making diffs and version control painless:
# %%
%juvio install numpy
# %%
import numpy as np
# %%
arr = np.array(1, 2, 3)
print(arr)
/r/Python
https://redd.it/1l8xwsc
Project Generate Beautiful Chessboard Images from FEN Strings 🧠♟️
Hi everyone! I made a small Python library to generate beautiful, customizable chessboard images from FEN strings.
What is FEN string ?
FEN (Forsyth–Edwards Notation) is a standard way to describe a chess position using a short text string. It captures piece placement, turn, castling rights, en passant targets, and move counts — everything needed to recreate the exact state of a game.
🔗 GitHub: chessboard-imagepip install chessboard-image
# What My Project Does
Convert FEN to high-quality chessboard images
Support for white/black POV
Optional rank/file coordinates
Customizable themes (colors, fonts)
# Target Audience
Developers building chess tools
Content creators and educators
Anyone needing clean board images from FEN It's lightweight, offline-friendly, and great for side projects or integrations
# Comparison
python-chess
supports FEN parsing and SVG rendering, but image customization is limited
Most web tools aren’t Python-native or offline-friendly
This fills a gap: a Python-native, customizable image generator for chessboards
Feedback and contributions are welcome! 🙌
/r/Python
https://redd.it/1l8hdwz
Hi Guys! I know Django and started learning RestAPI . So what projects I can make with these two only. Any Playlist or GitHub Repo
Sams as title.
/r/djangolearning
https://redd.it/1l6lr1v
Need advice about managing codebase
So, for starters this is the first real website I've made. The website is a combination of html/css/js on the front, with Django and a sqlite3 database on the back end. Currently I have about 50 paying users and I'm expecting it to increase to the hundreds next year. Concurrent users is usually fairly small and my webserver stats show <2% load on the smallest virtual server they offer.
What I've been doing is buildling on an Ubuntu VM on my computer, testing and such, then I run a deploy script to SSH to my real server in the cloud, upload the changed source code, then bounce gunicorn and the new version of the code is live (adding new games/quizzes mostly). The database gets updated manually - the deploy script makes a backup - by using an import script against the .csv file the data is in. New questions might be in the format of questions.csv
category,question,answer1,answer2,answer3,answer4,difficulty
all of my code is in a giant views.py file that is nearly 2000 lines long (I'm using VSCode). Is this the normal way of doing things? Right now to make it easier
/r/django
https://redd.it/1l86aa3
Just finished a beginner Python course – is it worth learning Django now with AI advancing so fast?
Hi everyone,
I just finished a beginner Python course and I'm planning to start learning Django to get into backend development. But recently, I've been seeing a lot about AI tools like ChatGPT, Copilot, etc., being able to generate code, build APIs, and automate a lot of what backend developers do.
So now I'm wondering — is it still worth learning Django and backend development from scratch in 2025, or will most of this work soon be handled by AI?
I'm not expecting to be replaced tomorrow or anything, but I’m just unsure if it's a good long-term path or if I should shift toward something more future-proof.
A few questions I’d really appreciate input on:
Is backend development (with Django or similar frameworks) still a good skill to invest time in?
Will learning it help me become a better developer even if AI helps with code generation?
For those already working in the field, has AI significantly changed how backend work is done?
Would love to hear your thoughts or advice from anyone who's a bit further along!
Thanks in advance.
/r/djangolearning
https://redd.it/1l6a3ki
Wednesday Daily Thread: Beginner questions
# Weekly Thread: Beginner Questions 🐍
Welcome to our Beginner Questions thread! Whether you're new to Python or just looking to clarify some basics, this is the thread for you.
## How it Works:
1. Ask Anything: Feel free to ask any Python-related question. There are no bad questions here!
2. Community Support: Get answers and advice from the community.
3. Resource Sharing: Discover tutorials, articles, and beginner-friendly resources.
## Guidelines:
This thread is specifically for beginner questions. For more advanced queries, check out our [Advanced Questions Thread](#advanced-questions-thread-link).
## Recommended Resources:
If you don't receive a response, consider exploring r/LearnPython or join the Python Discord Server for quicker assistance.
## Example Questions:
1. What is the difference between a list and a tuple?
2. How do I read a CSV file in Python?
3. What are Python decorators and how do I use them?
4. How do I install a Python package using pip?
5. What is a virtual environment and why should I use one?
Let's help each other learn Python! 🌟
/r/Python
https://redd.it/1l8egg6
Project FileVault – A Secure File Storage CLI Tool (Compression + Encryption + TUI)
Hello Python devs,
I recently finished building FileVault, an Encrypted file storage tool with an interactive terminal user interface.
🎥 Demo video:
👉 https://www.youtube.com/watch?v=YXFQwEj1E1k
📦 GitHub repo:
👉 https://github.com/MazenYasser/file-vault-python
⸻
What my project does
• Lets you upload any file from your system via the terminal.
• Files are compressed using Zstandard (zstd).
• Then encrypted with a Fernet key, protected by PBKDF2 + user password.
• You can later download and decrypt files with just a few keypresses.
• It has a clean terminal UI using questionary, with navigation, path validation, progress bars, and contextual menus.
• Everything is local
⸻
Target audience
• People who spend most of their time in the terminal or enjoy TUI more than GUI (I know I do)
• Anyone who wants a secure and simple way to store files, even just for fun.
⸻
Comparisons
This isn’t trying to be a full-blown alternative to other tools.
FileVault is:
• More educational and exploratory in nature.
• Offers a simple, guided, TUI experience.
• It is a side project, mainly for learning streaming I/O, encryption, config handling and modular project structure.
⸻
Backstory
I watched ThePrimeagen">ThePrimeTime’s video: https://www.youtube.com/watch?v=UowtlZB2a70 reacting to the article “Be an engineer, not a frameworker.”
That really stuck with me. So I embarked on learning lower level programming concepts, to learn the inner workings of tools I use, even though I primarily work with Django. This started with
/r/Python
https://redd.it/1l872q5
Is using if TYPE_CHECKING
: to type the objects
manager a good practice?
Hey everyone,
To get my linter and IDE (free PyCharm) to recognize the type of the default objects
manager, I'm using this pattern:
# models.py
from typing import TYPE_CHECKING
from django.db import models
if TYPE_CHECKING:
from django.db.models.manager import Manager
class MyModel(models.Model):
# ... fields ...
# is this ok?
if TYPE_CHECKING:
objects: Manager["MyModel"]
I built a fullstack solopreneur project template with free cloud hosting and detailed tutorials
Hey everyone,
I’ve been working on a fullstack template aimed at solo devs or indie hackers who want to build and ship something without spending money on infrastructure. I put a lot of effort into making sure everything works out of the box and included step-by-step guides so you can actually deploy it—even if you’ve never done it before.
What’s in it:
Detailed Tutorials & config template to eploy backend to Vercel and frontend to Cloudflare (both have free tiers)
Supabase for database and auth (also free tier)
Generate frontend client based on backend API
Dashboard with metrics and analytics
User management and role-based access control
Sign up / sign in with OAuth
Task management with full CRUD
Pre-configured dev setup with Docker and hot reload
it’s meant to be used as a quick project starter for app developed by a single person, It followed solid backend/frontend practices, used modern tools (React 19, TypeScript, Tailwind, OpenAPI, etc.), and tried to keep the architecture clean and easy to extend.
frontend is based on this great project called shadcn-admin (https://github.com/satnaing/shadcn-admin)
If you’re trying to build and deploy a real app with no cost, this could be interesting to you. Whether you’re making a SaaS,
/r/Python
https://redd.it/1l9q16q
SimplePyQ - Queueing tasks in Python doesn't have to be complicated
Hey everybody!
I just wanted to share a small library I wrote for some internal tooling that I thought could be useful for the wider community, called SimplePyQ.
The motivation for this was to have something minimalistic and self-contained that could handle basic task queueing without any external dependencies (such as Airflow, Redis, RabbitMQ, Celery, etc) to minimize the time and effort to get that part of a project up and running, so that I could focus on the actual things that I needed.
There's a long list of potential improvements and new features this library could have, so I wanted to get some real feedback from users to see if it's worth spending the time. You can find more information and share your ideas on our GitHub.
Do you have any questions? Ask away!
TL;DR to keep the automod happy
# What My Project Does
It's a minimalistic task queueing library with minimal external dependencies.
# Target Audience
Any kind users, ideally suitable for fast "zero to value" projects.
# Comparison
Much simpler to set up and use compared to Celery. Even more minimalistic with less requirements than RQ.
/r/Python
https://redd.it/1l9frz7
Mastering Modern Time Series Forecasting: A Python Guide to Statistical, ML & Deep Learning Methods
I’ve been working on a Python-focused book called Mastering Modern Time Series Forecasting — written to bridge the gap between theory and practice for time series modeling.
It covers a wide range of methods, from classical models like ARIMA, ETS, Theta, MSTL, TBATS to modern machine learning and deep learning techniques like CatBoost, LightGBM, Transformers, N-BEATS, and TFT.
The focus is on both fundamentals and practical implementation, using tools like statsforecast
, mlforecast
, neuralforecast
, scikit-learn
, statsmodels
, PyTorch
, and Darts
. Topics include handling messy time series data, feature engineering, evaluation, and deployment.
📘 The book is in early release (220+ pages) and growing fast.
📂 A companion GitHub repo is live and code will be added progressively:
🔗 GitHub Repo
I’m publishing the book on Gumroad and LeanPub — links will be in the comments if anyone’s interested.
Open to feedback or discussion — thanks for reading!
/r/Python
https://redd.it/1l9gdhu
Deploying to vercel
How can i deploy a flask app to vercel with these requirements:
flask==3.0.2
flask-cors==4.0.0
scikit-learn==1.4.1.post1
numpy==1.26.4
xgboost==2.0.3
pandas==2.2.0
tensorflow-cpu==2.16.1
I am getting a maximum size of 300mb file limit
Note: I am using python 3.11 in my local flask app
/r/flask
https://redd.it/1l9d6xi
What was your first Django application?
Mine was accounting application for my trader character in EVE Online.
It read my buy/sell transactions from the official API, parsed the data with xml.sax, and calculated the profit margin per item. Also, it used special html tags for EVE's in-game browser.
/r/django
https://redd.it/1l8nr9n
Building Dynamic Django Forms
Hi guys, whats your proven strategy (and/ or library) for building dynamic django forms that can span multiple pages with save point.
/r/django
https://redd.it/1l8vonr
Host your flask app on AWS for free
Just wanted to share another method of hosting your app in a serverless manner using AWS, best part is for most projects it's free as it's well covered by the free tier's generous monthly million requests
We use zappa to package our app and push to Aws with an API gateway that is integrated with our flask packaged as a lambda function. Any API calls will then be routed by zappa's handler to appropriate Flask app's endpoints
Created a YouTube tutorial on this today: https://youtu.be/6Bk-hpI1mNA?si=GqrzhiduAwSKJjAf
Appreciate any feedback, thanks!
/r/flask
https://redd.it/1l8zdgg
Should I really use React/Vue with Django instead of alpine js?
I've been using alpine js and I was happy with it. Let me cut to the chase
How it works now: I have a page where user creates an instance. An instance has a bunch of characteristics and foreign key to product (which has category and name itself) and all the fields are static - just stylized selects and inputs, but there is just a change event handler which saves any changes in session so that user could go back to editing
What I'm trying to do: with alpine I replaced two selects (where user chooses product category and product name) with a single button - "select a product" and after clicking a modal appears with options depending on the step - either category or name, once both category and name are selected a card with this product appears and a button turns into "change a product"
What's wrong: everything worked just fine until I started filling this mess with initial values from draft form, so that you need to combine django {% if %} with alpine x-if which turned into a horrible flickering mess
P.S I also have tried using Vue js alongside django with SFC component and i really love it, especially
/r/django
https://redd.it/1l8vc1s
What version do you all use at work?
I'm about to switch jobs and have been required to use only python 3.9 for years in order to maintain consistency within my team. In my new role I'll responsible for leading the creation of our python based infrastructure. I never really know the best term for what I do, but let's say full-stack data analytics. So, the whole process from data collection, etl, through to analysis and reporting. I most often use pandas and duckdb in my pipelines. For folks who do stuff like that, what's your go to python version? Should I stick with 3.9?
P.S. I know I can use different versions as needed in my virtual environments, but I'd rather have a standard and note the exception where needed.
/r/Python
https://redd.it/1l8chj0
How to "reverse engineer" your junior django developer job search.
/r/django
https://redd.it/1l8ph3g
Starting django
Want to start with django I know models and all, I recently built a form where you can submit info and click a photo and the photo will be redirected to another page, but where do I start learning like things
/r/django
https://redd.it/1l8jdu6
Is uvloop still faster than asyncio's event loop in python3.13?
Ladies and gentleman!
I've been trying to run a (very networking, computation and io heavy) script that is async in 90% of its functionality. so far i've been using uvloop for its claimed better performance.
Now that python 3.13's free threading is supported by the majority of libraries (and the newest cpython release) the only library that is holding me back from using the free threaded python is uvloop, since it's still not updated (and hasn't been since October 2024). I'm considering falling back on asyncio's event loop for now, just because of this.
Has anyone here ran some tests to see if uvloop is still faster than asyncio? if so, by what margin?
/r/Python
https://redd.it/1l8fwu1
Could you assist me with this issue? This glitch appears in all browsers; why doesn't the scrolling function properly in my notebook?
https://redd.it/1l7x692
@pythondaily
Academic study on code debugging
Hi everyone, I’m conducting a short experiment for my master’s thesis in Information Studies at the University of Amsterdam. I’m researching how people explore and debug code in Jupyter Notebooks.
The experiment takes around 15 minutes and must be completed on a computer or laptop (not a phone or tablet). You’ll log into a JupyterHub environment, complete a few small programming tasks, and fill out two short surveys. No advanced coding experience is required beyond basic Python, and your data will remain anonymous.
Link to participate: https://jupyter.jupyterextension.com Please do not use any personal information for your username when signing up. After logging in, open the folder named “Experiment_notebooks” and go through the notebooks in order.
Feel free to message me with any questions. I reached out to the mods and they approved the post. Thank you in advance for helping out.
/r/Python
https://redd.it/1l81fjc