Python Daily
رفتن به کانال در Telegram
Daily Python News Question, Tips and Tricks, Best Practices on Python Programming Language Find more reddit channels over at @r_channels
نمایش بیشتر2 580
مشترکین
-424 ساعت
-127 روز
-1130 روز
در حال بارگیری داده...
کانالهای مشابه
ابر برچسبها
اشارات ورودی و خروجی
---
---
---
---
---
---
جذب مشترکین
سپتامبر '26
سپتامبر '26
+7
در 0 کانالها
اوت '26
+43
در 0 کانالها
Get PRO
ژوئیه '26
+60
در 0 کانالها
Get PRO
ژوئن '26
+122
در 0 کانالها
Get PRO
مه '26
+55
در 1 کانالها
Get PRO
آوریل '26
+52
در 0 کانالها
Get PRO
مارس '26
+41
در 0 کانالها
Get PRO
فوریه '26
+38
در 0 کانالها
Get PRO
ژانویه '26
+37
در 0 کانالها
Get PRO
دسامبر '25
+42
در 0 کانالها
Get PRO
نوامبر '25
+40
در 0 کانالها
Get PRO
اکتبر '25
+33
در 0 کانالها
Get PRO
سپتامبر '25
+23
در 0 کانالها
Get PRO
اوت '25
+30
در 0 کانالها
Get PRO
ژوئیه '25
+35
در 0 کانالها
Get PRO
ژوئن '25
+22
در 0 کانالها
Get PRO
مه '25
+22
در 0 کانالها
Get PRO
آوریل '25
+26
در 0 کانالها
Get PRO
مارس '25
+32
در 0 کانالها
Get PRO
فوریه '25
+26
در 0 کانالها
Get PRO
ژانویه '25
+39
در 0 کانالها
Get PRO
دسامبر '24
+42
در 0 کانالها
Get PRO
نوامبر '24
+163
در 0 کانالها
Get PRO
اکتبر '24
+159
در 1 کانالها
Get PRO
سپتامبر '24
+75
در 0 کانالها
Get PRO
اوت '24
+72
در 0 کانالها
Get PRO
ژوئیه '24
+103
در 0 کانالها
Get PRO
ژوئن '24
+123
در 1 کانالها
Get PRO
مه '24
+95
در 1 کانالها
Get PRO
آوریل '24
+75
در 0 کانالها
Get PRO
مارس '24
+115
در 0 کانالها
Get PRO
فوریه '24
+179
در 0 کانالها
Get PRO
ژانویه '24
+173
در 0 کانالها
Get PRO
دسامبر '23
+167
در 7 کانالها
Get PRO
نوامبر '23
+23
در 4 کانالها
Get PRO
اکتبر '23
+33
در 3 کانالها
Get PRO
سپتامبر '23
+29
در 0 کانالها
Get PRO
اوت '23
+37
در 0 کانالها
Get PRO
ژوئیه '23
+40
در 0 کانالها
Get PRO
ژوئن '23
+51
در 0 کانالها
Get PRO
مه '23
+66
در 0 کانالها
Get PRO
آوریل '23
+58
در 0 کانالها
Get PRO
مارس '23
+68
در 0 کانالها
Get PRO
فوریه '23
+57
در 0 کانالها
Get PRO
ژانویه '23
+77
در 0 کانالها
Get PRO
دسامبر '22
+62
در 0 کانالها
Get PRO
نوامبر '22
+94
در 0 کانالها
Get PRO
اکتبر '22
+78
در 0 کانالها
Get PRO
سپتامبر '22
+98
در 0 کانالها
Get PRO
اوت '22
+80
در 0 کانالها
Get PRO
ژوئیه '22
+95
در 0 کانالها
Get PRO
ژوئن '22
+101
در 0 کانالها
Get PRO
مه '22
+119
در 0 کانالها
Get PRO
آوریل '22
+85
در 0 کانالها
Get PRO
مارس '22
+102
در 0 کانالها
Get PRO
فوریه '22
+83
در 0 کانالها
Get PRO
ژانویه '22
+86
در 0 کانالها
Get PRO
دسامبر '21
+72
در 0 کانالها
Get PRO
نوامبر '21
+68
در 0 کانالها
Get PRO
اکتبر '21
+41
در 0 کانالها
Get PRO
سپتامبر '21
+28
در 0 کانالها
Get PRO
اوت '21
+40
در 0 کانالها
Get PRO
ژوئیه '21
+45
در 0 کانالها
Get PRO
ژوئن '21
+38
در 0 کانالها
Get PRO
مه '21
+37
در 0 کانالها
Get PRO
آوریل '21
+46
در 0 کانالها
Get PRO
مارس '21
+42
در 0 کانالها
Get PRO
فوریه '21
+48
در 0 کانالها
Get PRO
ژانویه '21
+53
در 0 کانالها
Get PRO
دسامبر '20
+1 047
در 0 کانالها
| تاریخ | رشد مشترکین | اشارات | کانالها | |
| 06 سپتامبر | 0 | |||
| 05 سپتامبر | 0 | |||
| 04 سپتامبر | +1 | |||
| 03 سپتامبر | 0 | |||
| 02 سپتامبر | +4 | |||
| 01 سپتامبر | +2 |
پستهای کانال
Reproducibility seems to be headed towards irrelevance in ML research. Is it too late? D
I feel that reproducibility is now a lost cause in machine learning research for three reasons:
1. Many research is moving towards the physical AI territory, where you need expensive hardwares or even entire laboratories with high-speed cameras, in order to perform an experiment. You truly have no idea if the experiment can be reproduced and have to trust the demo. But demos are not perfectly reliable. Plus people are incentivized to only show the part of the demo that works. The entire system can fall apart the moment the recording stops.
2. You have big AI companies releasing various tools, which they claim to solve a host of problems with certain amount of accuracy or efficiency. Unless you work at those companies there is really no proof of that and you will have to take their words on it. They have strong financial incentive to blow-up those figures. There is no solid way to check it either because the problem that they solve are so vague and subjective.
3. We need to address the elephant in the room which is that people are incentivized to produce non-reproducible work to prevent their lunch being eaten by their competitors or looking bad. That's why some of us will probably never get a reply when we email the authors for their code.
So what now? Maybe everything will be OK because we can contrast it with scientific progress in earlier parts of history, e.g., building the atomic bomb or sending people to the moon. These projects had low "outside reproducibility" but high "internal reproducibility". Plus all these work were mathematical in nature and carefully checked. But I don't think many areas of machine learning research is like that. What do you think? Should reproducibility be abandoned? If not how is it best implemented going forward?
https://redd.it/1w92eis
@pythondaily
| 2 | Astral's endorsements for Python's first Packaging Council
Astral has announced their endorsements for Python's first packaging council elections.
- Read their announcement here - https://astral.sh/blog/python-packaging-council
- DPO discussion link - https://discuss.python.org/t/ppc-endorsements-from-astral-the-uv-team/
PPC election details:
- https://pyfound.blogspot.com/2026/08/announcing-packaging-council-election.html
- Nominees (17 nominees for 5 spots) - https://pyfound.blogspot.com/2026/08/announcing-packaging-council-election.html
Note: Voting is currently open and ends on Tuesday, September 15th, 2:00 pm UTC
What are your thoughts? The candidates they have nominated are fine, they are/have been heavily involved in packaging in the past.
https://redd.it/1w928wf
@pythondaily | 13 |
| 3 | AIStats 2027 Questions [D]
Hi All,
Was reading AIStats' website and it seems like abstract submission is due in 3 weeks.
Does anyone know where to find the LaTex template for 2027? It seems like very little information is available on their website.
Another question, is a Quant Finance paper a better fit for AIStats or ICLR?
Some background about the paper:
* Rejected by UAI with 76654, had some errors with proofs had to fix it by re-writing 9 pages during rebuttal. AC rejected the paper saying the changes were too substantial and unable to be fully verified during rebuttal period.
* Resubmitted the fixed paper to a finance conference, won best paper award (best paper for this conference usually end up in journals like JQFA, which is just 1 tier below the big 3 in finance), had the chief editors of a Q1 finance/math journal in the conference verbally offering he will take this paper if we submit it to his journal. Unfortunatley my department requires at least 1 Comp Sci paper to graduate, so my plan is to try and get this paper accepted into a Comp Sci conference, then submit an extension to that Q1 Finance/Math journal.
* Rejected again at ICDM, despite having all positive scores. Our AC meta-review was blank so we still do not know why we were rejected. All of our emails receieved no reply.
I am torn between ICLR or AIStats to re-submit this paper to. My worries are:
* In comp sci venues we frequently get comments like "this paper lacks novelty. The method is just XXXXX, the math is just XXXXX."
* But I had a scroll through at previous year's AIStats papers for key words like finance and there were none. It seems like AIStats is very pure stats, not that applied. My co-author is worried that the math in our paper is not hardcore enough.
We have never submitted to neither venues in the past. Would be nice to get some advice.
https://redd.it/1w8l0hn
@pythondaily | 13 |
| 4 | djevops: Self-host Django easily
https://github.com/mherrmann/djevops
https://redd.it/1w8t04u
@pythondaily | 19 |
| 5 | Djangos File structure as a Force Graph
Hey Everyone I found this visual quite interesting.
Just goes to show how big Django really is (Flask has only like 50 nodes/files when plotted as graph).
Each dot is a file (excluding non code files) and each line is an import between files.
Processing img 4kb5ra745vnh1...
https://redd.it/1w8r1er
@pythondaily | 16 |
| 6 | settings while Astra deeply debugged the gensim error. It found significant uplift through this process, though that only allowed it to roughly match Astra's numbers (see table below). Astra seemed to hit a home run right off the bat with its training process, so I don't know if it would have executed the same workflow or not. Astra also mutated my venv by adding PyTorch, when I built it a certain way to force the models to use TensorFlow+Keras for more concise code, then reversed course and went with TF anyways in the end. The models finished in roughly the same amount of wall-clock time.
Here are the final results, with one minor caveat -- Astra's test set scores exceed its val set, so it might have drawn a lucky test set that increases its score artificially (the pipeline has no leaks or data quality issues for either model, however):
Best Logistic Regression and LSTM for each model, ranked by macro F1:
| Model | Classifier | Best representation | Accuracy | Macro F1 |
|---|---|---|---|---|
| **Fable 5.1** | Logistic Regression | TF-IDF | 0.9883 | 0.9881 |
| **Fable 5.1** | Simple LSTM | Word2Vec-Skip-gram | 0.9718 | 0.9705 |
| **Astra** | Logistic Regression | TF-IDF | 0.9969 | 0.9969 |
| **Astra** | Simple LSTM | BoW | 0.9781 | 0.9765 |
I do want to note that these final scores were after I provided both models identical feedback on common pitfalls of the text data cleaning, vectorization, and model training process once their initial runs were complete. Both models improved by a similar amount (0.02-0.04 F1 and Accuracy) from that generic guidance (not tailored at all to either's specific shortcomings or step of the process). That was the only intervention in otherwise autonomous work, and it was just because I wanted to see if they could learn to improve their approaches with additional context on optimal methodology, which they both did to similar degrees.
I hope this post offers a little bit of help in some way for folks wondering how either model stacks up for real work, particularly if you're an AI/ML student like me.
https://redd.it/1w8g1gk
@pythondaily | 13 |
| 7 | Astra vs. Fable 5.1 on real ML tasks -- tradeoffs, strengths, shortcomings P
I ran a side-by-side ML text-processing and model-training workflow using Fable 5.1 vs. Astra (both on xhigh), and the results could not have been more different. Warning, long post.
TL;DR -- Astra codes more agentically, Fable more coherently. Fable writes better and follows directions better. Astra's final outcome was slightly better, and its scientific rigor/reproducibility was noticeably stronger. Both models improved their F1/Accuracy by 0.02-04 after human feedback on their approach, demonstrating that neither have mastered the AI/ML text processsing, vectorization, and model training process completely.
Astra is a better coder, writing a stricter evaluation protocol (70/15/15 train/val/test vs. Fable's basic 80/20) that selected its model using a held-out validation set vs. Fable's simpler test F1-based selection. It also debugged more deeply, as both models hit a gensim 4.4 compiled-kernel bug: Fable tried to figure it out, failed, and just hid the stderr notices on affected runs (though told me it had done so), while Astra root-caused it aggressively, then fixed the environment by downgrading gensim alongiside compatible NumPy/SciPy dependencies.
Astra wrote hardened training-run.py code the forced the uv venv it rebuilt without changing my default one, SHA-256'd the corpus to ensure reproducibility on later runs, output a split manifest and run-summary.json, and rendered a headless browser for QA with screenshots (not sure this was necessary, but impressive overkill all around). Fable's builder script was ephemeral, living only in tmp, and less intense overall.
Astra deployed subagents more effectively, making use of my pre-built notebook-reviewer and citation-checker agents, the former of which caught a real bug via review (sentence-final word-loss tokenization defect) and fixed it, retaining a regression test in the process. Fable overlooked this issue because, for some reason, it did not call the subagents I had available (which is surprising, usually it's pretty good about this).
If you're looking for an agent to autonomously grind through a broken environment, leaving a forensic audit trail, that's Astra. However, this review isn't over yet, and Fable is about to make a comeback.
Astra confidently shipped a significant verifiable text encoding defect. Working with UTF-8 data, Astra insisted Windows-1252 decoding preserves currency symbols, but the final HTML output shows mojibake throughout where currency symbols were in the original data. Fable read UTF-8, verified it, and rolled with the boring default for correct output.
I also had both models draft an analysis report for the run, and Fable's was significantly more insightful. As much as I hate Claude's recognizable writing style, a) 5.1 has toned down the Claudeisms significantly, and b) Fable went above and beyond my grading rubric, running an ablation on different parts of the text pre-processing pipeline to surface an expensive step that does basically nothing, and noting a discrepancy in the classification ranking based on a complexity I'd have overlooked. For writing prose, I'd pick Fable 5.1 any day, and I haven't said that about Claude in a while.
Speaking of writing, Fable writes code that is more idiomatic and readable. It definitely resembles more what I would write than what an LLM would choose to write without constraints (and yes, I had a whole coding-conventions.md document that applied my requirements to both models, Fable just followed it better and writes more naturally to start with). There were some parts of Astra's code where I had to squint really hard to figure out what was going on, and why. This matters to me because I'm not the strongest coder (still trying to get better), and I need to understand the code to learn from it.
Finally, Fable scoped its work better: It spent its time and tokens doing repeated runs, tweaking hyperparamters and retraining the models to find the optimal | 13 |
| 8 | 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! 🌟
https://redd.it/1w8glvb
@pythondaily | 16 |
| 9 | Flask-RPBAC — a lightweight role/permission authorization extension, looking for feedback before calling it production-ready.
Hey all — I've been building Flask-RPBAC, a small authorization extension for Flask that handles role- and permission-based access control without imposing a data model or ORM on you.
The core idea: you write loader functions that return the current user's roles/permissions (from wherever — DB, ORM, cache), and RPBAC handles evaluating access rules against them. It doesn't touch authentication at all — that's intentionally left to whatever you're already using (Flask-Login, sessions, etc.).
A few things it does:
Route and blueprint-level protection, composable (blueprint + route rules stack, not override)
Role() / Permission() with match="any"/"all", plus All/Any composition and &/| operators for expressing nested rules
Three ways to handle rejected requests: default JSON 403, raise-and-handle-yourself, or a custom rejection hook.
Optional in-memory caching keyed by user identity (explicitly not meant as a production cache replacement yet)
A flask rpbac-audit CLI command to list what's actually protected
Loud RuntimeError if you use @permission_required without registering a permission loader, instead of silently failing closed.
Docs: https://flask-rpbac.readthedocs.io/en/latest/
PyPI: https://pypi.org/project/Flask-RPBAC/
GitHub: https://github.com/JohnStares/flask_rpbac
It has a test suite and CI running, and I'm not calling it production-ready yet — I'd rather have people try to break it first. Specifically looking for:
Edge cases in the All/Any/operator composition logic
Opinions on the loader/decorator split — does it feel natural or awkward in a real app?
Anything that feels like a footgun in the error-handling setup
Issues and PRs welcome, security stuff via the SECURITY.md process rather than a public issue. Appreciate any eyes on it.
https://redd.it/1w87mty
@pythondaily | 15 |
| 10 | GPT-6 reportedly jailbroken within 24 hours using an extended Task-in-Prompt (TIP) attack N
A researcher has reported a jailbreak of GPT-6 Astra within a day after release.
The attack is described as combination of TIP (Task-in-Prompt) attack from ACL 2025 paper with four other unnamed techniques.
TIP attacks exploit the model’s reasoning/instruction-following behaviour by hidding the harmful objective inside another task, like solving a cipher or executing a Python code. For GPT-6, the researcher says the original minimal TIP attack was no longer sufficient and had to be reworked.
They have reportedly disclosed the details privately to OpenAI rather than publishing the jailbreak.
The same researcher reported jailbreaking GPT-5 within an hour of its release a year ago.
Source: screenshot/post from the researcher; their ACL 2025 TIP paper linked in the original post.
https://redd.it/1w89m36
@pythondaily | 20 |
| 11 | NeurIPS 2026 Automatic Reference Checker R
Just received an email about the automatic reference/citation checker. Did anyone receive a follow up email about whether the checker was included in the paper's decision making too, along with the general instructional email?
https://redd.it/1w7sljy
@pythondaily | 21 |
| 12 | Entire Flask app in a string! Thanks Claude Code
https://redd.it/1w7tzla
@pythondaily | 29 |
| 13 | Mark Your Calendars: Jupyter Day 2026 is Coming to San Jose!
https://blog.jupyter.org/mark-your-calendars-jupyter-day-2026-is-coming-to-san-jose-bbaad863421c
https://redd.it/1w7opx1
@pythondaily | 24 |
| 14 | When scaling application pods with SQLAlchemy pools, who redistributes existing connections?
I’m running application pods that use SQLAlchemy’s connection pool to connect to PostgreSQL. Each pod has its own pool, so when I scale the application from, say, 3 to 10 replicas, the new pods create new pools while the existing pooled connections remain open.
If PostgreSQL has read replicas behind a Kubernetes Service or a proxy, I assume new connections might reach the new replicas, but the existing long-lived pooled connections will remain attached to the old replicas.
Who is normally responsible for redistributing those existing connections after scale-out?
https://redd.it/1w7tis5
@pythondaily | 20 |
| 15 | Language Models Can Control Their Own Attention R
# Abstract
Language models spend most of their attention on a small fraction of context, yet they read the entire KV cache to find the few tokens that matter. If the user asks about a previous detail in a 1M-token conversation, global attention layers must scan the full context to generate each token of the reply. A prominent approach mitigates this cost by pre-selecting relevant tokens via lightweight proxy scores, but this extrinsic scoring still incurs O(N) per step. We take an intrinsic approach motivated by the simple question: wouldn't the model already know which parts of the context are relevant? To this end, we introduce Declarative Attention (DA), a protocol that elicits the model to declare where it needs to attend within its chain-of-thought, partitioning generation into three modes: <global> (full context), <focus> (a specific region), and <local> (recent output only). The inference engine parses these declarations like tool calls and skips most of the KV cache read. Under zero-shot evaluation across 15 long-context tasks, DA on off-the-shelf models (Gemma-4-31B, Qwen-3.6-27B) significantly reduces total attended tokens during decoding (52.0%, 31.1%) with modest accuracy drops (1.27pp, 2.75pp) that shrink with model scale. DA unlocks a new axis of sparse attention, with further potential under training-based methods that future work can explore.
Subjects:
Computation and Language (cs.CL); Artificial Intelligence (cs.AI); Machine Learning (cs.LG)
Cite as:
arXiv:2609.02737 [cs.CL\]
(or arXiv:2609.02737v1 [cs.CL\] for this version)
https://doi.org/10.48550/arXiv.2609.02737
Focus to learn more
https://redd.it/1w7sgf3
@pythondaily | 19 |
| 16 | django or fastapi
i am a biginner/intermediate and i picked up fastapi as my first framework on backend dev ,
after months of learning and using fastapi , i feel overwhelmed like there are so many things to import(i cant even remember what i need to import when i need to do something) , complex syntax, yes i have build some cool projects around it but it was mostly ai help even though i understood the logic .its like i have to do the setup from scratch and when iam to the point of actually writing logic i feel down.
thats why i was thinking of switching to django rn , so now i am confused again whether i should do it or no (i dont even have a intern experience)
is my reason correct for trying to switch as beginner or will same problem occur in django as well , thats why im in django reddit
it would be really helpful if u could share your thoughts
https://redd.it/1w7qy9b
@pythondaily | 20 |
| 17 | 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! 🌟
https://redd.it/1w7l34y
@pythondaily | 20 |
| 18 | What is the general design of these new math solving systems? D
From what I've seen online so far, the description of these systems is roughly:
They asked the model (often Aster) to generate statements in LEAN and then submit those to a LEAN compiler to be checked. Based on the results of attempting the LEAN compilation, they somehow add those statements as fact. When the full proof in LEAN compiles, the system is finished.
I can imagine trying to jam as much of a proof as possible into the context window but some of the papers these systems have produced are hundreds of pages. To me this would indicate that somehow the paper is being built piece by piece and being assembled before being submitted to LEAN. This resonates with the part of my understanding that after checking LEAN compilation there's some kind of management of "facts."
I would like to try to implement my own janky version and see if it can answer a question I have about higher dimensional geometry. I'm struggling to find a meaningful way to compose larger ideas from smaller ones. I can imagine it's relatively simple if you know what to do.
What things have you seen? Do you have any ideas you haven't seen that might be interesting to try? Is this a fool's errand because you really need huge amounts of hardware to do anything meaningful? I would welcome any thoughts or links on the matter, cheers
https://redd.it/1w7glyo
@pythondaily | 11 |
| 19 | Django Fundraiser less than 1 Week Left!
RETURNERS AND RENEWALS, and new users, everyone gets PyCharm Pro 30% off, and 100% goes to the DSF!
It's literally completely charity and you get something back. The way renewals work is that it adds 12 months on to your existing subscription. If you have 5 months left, now you would have 17, nothing wasted.
Use this link: https://www.jetbrains.com/pycharm/promo/support-django/
This is a big deal for the DSF, particularly to have renewals included, which is a first for us this year. Please help us out.
You can also donate on our website. https://www.djangoproject.com/fundraising/
Particularly if your company is interested in becoming a corporate member of the DSF, let me know. You can reach me here or at catherine@djangoproject.com Also, if your company would be interested in sponsoring DjangoCon 2027, you can talk to me about that too.
https://redd.it/1w7bqdk
@pythondaily | 17 |
| 20 | Just had an interview call
I’m a self taught programmer not a non CS graduate, after many years and millions of applications finally someone called me and its one of the beggest companies in the country, the funny thing literally the interview lasted 3 minutes the hr ended it right after we talked about legal documents. Anyway i felt very motivated. Any thoughts?
https://redd.it/1w7dz07
@pythondaily | 15 |
