Python Daily
2.57K subscribers
1.48K photos
53 videos
2 files
38.9K links
Daily Python News
Question, Tips and Tricks, Best Practices on Python Programming Language
Find more reddit channels over at @r_channels
Download Telegram
Friday Daily Thread: r/Python Meta and Free-Talk Fridays

# Weekly Thread: Meta Discussions and Free Talk Friday 🎙️

Welcome to Free Talk Friday on /r/Python! This is the place to discuss the r/Python community (meta discussions), Python news, projects, or anything else Python-related!

## How it Works:

1. Open Mic: Share your thoughts, questions, or anything you'd like related to Python or the community.
2. Community Pulse: Discuss what you feel is working well or what could be improved in the /r/python community.
3. News & Updates: Keep up-to-date with the latest in Python and share any news you find interesting.

## Guidelines:

All topics should be related to Python or the /r/python community.
Be respectful and follow Reddit's Code of Conduct.

## Example Topics:

1. New Python Release: What do you think about the new features in Python 3.11?
2. Community Events: Any Python meetups or webinars coming up?
3. Learning Resources: Found a great Python tutorial? Share it here!
4. Job Market: How has Python impacted your career?
5. Hot Takes: Got a controversial Python opinion? Let's hear it!
6. Community Ideas: Something you'd like to see us do? tell us.

Let's keep the conversation going. Happy discussing! 🌟

/r/Python
https://redd.it/1nkohvq
Today I learned that Python doesn't care about how many spaces you indent as long as it's consistent

Call me stupid for only discovering this after 6 years, but did you know that you can use as many spaces you want to indent, as long as they're consistent within one indented block. For example, the following (awful) code block gives no error:

def say_hi(bye = False):
 print("Hi")
 if bye:
        print("Bye")

/r/Python
https://redd.it/1nkidxq
enso: A functional programming framework for Python

Hello all, I'm here to make my first post and 'release' of my functional programming framework, enso. Right before I made this post, I made the repository public. You can find it here.

# What my project does

enso is a high-level functional framework that works over top of Python. It expands the existing Python syntax by adding a variety of features. It does so by altering the AST at runtime, expanding the functionality of a handful of built-in classes, and using a modified tokenizer which adds additional tokens for a preprocessing/translation step.

I'll go over a few of the basic features so that people can get a taste of what you can do with it.

1. Automatically curried functions!

How about the function add, which looks like

def add(x:a, y:a) -> a:
return x + y

Unlike normal Python, where you would need to call add with 2 arguments, you can call this add with only one argument, and then call it with the other argument later, like so:

f = add(2)
f(2)
4

2. A map operator

Since functions are automatically curried, this

/r/Python
https://redd.it/1nksvm0
T-Strings: What will you do?

Good evening from my part of the world!

I'm excited with the new functionality we have in Python 3.14. I think the feature that has caught my attention the most is the introduction of t-strings.

I'm curious, what do you think will be a good application for t-strings? I'm planning to use them as better-formatted templates for a custom message pop-up in my homelab, taking information from different sources to format for display. Not reinventing any functionality, but certainly a cleaner and easier implementation for a message dashboard.

Please share your ideas below, I'm curious to see what you have in mind!

/r/Python
https://redd.it/1nkq8pt
FYI: PEP 2026 (CalVer) was shot down back in February - no jumping from 3.14.y to 3.25.y or 2025.x.y

PEP2026 discussed replacing the current Semantic Versioning with a Calender Versioning, where some options were 26.x.y (where 26 was from 2026), or 3.26.y (because there's currently a yearly release, they would just shift the minor version about 10 points).

Luckily this idea was shot down, back in Feb, because I was NOT looking forward to having to mess around with versions.

---

I'm mentioning it, because I recall a discussion back in Januari that they were going to do this, and quite a few people disliked the idea, so I'm happy to inform you that it's dead.

---

edit: It was shot down in this post

/r/Python
https://redd.it/1nl0x1p
Herramientas para trabajar en Django de mode API first

Quiero empezar a trabajar con Django y DRF definiendo primero la API (API first). Hago una definición de OpenAPI en un fichero YAML, pero no encuentro buenas herramientas para comprobar que mis vistas de Django cumplen con ese contrato.

/r/django
https://redd.it/1nl49u5
Best way to document my code ?

Hi, I would like to cleanly document my Python+Flask code ; this is my first time so I'm looking for help.

For now I've been doing it in a javadoc-style (see below), but i don't know if there are tools integrating it (VSCode integration, HTML doc generation, and other intelligent features). For instance I'm seing that python's typing library allows features similar to \\@param and \\@return that are closer to the code, that feels like a better idea than what I'm doing already.

In short, what is the standard(s), and what are the tools to exploit ?


Thanks in advance !



\---



Example of what I'm doing currently and want to improve on :

def routeAPIRequest(self, configFromPayload):
        """
        @param llmConfig a config dict, such as the output from processPayloadData()
                            can be None if no config coverride is meant

        @return Response    (meant to be transmitted in

/r/flask
https://redd.it/1nl4q4l
A script to get songs from a playlist with matching total length

#What my project does
Basically, you input:

- A public youtube playlist

- Target duration

You get:

- Song groups with a matching total length

#Target Audience

So I think this is one of the most specific 'problems'..

I've been making a slow return to jogging, and one of the changes to keep things fresh was to jog until the playlist ended. (Rather than meters, or a route)

I am incrementing the length of the playlist by 15 seconds between each run, and each time finding a group of songs with a matching length can be tiring, which is why I thought of this 😅

 

So I guess this is for people who want a shuffled playlist, with a specific duration, for some reason.

This is 'py-playlist-subset', try it out 👀

https://github.com/Tomi-1997/py-playlist-subset

/r/Python
https://redd.it/1nl4bxv
Doubt regarding a resource

I wanted ask you guys how is this django tutorial???: https://www.youtube.com/playlist?list=PL4cUxeGkcC9iqfAag3a\_BKEX1N43uJutw , this is a tutorial by net ninja

I know people here suggest the official docs over everything else, but i wanna get done with the basics of django and straight away start with building projects

If you guys have any other resource suggestion i am all ears

/r/djangolearning
https://redd.it/1nkw4tp
I just released reaktiv v0.19.2 with LinkedSignals! Let me explain what Signals even are

I've been working on this reactive state management library for Python, and I'm excited to share that I just added LinkedSignals in v0.19.2. But first, let me explain what this whole "Signals" thing is about.

# I built Signals = Excel for your Python code

You know that frustrating bug where you update some data but forget to refresh the UI? Or where you change one piece of state and suddenly everything is inconsistent? I got tired of those bugs, so I built something that eliminates them completely.

Signals work just like Excel - change one cell, and all dependent formulas automatically recalculate:

from reaktiv import Signal, Computed, Effect

# Your data (like Excel cells)
name = Signal("Alice")
age = Signal(25)

# Automatic formulas (like Excel =A1&" is "&B1&" years old")
greeting = Computed(lambda: f"{name()} is {age()} years old")

# Auto-display (like Excel charts that update automatically)
display = Effect(lambda: print(greeting()))
# Prints: "Alice is 25 years old"



/r/Python
https://redd.it/1nl9f0h
Saturday Daily Thread: Resource Request and Sharing! Daily Thread

# Weekly Thread: Resource Request and Sharing 📚

Stumbled upon a useful Python resource? Or are you looking for a guide on a specific topic? Welcome to the Resource Request and Sharing thread!

## How it Works:

1. Request: Can't find a resource on a particular topic? Ask here!
2. Share: Found something useful? Share it with the community.
3. Review: Give or get opinions on Python resources you've used.

## Guidelines:

Please include the type of resource (e.g., book, video, article) and the topic.
Always be respectful when reviewing someone else's shared resource.

## Example Shares:

1. Book: "Fluent Python" \- Great for understanding Pythonic idioms.
2. Video: Python Data Structures \- Excellent overview of Python's built-in data structures.
3. Article: Understanding Python Decorators \- A deep dive into decorators.

## Example Requests:

1. Looking for: Video tutorials on web scraping with Python.
2. Need: Book recommendations for Python machine learning.

Share the knowledge, enrich the community. Happy learning! 🌟

/r/Python
https://redd.it/1nljibj
🚀 DRF Auth Kit - Complete DRF Authentication with Type Safety & OpenAPI


After months of development and fixing issues from the initial release, I'm excited to reintroduce DRF Auth Kit - a modern Django REST Framework authentication toolkit that addresses the pain points of existing packages.

What makes it different:

🔥 Full Type Safety - Complete type hints with mypy/pyright support
📋 Perfect OpenAPI Schema - Auto-generated docs that work flawlessly with any client generator
🍪 JWT Cookies - Secure HTTP-only cookies with automatic token management
🔐 Easy MFA Setup - Email & app-based MFA with backup codes, proper OpenAPI schemas included
🌐 Simple Social Auth - Django Allauth integration with minimal setup (like headless mode but easier)
🌍 57 Languages - Built-in i18n support

Why we built this:

Inspired by dj-rest-auth and django-trench, but enhanced to solve their limitations:
- No more broken OpenAPI schemas
- Complete type safety throughout
- Zero manual schema fixes needed
- Easy customization without breaking functionality

Perfect for:
- Teams wanting bulletproof API documentation
- Projects requiring type-safe authentication
- Anyone tired of manually fixing auth schemas
- Developers who value clean, well-documented code

pip install drf-auth-kit[all]  # Includes MFA + social auth


GitHub: https://github.com/forthecraft/drf-auth-kit
📚 Docs: https://drf-auth-kit.readthedocs.io/

Would love feedback from the community!


/r/django
https://redd.it/1nl9qy9
Why isn't the copy() method part of the Sequence and MutableSequence ABCs?

The Sequence ABC from collections.abc does not include an abstract method copy(). What are the reasons for that design choice?

Note that I am not asking how to work with that design choice. Instead I am trying to understand it.

/r/Python
https://redd.it/1nllur9
Looking to get hire in the django as a freelancer

i am having a experience of 2+ years as Django, next and react. i am looking for part time, contract or freelancing jobs. worked on more than 4 or 5 project intermediate level. Looking forward to get connected.

/r/django
https://redd.it/1nlgouk
Scintilla, Qt and alternative text editor widgets

Hello fellow python enjoyers,

I'm currently considering moving away from PyQt6 to go on PySide6 due to license issues. However, it would imply moving away from QScintilla as a text editor too, since there is no bindings for Scintilla on PySide side.

I don't want to go back to "default" QPlainTextEdit since my needs are close to the ones of a Source Code editor (especially indentation guides).

Do any of you know an alternative? I'm leaning towards Monaco via QTMonaco, but there might be better options or easier to adapt (I still need to find out resources regarding Monaco).

/r/Python
https://redd.it/1nltf58
Flask + ReactJs + MySQL + Crawler

Is it possible to create a web app for web crawling such as Broken Acces Control vulnerability using said language? I was planning to use

Backend : Flask
Frontend : ReactJS
Database : MySQL
Crawler : Playwright

Also, does that mean using reactjs as frontend will be different as using PHP, HTML and Bootstrap??

/r/flask
https://redd.it/1nlve3z
Fake OS - Worth making?

So, a while ago i discovered this repo on github: https://github.com/crcollins/pyOS

In summary, its a program trying to simulate an OS by having a kernel, programs (terminal commands), a filesystem etc.

Ive been impressed of the dedication for something that isnt useful in your everyday life. Though ive seen the small group of repositories making similar projects fascinating, and thought about making my own, but ive yet to come up a reason for it.

So here i am, wanting to ask:

Is something like this worth making, following the structure of a real computer, containing a kernel, drivers, the OS layer, BIOS etc?

What would be ways to make it useful / more interesting?

All feedback is appreciated, thanks in advance :O

/r/Python
https://redd.it/1nlwpe8
Which Django Youtube channel do you recommend?

Hi Django lovers.

I want to learn Django exactly, to do this i can go with Django offical documents but i know a few awesome Django channel that i want to watch all video because there are many things with Django.

Problem is, there are so many videos.


https://www.youtube.com/@CodeWithStein 363 videos 180 hours

https://www.youtube.com/@bugbytes3923 423 videos 128 hours

https://www.youtube.com/@CloudWithDjango 222 videos 68 hours


What do you think, where should i start with?

Thanks




/r/django
https://redd.it/1nluode