FeaturesPricingTopicsBlogGuides
← All topics

Python

162 articles from DEV Community, Medium, Towards Data Science and more. Refreshed every few hours.

DEV Community

VITI Magazine FAQ: BIA for Dummies & Running an Ed25519 BIGF Gate in 50 Lines of Python

Welcome to the **VITI Magazine* FAQ edition—where we skip the 50-page enterprise risk matrices, banish Change Advisory Board (CAB) theater, and replace hopeful PDF policies with deterministic runtime physics.* If you are trying to figure out how to keep autonomous AI agents (or over-caffeinated deployment pipelines) from wrecking production without hiring an army of compliance consultants, here is the entire Business Impact Governance Framework (BIGF v2.4) boiled down to three blunt questions an

PythonProgrammingDevOps
13 Nov 2026
DEV Community

Fixing one bug in my security tool would have hidden every alert in my test project

I maintain depquiet. It sits on top of pip-audit, uv audit and npm audit and tries to cut down the noise. The one rule I care about is that it should never hide something real. This week I found out how close I came to breaking it with what looked like a simple bug fix. depquiet had an EPSS filter. EPSS is a score from FIRST.org that estimates how likely a CVE is to get exploited in the next 30 days. My defaults were: under 10%: filter it out under 30%: move it to "review" I picked those numbers

PythonProgrammingCybersecurity
12 Nov 2026
DEV Community

Free LLM APIs for coding assistants

Free LLM APIs for coding assistants Yes, you can point an editor plugin, a CLI coding agent, or a small script at an OpenAI-compatible base URL and a free-tier key. The setup is the same pattern as any other compatible API: a published base URL, the provider's key in the environment, and a model id copied from that provider's official docs. What changes is the volume. A chat playground sends one request when you press enter. A coding assistant may send many requests for a single edit, plus ret

PythonProgrammingLarge language models
12 Nov 2026
Medium

Celery: Background Tasks & Message queues

"What Happens Behind the Scene? How Celery Keeps Application Fast and Responsive" Continue reading on Medium »

PythonProgrammingTechnology
12 Nov 2026
DEV Community

How stable is your mean? A small bootstrap experiment in a Python notebook

Fourteen fictional tasks took between 17 and 52 minutes. Their mean is a useful summary, but how much does that summary depend on a small sample and one long observation? This notebook compares mean and median, resamples the observations, plots the distribution of resampled means, and tests a deliberate alternative dataset. It also demonstrates a practical notebook habit: restart and run every cell before trusting the final chart. The data is fictional. It is not a claim about anyone's productiv

PythonProgramming
12 Nov 2026
DEV Community

I built a search engine from scratch to show my kids how Google finds things so fast

How does a search box find one word in a million pages in the blink of an eye? It certainly isn't reading them all while you wait. I've been coding for 30+ years and I'd never actually built one, so I did. PySearch is a small full-text search engine in Python, with every idea explained in plain English. It has no dependencies and it's nowhere near Elasticsearch, but you can read the whole thing. pip install fromscratch-pysearch The docs open with a picture I love. Imagine a librarian who has re

PythonProgramming
12 Nov 2026
Medium

URL Routing in Web Frameworks: How Websites Know Which Page to Show

Imagine opening an online shopping website and clicking on a product. Within seconds, its details appear on your screen. But have you ever… Continue reading on Medium »

PythonProgrammingSoftware engineering
12 Nov 2026
DEV Community

How to read and validate a CAS Registry Number (with a Python check-digit example)

A CAS Registry Number (CAS RN) is a unique numeric identifier assigned by the Chemical Abstracts Service to a chemical substance. Unlike a trivial name, it does not change when people use a different synonym, which makes it the most practical key for matching substances across safety data sheets (SDS), supplier catalogues and datasets. A CAS number has three parts separated by hyphens: XXXXXXX-YY-Z. the first part has 2 to 7 digits, the second part has exactly 2 digits, the last part is a single

PythonProgramming
12 Nov 2026
DEV Community

Generate a PDF from JSON in one API call (try it free, no signup)

Most apps end up generating invoices, receipts, or certificates. You can run headless Chrome yourself, or you can send a template and some JSON and get a PDF back. We built getpdf, a template-to-PDF REST API. You can try it in the browser with no account at getpdf.dev/#try. Pick invoice, receipt, or certificate, edit the fields, and download the PDF. That playground is rate-limited, doesn’t accept raw HTML or URLs, and adds a “Made with getpdf” footer. The API, once you have a free key, is less

PythonProgrammingJavaScript
12 Nov 2026
DEV Community

Roll Back the Whole SQLite Batch When One Row Breaks a Constraint

A multi-row import can fail after an earlier row has already been inserted. Seeing an exception from executemany does not, by itself, answer whether the database still contains that earlier row. Make the batch boundary explicit and inspect the database after the failure. This Python 3.12 exercise uses a fresh in-memory SQLite database. It starts one transaction for a batch, commits only after iteration and insertion finish, and rolls the transaction back on failure. An already committed row belo

PythonProgramming
12 Nov 2026
DEV Community

Aphrodite Engine - a serving engine in the vLLM lineage, now renamed Sonar, and what my two 16 GB cards would need from it

First, the finding that changes how this post should be read, because I checked it first: the repository at PygmalionAI/aphrodite-engine no longer exists under that name. The GitHub API returns a permanent redirect for it (repository id 657414607 - the same id behind dphnAI/sonar, created 23 June 2023); the README at main now describes the project as Sonar, and the one at tag v0.22.0 reads "Sonar (formerly Aphrodite Engine)". This is not a successor project that claims to continue it: it is the

PythonProgrammingAI
11 Nov 2026
DEV Community

exo - splitting one model across several machines, and the rules it sets for joining

I went looking at exo (github.com/exo-explore/exo) because it answers the question I keep getting about a constrained rig: what if the memory ceiling of one machine were not the ceiling? The repository's own description reads, plainly enough: "Run frontier AI locally" - and the README states what it does in one sentence: "exo connects all your devices into an AI cluster." Not just larger models, but, with day-0 support for RDMA over Thunderbolt 5, faster as you add machines. The GitHub metadata

PythonProgrammingAI
11 Nov 2026
Medium

Stop Asking LLMs for ‘Valid JSON’ in Prompts: Schema-Constrained Outputs for Kotlin & Python

How grammar-masked decoding and kotlinx.serialization field ordering stopped parser crashes in our mobile AI features. Continue reading on Medium »

PythonAILarge language models
11 Nov 2026
Towards Data Science

“Are You Sure?” Flipped Qwen2.5-1.5B’s Right Answer 2 Times in 3

Three small open models, 150 MMLU questions each, five pushback styles: “That’s wrong” did more damage, and naming a wrong option was close to fatal. The post “Are You Sure?” Flipped Qwen2.5-1.5B’s Right Answer 2 Times in 3 appeared first on Towards Data Science.

PythonAILarge language models
11 Nov 2026
Medium

Python Automation: How to Automate Repetitive Tasks and Save Hours of Work

Python Automation: How to Automate Repetitive Tasks and Save Hours of Work Continue reading on Medium »

PythonTechnologyProgramming
5 Nov 2026
DEV Community

Why Delivered Emails Land in Spam and How to Test Inbox Placement

Your application sends a password reset. The email API returns a message ID. A delivery event arrives. The user still cannot find the message. Then someone checks the spam folder. This is where email debugging becomes confusing: several different systems have reported success, but none of those signals necessarily describes the folder the user sees. Amazon SES, for example, distinguishes acceptance of a sending request from delivery to a recipient's mail server. Neither event is an inbox placeme

PythonProgramming
5 Nov 2026
DEV Community

My first Phonon WAV, with the model and language pinned

speech.wav was the first useful result: a mono PCM file containing 44,160 samples at 24,000 Hz. That works out to 1.84 seconds of audio for “Hello from Phonon.” I generated it with Phonon's public English checkpoint on CPU. Getting that file is a more useful starting point for me than borrowing a leaderboard latency number from a different machine. Actual generated samples. The plot shows the resulting audio, not synthesis speed or a speech-quality score. Image by the author. Listen to the gene

PythonProgrammingAI
5 Nov 2026
DEV Community

Meu relatório anual travava o Trino: 144 milhões de linhas e o que mudou no script Python

Eu tinha um script em Python que gerava um relatório mensal. Ele consultava uma tabela no Trino, trazia os dados de um mês e montava o resultado. Um mês dava cerca de 12 milhões de linhas, e o script dava conta. Até que veio o pedido: o mesmo relatório, só que anual. Parecia uma mudança de uma linha: trocar o filtro de um mês para doze. Só que 12 milhões vezes 12 são cerca de 144 milhões de linhas. E o Trino travou completamente. Este artigo é sobre o que mudou no script para o relatório anual s

PythonProgramming
5 Nov 2026
DEV Community

Keep the “not” when handing off a research reading note

A quotation and an interpretation are separate things to check. Here is a small Python example for preserving a research note’s source location without pretending that a string match verifies scientific meaning. The source is Page et al.’s PRISMA 2020 statement, published in BMJ in 2021. Its scope passage says that the reporting guideline should not be used to assess review conduct or methodological quality. The same paragraph also says that familiarity with the reporting requirements is useful

PythonProgramming
5 Nov 2026
Medium

async Won't Make Your Python Code Faster (and When It Will)

I ran four small experiments to find out what async really changes, and what it doesn’t. The results are not what the hype suggests. Continue reading on Medium »

PythonProgramming
5 Nov 2026
DEV Community

The Python Reader I Measured Never Opened 34,557 Files. 310 Tests Still Needed Them.

Originally published on hexisteme notes. On 2026-10-31 I quarantined 34,557 HTML files in a content-collection system because the reader I had measured never opened them. The collection round that ran next finished complete and a re-trace passed. Then I compared the full test suite to its sealed baseline and found 310 failures beyond it. All of the files went back the same day, and that was cheap only because I had moved them instead of deleting them. The retry that came after is still in progre

PythonProgrammingDevOps
5 Nov 2026
DEV Community

Build Both UTC Boundaries Before Assigning an Event to a New York Day

AI and affiliation disclosure: An autonomous AI agent prepared and locally tested this example for TokenPeak on November 3, 2026. The event instants are synthetic fixtures. No traffic, customer record, account metric or publishing result was measured. A local calendar day does not always contain 24 elapsed hours. A report that takes a UTC start and adds 24 hours can silently omit part of a fallback day or include part of the following spring day. The following Python exercise is specifically sco

PythonProgramming
5 Nov 2026
DEV Community

I ran an AI diff reviewer on 79 real pull requests: 4 bugs maintainers fixed, all in the first 29, none in the next 50

By Spacexcx · November 2026 I built a small tool that reads a git diff and flags possible logic bugs, quoting the exact line behind each flag. Between late August and late October 2026 I ran it on 79 public pull requests and checked every flag by hand. The result is lopsided. Four flags were accepted and fixed by the authors, and all four came from 14 pull requests I picked by hand. In the next 50, which I picked with a mechanical filter, nothing survived review. This post covers what I measured

PythonProgrammingAI
4 Nov 2026
DEV Community

Postal codes are strings: test a CSV/JSON fixture round trip in Python

A postal code can look like a number without being one. If an importer converts "00123" to 123, the leading zeros have already disappeared. Converting the result back to a string does not recover them. Canadian-shaped values such as "A1A 1A1" also contain letters and a significant space. For an address form test, preserving the postal string is only half the job. The street, locality, region and postal field should stay attached to the same record. A valid-looking code independently shuffled int

PythonProgramming
4 Nov 2026
DEV Community

Python List Methods Explained with Simple Examples

Originally published on CodingCush. Python list methods are built in functions you call on a list to add, remove, find, sort or copy items without writing long code yourself. The most useful ones are append, extend and insert for adding items, remove, pop and clear for removing items, index and count for searching, sort and reverse for ordering, and copy for making a safe duplicate. In this guide, you will learn each method with a short, working example you can try right away. A list in Python i

PythonProgramming
4 Nov 2026
DEV Community

Keep missing days missing: a Python evidence table for paper dates

A research briefing that calls every recently indexed record a new paper can quietly change the selection rule. Another small error is to turn a year/month date into the first day of that month. Here is a small, offline Python example for preserving the evidence before giving metadata to an AI assistant. It uses only the standard library. It does not fetch full text, decide a systematic review's eligibility or infer a paper's first publication from a database timestamp. We are the RigorMed team.

PythonProgramming
3 Nov 2026
DEV Community

Des globules rouges fossilisés dans un os de 115 Ma — et la question que je me pose chaque fois que j'ouvre PyMOL : et si on marchait dans la poche de l'hème ?

Des globules rouges fossilisés dans un os de 115 Ma — et la question que je me pose chaque fois que j'ouvre PyMOL : et si on marchait dans la poche de l'hème ? Quand j'ai lu l'annonce de globules rouges préservés dans un os de dinosaure vieux de 115 millions d'années, je n'ai pas pensé « wow ». J'ai pensé à mon dossier heme/ sur le disque, ouvert depuis trois ans, et à la petite boîte rouge que je n'arrive jamais à bien rendre. Je m'appelle Camille, je suis développeuse dans un labo de bio-inf

PythonProgrammingScience
3 Nov 2026
DEV Community

Bi-Temporal Knowledge Graphs for AI Agents: Cutting Context Blowout by 74% in Python

Standard vector RAG (Retrieval-Augmented Generation) for AI agents suffers from two fatal flaws: Temporal Confusion: If a user changed their email address three times over 6 months, vector cosine similarity frequently retrieves the old, invalid email address. Context Window Blowout: Stuffing entire conversational transcripts into prompt context burns tens of thousands of tokens and causes catastrophic forgetting. To solve this, we engineered agent-memory-mesh — a local-first Bi-Temporal Knowledg

PythonProgrammingAI
3 Nov 2026
DEV Community

Reality Lock: Eliminating AI Agent 'Hallucination of Done' via Cryptographic Proofs in Python

In autonomous AI agent engineering, the most devastating operational failure is the Hallucination of Done. An agent cheerfully reports: "I have successfully migrated the production PostgreSQL schema and updated 4,200 user records." In reality: The database connection timed out. The Python script exited with exit code 1. Zero rows were touched. Because LLMs are probabilistic language models, they generate plausible-sounding success statements without any physical verification of operating system

PythonProgrammingAI
3 Nov 2026
DEV Community

High-Speed, Zero-Token-Waste Autonomous Browser Engine for AI Agents

When building autonomous browser agents with Playwright, Selenium, or Puppeteer, taking full-page screenshots and feeding them to vision LLMs burns over 1,500 tokens per action and takes 3 to 6 seconds per step. For multi-step web scraping, form filling, or research tasks, this creates an unsustainable Vision Token Tax. To eliminate this bottleneck, we engineered agent-browser-mesh — a high-speed, zero-token-waste autonomous browser engine for AI agents and MCP servers. Instead of sending full 4

PythonProgrammingAI
3 Nov 2026
DEV Community

Weight-Space Programming Works: An LLM Fixed Qwen's Math Loop by Editing 0.016% of Its Weights

One hundred thirty-one thousand numbers. That is the entire size of the edit that moved Qwen3.5-0.8B, a small open reasoning model, from 7.9% to 48.1% on MATH-500, from 13.8% to 67.1% on GSM8K, and from 21.0% to 62.3% on IFEval, an instruction-following benchmark. No gradient descent was involved, no training data, no fine-tuning run. A frontier model called GPT-6 Astra read the model's raw weights, identified a single direction written by two MLP layers that was trapping the model in repetition

PythonProgrammingAI
3 Nov 2026
DEV Community

Track hiring signals at any company with the Greenhouse and Lever public job APIs

Thousands of companies host their careers page on Greenhouse or Lever. Both platforms expose a public, documented, read-only API for those job boards, meant for building job sites. That makes them a clean data source for a useful question: Which companies are hiring, for which teams, and how fast is that changing? Sales teams use it as a buying signal, investors as a proxy for momentum, job seekers as an alert feed. This post shows how to get it in a few lines of Python, without scraping HTML an

PythonProgramming
3 Nov 2026
Towards Data Science

A Good Shooter or Just a Good Shot Selector? Using Python to Find Out

In basketball, field-goal percentage tells us how often a player makes a shot. But what about the shots’ difficulty? Let's use Python and machine learning to separate shot selection from shot making. The post A Good Shooter or Just a Good Shot Selector? Using Python to Find Out appeared first on Towards Data Science.

PythonAIData science
3 Nov 2026
DEV Community

A Minimal Music Player for Linux Ricing

Looking for a lightweight music player to complete your Linux rice? 🎵 I built a minimal music player with Lua, Python, and LÖVE, featuring YouTube music search, playback, and real-time audio visualization. Customize the visualizer with different colors, bar styles, spacing, and effects to match your desktop setup. It also supports Linux and has an Android version. Check it out, try it with your rice, and share your feedback! 🔗 https://github.com/HimanshuS073/music_visualizer

PythonProgrammingOpen source
3 Nov 2026
Medium

My Best Senior Engineer Stopped Fixing Everyone’s Code. Six Weeks Later, Management Wanted to Fire H

He had spent years keeping our production systems alive while other engineers collected promotions for shipping features. When he finally… Continue reading on Engineering Under Pressure »

PythonProgrammingSoftware engineering
2 Nov 2026
DEV Community

Python Event Alerts: Separating Email and SMS by Bounce Risk

Short answer: for startup event alerts, the most cost-effective choice is usually a policy, not a single API. Put routine, non-urgent notices on email, reserve SMS for events where delay has a real operational cost, and make recipient suppression a shared piece of state. The integration effort is lower when both channels emit normalized delivery events into the same Python pipeline. The important comparison is not a price table. It is how much application code you need to keep bad addresses, har

PythonProgramming
2 Nov 2026
DEV Community

Week 44 shelf-price indices: UK down 0.24%, Australia up 0.48%

I publish two weekly indices of posted online supermarket prices, one for the UK and one for Australia. Both for 2026-W44 went out on 2 November 2026. This post covers the headline moves, what the indices do not measure, and how to read the data yourself. Each week I read the online catalogues of the retailers, match products week on week by the retailer's own product id, and chain the geometric mean (a Jevons index) of the price ratios. Retailers get equal weights. There are no spending weights

PythonProgramming
2 Nov 2026
Medium

Python Finally Has a No-GIL Build. Your Code Probably Won’t Use It Yet.

Python 3.14 made the free-threaded build officially supported. Four threads can now run about 3.3–3.9x faster on CPU-bound code. But the… Continue reading on Python in Plain English »

PythonTechnologyProgramming
2 Nov 2026
Medium

I Stopped Building Basic Python Projects and Tried These 7 Instead

I used to think building more Python projects would make me a better programmer. Then I realized I was building the same things repeatedly… Continue reading on CodeToDeploy »

PythonProgrammingMachine learning
2 Nov 2026
DEV Community

Day 13/90: Define What Your AI Tools Can Accept—and What They Must Return

Day 13/90: Define What Your AI Tools Can Accept—and What They Must Return An LLM chooses a search tool and sends this: { "query": "What is our refund policy?", "limit": "a few" } The request is understandable to a person. The backend still needs an integer. Should it guess what “a few” means? Use a default? Return an error? This is where tool contracts become useful. While exploring this topic, I looked at function-calling research, JSON Schema, and the Model Context Protocol specificatio

PythonProgrammingAI
2 Nov 2026
DEV Community

How to Retry Property Report Email APIs with Python: Exponential Backoff

Short answer: retry transient email API failures with exponential backoff, start at 2 seconds, cap the delay at 32 seconds, and stop after 5 attempts. Record every failure. A retry policy improves the chance that a property report reaches its recipient without turning a temporary API problem into a burst of duplicate sends. The least complicated design is a durable report job with one send decision, one idempotency key, and a retry worker. The worker should retry transport failures and HTTP 429

PythonProgramming
1 Nov 2026
DEV Community

How to compute the real APR on a loan (derivation + 20 lines of Python)

Two loan offers land in your inbox. Both say 6.5%. One has a $1,200 origination fee, the other has none. The monthly payment on the first is not a cent higher than on the second — because the fee is taken out of the money before it reaches you. If you compare the quoted rates, the two offers look identical. They are not: on a $20,000 five-year loan the fee turns 6.5% into 9.12% APR. APR is the single number that makes those two offers comparable, and it is nothing more than an internal rate of r

PythonProgrammingFintech
1 Nov 2026
DEV Community

كيف تبني متجر واتساب إلكتروني ونظام عروض أسعار وفواتير متكامل بلغة بايثون بدون اشتراكات شهرية

في بيئة الأعمال الرقمية والتجارة الإلكترونية المعاصرة، يجد أصحاب المشاريع الصغيرة والمستقلون في العالم العربي أنفسهم محاصرين باشتراكات شهرية متراكمة (منصات المتاجر، أدوات الفواتير الإلكترونية، بوابات التوقيع الرقمي، ومزودو خدمة واتساب)، مما يبتلع جزءاً كبيراً من هوامش الربح قبل حتى تحقيق أول عملية بيع حقيقية. والأخطر من ذلك هو ارتهان بيانات العملاء وقوائم الطلبات والتقارير المالية لخوادم ومنصات وسيطة تفرض شروطها وتزيد أسعارها دورياً. في هذا الدليل الهندسي والعملي من استوديو أنتيجرافيتي (Antigrav

PythonProgrammingWeb development
1 Nov 2026
DEV Community

Self-Hosted WhatsApp E-Commerce & Automated Client Proposals in Pure Python + SQLite (Zero SaaS Fees)

Running an online store or a freelance consulting business in 2026 often feels like a slow bleed of monthly SaaS subscriptions. You pay $29/month for a basic Shopify tier, another $15/month for a proposal signing app, $20/month for an invoice generator, and another $30/month for automated WhatsApp messaging plugins. Before making your first dollar in profit, your business is saddled with over $1,000 a year in fixed recurring overhead. Worse, your customer data, order history, and client contrac

PythonProgrammingWeb development
1 Nov 2026
Medium

How I Replicated a Simplified QuickBooks Dashboard Using Python

An Introduction to building accounting dashboard with Python, Tkinter, and JSON Continue reading on Medium »

PythonFinanceProgramming
1 Nov 2026
DEV Community

Mergetober: an agent that remembers your support tickets, and forgets the deleted ones, with cognee and Zendesk

Support teams answer the same questions again and again: "have we seen this error before?", "how did we fix the double charge last month?" The answers are in old tickets and Help Center articles, but nobody has time to dig through them. For Mergetober I built a Zendesk connector for cognee, so an agent can answer from the team's own tickets and articles. Pull request: topoteretes/cognee-community#356 Issue: topoteretes/cognee#4754 Setting it up import cognee from cognee_communi

PythonProgrammingOpen source
31 Oct 2026
DEV Community

Mergetober: a CRM memory that forgets, with cognee and HubSpot

A CRM holds a lot of small facts that only make sense together: this contact works for that company, this deal needs a discount, that discount needs someone's approval. An agent that can answer "what does Northwind want, and who has to sign off?" needs all of those links, and it needs to drop them again when the CRM changes. For Mergetober I built a HubSpot connector for cognee. It syncs contacts, companies, deals, tickets and notes with the relationships between them, picks up only what changed

PythonProgrammingOpen source
31 Oct 2026
DEV Community

I built an Asana connector for cognee, and my first version got deleting wrong

My Asana connector for cognee got merged during Mergetober. It's a small package, but it taught me more about syncing data than anything I've built before. cognee turns your documents into a knowledge graph you can ask questions. My connector is a dlt source that feeds it your Asana projects. Every task becomes a document with its notes, custom fields, subtasks and comments, and each project description becomes one too. Then you can ask things like "what's blocking the website launch?" and the a

PythonProgrammingOpen source
31 Oct 2026

Related topics

ProgrammingAIOpen sourceLarge language modelsSoftware engineeringTechnologyWeb developmentDevOps

Start with the tab you have open.

Free for your first hundred saves. No card needed.

tagit

Save it, describe it, find it again. Bookmarks that work the way remembering works.

Developed in Iceland
ProductFeaturesFor AI toolsFor teamsPricingChrome extension
ResourcesBlogGuidesTopicsWhy tagsTagging guideContact
CompanyTerms of servicePrivacy policyExtension privacyRefund policy
© bla ehf.support@tagit.io