SShortSingh.

Programming

0
ProgrammingDEV Community ·

Why Redis Beats Node.js and Standard DBs for Building a Rate Limiter

A developer built a rate limiter from scratch after failing an Amazon online assessment that included a rate-limiting question, using the experience to explore why common approaches fall short. Node.js, despite being single-threaded, is asynchronous, meaning two simultaneous requests can bypass in-memory rate limits due to event-loop race conditions at await boundaries. Standard databases like MongoDB or SQL face similar issues through stale reads under MVCC concurrency models, unless expensive row-level locks are applied. Popular packages such as express-rate-limit suffer from a 'boundary burst' flaw, where a fixed-window reset allows up to double the intended request limit within a very short span. Redis addresses these problems using a ZSET data structure that combines a hash map and skip list, enabling O(1) lookups and O(log N) range queries without the costly memory-shift operations of array-based approaches.

0
ProgrammingDEV Community ·

Why crypto payment systems should treat every amount string as hostile input

A developer with production experience building crypto payment systems since 2018 argues that most precision-related bugs stem from skipping representability checks and leaving rounding behavior implicit. The core problem is that when an amount string with too many decimal places enters a system, it is often silently truncated to fit a database column rather than flagged or explicitly rounded. This creates reconciliation drift that surfaces much later and cannot be easily attributed to a source. The author advocates declaring rounding policy explicitly at each call site before any computation occurs, rather than relying on whatever a database column or arithmetic operation happens to produce. To enforce this, they built a parsing library called cryptomoney that refuses float inputs, rejects amounts finer than the asset allows, and requires developers to explicitly name a rounding mode when precision loss is acceptable.

0
ProgrammingDEV Community ·

Fine-Tuning vs Context Engineering: How Enterprises Are Deploying Small AI Models

As of late 2026, enterprises are increasingly shifting from large cloud-based AI APIs to Small Language Models (SLMs) ranging from 1 to 9 billion parameters, driven by concerns over latency, cost, and data governance. Teams deploying SLMs face a core architectural choice between fine-tuning a model's internal weights for domain-specific tasks or using context engineering to optimize how information is fed to a general model at runtime. Context engineering approaches risk performance degradation as large token loads cause attention decay and slower response times in smaller models. Fine-tuning, while powerful for specialized tasks, carries its own risks including catastrophic forgetting, loss of general capabilities, and significant data preparation overhead. Advances in Parameter-Efficient Fine-Tuning and model distillation have made custom SLM training more accessible, but selecting the wrong deployment strategy can have immediate operational and financial consequences.

0
ProgrammingDEV Community ·

Claude Code's /skill-doctor reveals hidden token costs from unused AI skills

Claude Code version 2.1.252 introduced a new diagnostic command called /skill-doctor, which audits loaded skills by reporting their context token cost and usage frequency. A developer running the tool on their codebase found 40 skills consuming roughly 3,060 tokens per turn, with 16 never-used skills from a memory plugin alone accounting for nearly half that cost. The report flagged only 3 skills as unused, missing the 16 costliest idle ones because they belonged to an actively used plugin. One flagged skill was intentionally dormant, kept in place to handle a future system state change, illustrating that the tool's recommendations require human judgment rather than blind application. The findings highlight a broader issue: plugin installations silently inflate context size on every turn, regardless of whether Claude actually invokes those skills.

0
ProgrammingDEV Community ·

How Pre-Authorized 'Standing Orders' Help On-Call Engineers Act Without Waiting for Bosses

Standing orders are written, pre-authorized decision frameworks that define what an on-call engineer can do independently when key decision-makers are unreachable. Borrowed from the military concept of commander's intent, the framework organizes actions into tiers ranging from act-alone decisions to those requiring escalation, paired with spending and impact caps. Without such guidelines, teams risk costly delays, as illustrated by a nine-person payments team whose on-call engineer waited 40 minutes for CTO approval during a duplicate-charges incident, resulting in 212 customers double-charged instead of an estimated 60. After implementing standing orders, a similar incident was resolved in 4 minutes with only 19 customers affected. The framework also includes communication commitments, expiry dates, and regular review triggers to prevent outdated or misused authority.

0
ProgrammingHacker News ·

Blog Post Highlights Notable Innovations in Programming Language Design

A blog post published at prydt.xyz explores what the author considers standout ideas in programming language design. The piece was shared on Hacker News, where it received 9 points at the time of reporting. The article aims to identify and discuss concepts that have meaningfully advanced how programming languages are built or used. No comments had been posted on the Hacker News thread at the time of publication.

0
ProgrammingDEV Community ·

FlipImage Flips Photos Entirely in Your Browser Without Uploading Them

FlipImage is a browser-based tool that performs horizontal and vertical image flips locally, meaning image data never leaves the user's device or reaches a server. Processing is handled via the browser's Canvas API, and users can verify this by checking the Network panel in DevTools, where no image upload requests appear. The tool supports common formats including JPEG, PNG, WebP, BMP, and GIF, though animated GIFs are exported as static PNGs and files exceeding 30 MB are rejected upfront. Transparency is preserved when exporting as PNG, while JPEG inputs are re-encoded at 0.92 quality, so the downloaded file extension may differ from the original. Free downloads include a watermark, which can be removed with a one-time payment of $6.90.

0
ProgrammingDEV Community ·

Why Round-Robin Load Balancing Fails WebSocket Connections at Scale

Round-robin load balancing, while effective for stateless HTTP traffic, is poorly suited for WebSocket connections because it distributes handshakes rather than ongoing connection load. Since WebSocket connections are persistent and can remain open for hours, round-robin routing gradually concentrates active connections on a small number of backend nodes, creating dangerous hotspots. These overloaded nodes can buckle under memory and CPU pressure, triggering cascading failures across the system. Switching to a least-connections routing strategy — where new handshakes are directed to the least-burdened server — helps distribute load more evenly. Additional pitfalls include using IP-based sticky sessions, which can pin thousands of users sharing a single IP to one node, and default idle timeouts that silently drop live WebSocket connections.

0
ProgrammingDEV Community ·

GitHub Actions Outage on Aug 26 Delayed Workflows and Blocked PR Merges

GitHub experienced a service incident on August 26, 2026, between approximately 21:55 UTC and 23:58 UTC, affecting Actions workflows triggered by pull request events. At peak disruption, up to 25% of workflow runs faced delayed starts exceeding five minutes, while 4% failed to trigger at all. The root cause was traced to background jobs timing out while accessing a single git data partition, creating a backlog that cascaded into broader pull request processing failures. GitHub engineers resolved the issue by reducing workload, rerouting traffic away from affected infrastructure, and restoring the impacted service component. The incident highlighted the operational risks CI/CD dependencies pose to release schedules and prompted GitHub to commit to improved resource saturation detection and stronger backpressure mechanisms.

0
ProgrammingDEV Community ·

GitHub Billing Outage Blocked Developer Workflows for Over 60 Hours

GitHub declared a billing service disruption on August 26, 2025, affecting users' ability to load billing pages and maintain active Copilot sessions. The incident was resolved by August 27 after the platform applied staged mitigations to restore Copilot access and fix billing page failures. However, one enterprise user managing over 140 projects reported that billing issues had begun earlier on August 23, stemming from a failed card payment that resulted in a duplicate invoice and an inactive Copilot account. Despite raising 6–7 support tickets and sending multiple emails over 60 hours, the user received only automated responses and no human intervention, leading to missed client deadlines and reported financial losses. The case highlights concerns about the adequacy of automated customer support systems when critical developer tools are disrupted for paying enterprise customers.

0
ProgrammingDEV Community ·

Classic Quotes from Dijkstra, Knuth and Kernighan Still Define the AI Coding Debate

A DEV Community piece argues that foundational warnings from computing pioneers like Edsger Dijkstra, Donald Knuth, and Brian Kernighan anticipated today's debates around AI-generated code with striking accuracy. Dijkstra's 1972 Turing Award lecture cautioned against clever tricks and overconfidence — concerns that map directly onto risks of accepting unreviewed LLM output. Kernighan's observation that debugging is twice as hard as writing code takes on new weight when developers accept generated code they do not fully understand. Knuth's reminder that even formally proved code can still contain bugs underscores why the confident tone of AI output deserves healthy scepticism. The article contends that questions around trust, readability, and code quality are not new problems introduced by AI, but old ones now appearing in a different form.

0
ProgrammingDEV Community ·

Developer builds system-design lab that validates architecture against real Docker infra

A developer has created Torollo, a local system-design lab that backs visual architecture diagrams with real Docker containers and networks on the user's machine. Unlike traditional diagram tools, Torollo's validator checks the actual running environment rather than the appearance of the diagram. For example, if an exercise requires PostgreSQL to be isolated from a load balancer, the tool tests the real network connection and fails the step if the port remains accessible. The project uses React, React Flow, and TypeScript on the frontend, with a Node.js and Dockerode backend maintaining a strict separation between what the canvas depicts and what can be observed at runtime. The developer also built a diagnostic CLI command to help users identify environment-specific issues, such as limitations in rootless Docker setups that affect advanced networking behavior.

0
ProgrammingDEV Community ·

Anthropic's Claude Code CLI Cuts Developer Feature Time by Up to 75%, Review Finds

A developer with extensive experience across AI coding tools including GitHub Copilot, Cursor, and ChatGPT has published a detailed review of Anthropic's Claude Code, a command-line interface tool. Unlike conventional AI coding assistants that work within a single file, Claude Code reads an entire codebase and makes coordinated edits across multiple files simultaneously. The reviewer reports that feature development time dropped from 4–6 hours to 1–2 hours, with one example seeing an 8-file lead capture system built in roughly 15 minutes. The tool also demonstrated strong debugging capabilities, tracing a production webpack failure caused by a circular dependency in under two minutes. The reviewer notes limitations with large codebases and visual design tasks, but overall considers it a meaningful shift in how AI assists real development work.

0
ProgrammingDEV Community ·

Android's AI Ambitions Outpace Stable APIs, Developer Warns

A developer who spent 18 months building on Android's agentic APIs argues that Google's vision of an 'intelligent operating system' bundles three distinct engineering challenges — model runtime, app integration, and agent distribution — into a single marketing narrative. Google's own posts claim Gemini can already complete task automation on Android without user input, but the developer contends the shipping code lags well behind those assertions. The distribution layer, which determines which AI assistant gets privileged access to the user, is identified as the least trustworthy claim and the one receiving the least scrutiny. Android 17 will introduce Android Halo, a status-bar slot intended to surface any agent's activity, though the developer notes a UI slot is not the same as equal API access. On July 16, 2026, the European Commission ordered Alphabet under the Digital Markets Act to grant third-party AI assistants the same Android capabilities — including hotword detection, on-device context, and system actions — that Google extends to Gemini.

0
ProgrammingDEV Community ·

Green Login Tests Can Miss SQL Injection Risks, Developer Experiment Shows

A software developer demonstrated that standard login behavior tests can pass even when SQL queries are built unsafely using f-strings, leaving applications vulnerable to SQL injection. The experiment compared two login implementations — one embedding user input directly into the SQL string and another using parameterized placeholders — both of which passed identical response-based tests. A separate 'parameterization contract test' using a fake database object was introduced to inspect exactly what SQL and parameters reached the cursor.execute call. The unsafe f-string implementation failed this contract test, as user values were embedded in the query string with no parameter tuple, while the parameterized version passed cleanly. The developer concluded that behavior tests and parameterization contract tests cover different boundaries and both are necessary for robust security coverage.

0
ProgrammingDEV Community ·

AI Now Screens Both Sides of Job Interviews, But Only Employers Hold the Power

Automated tools have screened job applicants for years through keyword filters and recorded-interview scoring, well before candidates began using AI chatbots for application help. A CESifo working paper studying over 3,000 real applicants found that asynchronous AI-scored interviews led to a more than 50% drop in application completion, with the steepest declines among women and highly qualified candidates. Experts argue this creates a structural power imbalance: while a candidate using AI to prepare affects only themselves, an employer using AI to score makes consequential decisions about people without transparency or right of appeal. Some jurisdictions are beginning to regulate this gap — the EU AI Act classifies candidate-evaluation systems as high-risk, Illinois mandates consent before AI analyses video interviews, and New York City requires published bias audits for automated hiring tools. Until broader rules exist, candidates are advised to ask employers directly what is recorded and analysed, as the nature of that response itself signals something about the organisation.

0
ProgrammingDEV Community ·

Lazygit's Four Merge Options Explained: How Each Shapes Your Git History

Lazygit's 'M' key in the branches panel opens a menu with four distinct merge options, each producing a different commit graph in Git history. The default 'm' option fast-forwards when possible, leaving a linear history with no merge marker, but falls back to a merge commit if the target branch has moved. The 'n' option always creates a merge commit with two parents, permanently marking where a branch was integrated. Squash merge options ('s' and 'S') condense all source branch commits into one, either leaving it uncommitted or committing it immediately. A developer documented these differences by building a throwaway repository and testing each option individually, using 'git log --oneline --graph' to observe the resulting history shape.

0
ProgrammingDEV Community ·

Developer Builds Real-Time 3D Digital Twin of Pune Using IDM/MOBIL Traffic Engine

A developer has created Pune Pulse, a real-time 3D digital twin of Pune, India, that renders 95,666 real buildings and accurate road geometry. The app uses the Intelligent Driver Model (IDM) and MOBIL lane-change algorithm to simulate realistic vehicle behaviour rather than scripted paths. A key feature is a what-if tool that lets users close any road and observe how traffic redistributes across the city. Built with React 19, React Three Fiber, and three.js, the web app is packaged for Android via Capacitor and is available on the Google Play Store. The simulation runs entirely offline with no API calls, no GPS usage, and no location tracking.

0
ProgrammingDEV Community ·

QBEACON API lets anyone run and verify a tamper-proof giveaway draw

A tool called QBEACON offers a cryptographically verifiable way to run online giveaways, addressing common accusations of rigging. Organizers first submit their entrant list via an API, which hashes and locks it before any random value is generated. The winner is then determined by a publicly published randomness beacon — a 4,096-bit, Ed25519-signed value chained to previous outputs and released roughly every 2.5 minutes — ensuring no one, including the organizer, can influence the outcome. A signed certificate and a public verification page are generated for each draw, allowing anyone to audit the result without an API key. The service is available on RapidAPI with a free tier supporting up to 10 draws per month for lists of up to 100 entrants.

← NewerPage 1418 of 3336Older →