SShortSingh.
0
IndiaTimes of India ·

India's Manufacturing PMI Hits Five-Year Low at 52.8 in August

India's manufacturing sector recorded its slowest growth in five years during August, with the Purchasing Managers' Index (PMI) falling to 52.8. Both production output and new orders declined during the month, pushing activity to its weakest level since August 2021. The slowdown also triggered a contraction in factory employment for the first time in two and a half years. Overseas demand weakened overall, despite a marginal uptick in purchasing activity. Business confidence improved slightly but stayed below long-term historical averages.

0
IndiaNDTV ·

Child's Preference Not Sole Factor in Custody Decisions, Rules High Court

A High Court has ruled that a child's preference for one parent cannot be the sole determining factor in custody cases. The court delivered this judgment while deciding a custody dispute between two parents. Custody of the child was ultimately retained with the mother following the ruling. The court also put in place structured visitation rights to ensure the father maintained access to the child. The decision underscores that multiple factors, not just the child's stated preference, must guide custody determinations.

0
ProgrammingDEV Community ·

How Well-Written Pull Requests Make Code Review Faster and More Effective

A poorly documented pull request with a blank description, a vague title, and 600 lines of unexplained changes once slipped past review and crashed a production checkout flow. The incident highlights how PRs are often treated as bureaucratic checkboxes rather than collaborative conversations, undermining their core purpose. A pull request is a formal request to merge code changes into a main branch, but its real value lies in the social layer — the discussion, decisions, and context it preserves for future developers. Experts recommend that PR titles clearly state the change in imperative form, while descriptions should answer why the change was made, what it includes, and how to test it. Following these practices can significantly reduce review turnaround time and improve overall code quality across engineering teams.

0
ProgrammingDEV Community ·

Why Smart Contract Token Approvals Are Transactions, Not Toggles

Token approvals on ERC-20 contracts are stored on-chain as allowance entries, not app-level settings, meaning any system relying on them must treat that on-chain record as the sole source of truth. Revoking an approval is itself a full blockchain transaction that must be signed, broadcast, and confirmed — it is not instant and can be delayed by network congestion. Services that cache approval states locally risk acting on stale data, either attempting to spend tokens already revoked or blocking valid spends when a revocation is still unconfirmed. The safest engineering practice is to read the allowance directly from the chain immediately before executing any token transfer, rather than relying on a database record. This approach adds RPC latency and infrastructure load but prevents a class of bugs where a system's internal state diverges from what the token contract will actually permit.

0
ProgrammingDEV Community ·

Attackers Can Silently Disable AWS CloudTrail Logging With a Single API Call

Security researchers warn that an attacker who gains access to an AWS account can halt audit logging with a single command — aws cloudtrail stop-logging — leaving the trail's configuration visually intact while new events stop being recorded. The technique, catalogued under MITRE ATT&CK as T1562.008, is well-documented in Mandiant incident reports and AWS security guidance. Because standard inspection commands like describe-trails and GetTrail do not reveal the logging state, only get-trail-status exposes the critical IsLogging: false flag. Inside this blind window, attackers can exfiltrate secrets, create persistent backdoor IAM users, and rotate KMS keys to prevent decryption of existing log archives — all without generating a CloudTrail record. Security teams are advised not to treat 'trail configured' as equivalent to 'trail running,' and to actively monitor the logging status field rather than relying solely on static configuration audits.

0
ProgrammingDEV Community ·

Silent calendar bug corrupted five years of Korean astrology charts, tests missed it

A developer building a Korean saju (BaZi) astrology service discovered that a third-party calendar library was returning the same solar term timestamp for every year, regardless of the year passed as input. The bug meant that birth charts for anyone born on or near a solar term boundary between 2020 and 2030 — except 2026 — may have been calculated incorrectly, sometimes by as much as twelve hours. The flaw went undetected for five years because the test suite's expected values had been derived from the same faulty library, making the tests confirm the library's output rather than astronomical reality. A secondary issue compounded the problem: all test probes had been chosen on the same side of the real boundary, so they would have passed even against an independent correct dataset. The developer has since replaced the dependency with verified astronomical data and redesigned the tests to assert that different years must produce distinct solar term instants.

0
ProgrammingDEV Community ·

Developer Runs 48-Hour AI Prompt Regression Test, Finds Output Consistency Unreliable

A developer discovered that a free AI model returned three different action plans for the same prompt within one hour, each delivered with equal confidence, prompting a structured reliability test. To assess consistency, they froze a battery of 11 prompts and ran each three times every six hours over 48 hours, recording all raw outputs without adjusting anything mid-run. A diversity ratio metric was used to score output stability, where a perfect repeat scored 0.33 and fully inconsistent outputs scored 1.0. Contrary to expectations, short prompts initially appeared stable but then abruptly changed key names, while long prompts showed high variability from the very first run. The most problematic finding was not semantic drift but "serialization drift" — the same JSON prompt returning raw JSON, fenced code blocks, or preamble-wrapped text across different runs, breaking parsers silently.

0
ProgrammingDEV Community ·

How to diagnose and fix blurry or shimmering sprites in Godot 4 pixel art

Blurry pixel-art sprites in Godot 4 can stem from several distinct issues, including texture filtering, fractional movement, camera interpolation, or sprite-sheet bleeding — and misidentifying the cause wastes debugging time. A reliable first step is to pause the character and camera to determine whether the blur appears at rest or only during motion, as each points to a different root cause. Setting the Sprite2D or AnimatedSprite2D texture filter to Nearest prevents pixel blending, while ensuring positions and scales remain whole integers keeps pixel art crisp during movement. Developers should also verify that sprite-sheet geometry matches slicer settings, that animation frames share a consistent canvas size and foot baseline, and that physics updates and render interpolation are not working against each other. Godot's official documentation on jitter, stutter, and input lag offers additional guidance for separating rendering artifacts from movement-related problems.

0
ProgrammingDEV Community ·

Branch-Level Refactor Workflow Offers Safer Way to Modernize Legacy Code

A software development workflow described on DEV Community proposes refactoring legacy codebases one conditional branch at a time, rather than one line at a time, to reduce the risk of shipping hidden bugs. The approach begins by generating characterization tests that record the existing behavior of a function — including side effects — into a JSON snapshot before any changes are made. This snapshot acts as a behavioral contract, ensuring that each subsequent refactor can be verified against the original output. The method is demonstrated using a messy Python function with three independent conditional branches and a global side effect list. The author notes the workflow is compatible with AI-assisted tools for branch discovery but does not require them.

0
ProgrammingDEV Community ·

Understanding React useEffect: Synchronization, Dependencies, and Cleanup Explained

React's useEffect hook is designed to synchronize a component with external systems such as network connections, timers, WebSockets, and third-party libraries. It runs after React commits changes to the DOM, and its behavior is controlled by a dependency array that determines when re-synchronization is needed. React compares dependency values using Object.is, and any reactive value read inside the effect should be listed as a dependency to avoid subtle bugs. When a dependency changes, React first runs the previous effect's cleanup function before executing the new setup, ensuring external systems stay in sync. Misunderstanding these mechanics — such as omitting dependencies or suppressing lint warnings — can lead to stale data, infinite loops, or unexpected re-renders.

0
ProgrammingDEV Community ·

Developer builds retro Windows 95-style portfolio using Next.js 15 and Framer Motion

A developer has created a personal portfolio website styled after the classic Windows 95 operating system, standing out from conventional portfolio designs. The site features a teal desktop background, draggable and resizable windows, clickable icons, and a retro boot animation that plays on page load. It was built using Next.js 15 with App Router, Tailwind CSS for styling, Framer Motion for animations, and TypeScript for type safety. The portfolio includes sections for projects, writing, and a functional contact form, and is deployed on Vercel. Despite its rich animations, the site reportedly achieves a perfect score of 100 on Google Lighthouse's SEO audit.

0
ProgrammingDEV Community ·

Dev shares hard lessons from deploying LLM features in production

A developer writing for DEV Community recounts building an AI-powered support ticket classifier for a client, only to face a series of failures after moving from demo to production. Issues included malformed model outputs crashing the backend and the LLM inventing non-existent priority categories, highlighting how non-deterministic AI outputs break standard software assumptions. The author resolved output reliability by separating model inference from structured data extraction, letting deterministic code enforce schemas rather than relying on prompts alone. Context window overflows in production led to a shift toward vector database retrieval, cutting token costs by 60% and improving response quality. The key takeaway is that production AI integration demands the same engineering rigour as any data system — including validation layers, context management infrastructure, and quality monitoring beyond standard HTTP error tracking.

0
TechnologyThe Verge ·

Tim Cook steps down as Apple CEO after 15 years, John Ternus takes over

Tim Cook is stepping down as Apple's CEO after 15 years in the role, with hardware chief John Ternus named as his successor. Cook took over in 2011 from co-founder Steve Jobs, inheriting a company already riding high on the success of the Mac, iPod, and iPhone. During his tenure, Cook oversaw the launch of numerous new products, services, and features that became central to Apple's identity. His 15-year run included notable highs and lows, but he is widely credited with cementing Apple's status as one of the world's most valuable companies.

← NewerPage 749 of 4209Older →