# Exception

An event during program execution that disrupts the normal flow of a program's instructions and can be handled by exception-handling code.

This is one page of public article previews, not the complete archive. Follow Next page to continue. Summaries are not the original full articles.

## Stop Using Try-Catch Everywhere: Better Exception Handling in .NET

DevFeed: [Stop Using Try-Catch Everywhere: Better Exception Handling in .NET](<https://devfeed.tech/articles/stop-using-try-catch-everywhere-better-exception-handling-in-net-146531.md>)

Original publisher: [Read original article](<https://blog.devops.dev/stop-using-try-catch-everywhere-better-exception-handling-in-net-6c33917bce3a?source=rss----33f8b2d9a328---4>)

Author: Bharat Chandera

Published: 2026-11-20T12:30:30Z

Content type: article

Language: en

Sources: [DevOps.dev](<https://devfeed.tech/sources/devops-dev.md>)

Topics: [Exception handling](<https://devfeed.tech/topics/exception-handling.md>), [Error Handling](<https://devfeed.tech/topics/error-handling.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [.NET](<https://devfeed.tech/topics/net.md>), [Custom exceptions](<https://devfeed.tech/topics/custom-exceptions.md>), [Null-Safety](<https://devfeed.tech/topics/null-safety.md>)

Tags: [asp-net](<https://devfeed.tech/tags/asp-net.md>), [asp-net-core](<https://devfeed.tech/tags/asp-net-core.md>), [aspnetcore](<https://devfeed.tech/tags/aspnetcore.md>), [best-practices](<https://devfeed.tech/tags/best-practices.md>), [business-logic](<https://devfeed.tech/tags/business-logic.md>), [clean-code](<https://devfeed.tech/tags/clean-code.md>), [csharp](<https://devfeed.tech/tags/csharp.md>), [dotnet](<https://devfeed.tech/tags/dotnet.md>), [exception](<https://devfeed.tech/tags/exception.md>), [exception-handling](<https://devfeed.tech/tags/exception-handling.md>), [middleware](<https://devfeed.tech/tags/middleware.md>), [net](<https://devfeed.tech/tags/net.md>)

### AI overview

Catching every exception and returning `BadRequest(ex.Message)` can make a .NET application harder to maintain, debug, and operate. The excerpt illustrates that APIs encounter distinct failures--database connection errors, missing records, payment timeouts, business-rule violations, and unexpected null references--but does not include the article's proposed handling approach.

### Source excerpt

Catching every exception doesn't make your application safer. Learn how to build clean, centralized, and reliable exception handling in... Continue reading on DevOps.dev "

## PHP 8.6 is out, and here's what changes for your code

DevFeed: [PHP 8.6 is out, and here's what changes for your code](<https://devfeed.tech/articles/php-8-6-is-out-and-here-s-what-changes-for-your-code-143794.md>)

Original publisher: [Read original article](<https://www.helpnetsecurity.com/2026/11/19/php-8-6-released/>)

Author: Anamarija Pogorelec

Published: 2026-11-19T15:22:36Z

Content type: release

Language: en

Sources: [Help Net Security](<https://devfeed.tech/sources/help-net-security.md>)

Topics: [Release notes](<https://devfeed.tech/topics/release-notes.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [ReactPHP](<https://devfeed.tech/topics/reactphp.md>)

Tags: [api](<https://devfeed.tech/tags/api.md>), [clamp](<https://devfeed.tech/tags/clamp.md>), [class](<https://devfeed.tech/tags/class.md>), [code](<https://devfeed.tech/tags/code.md>), [deprecated](<https://devfeed.tech/tags/deprecated.md>), [error](<https://devfeed.tech/tags/error.md>), [event-loop](<https://devfeed.tech/tags/event-loop.md>), [exception](<https://devfeed.tech/tags/exception.md>), [io](<https://devfeed.tech/tags/io.md>), [news](<https://devfeed.tech/tags/news.md>), [open-source](<https://devfeed.tech/tags/open-source.md>), [php](<https://devfeed.tech/tags/php.md>), [php-8-6](<https://devfeed.tech/tags/php-8-6.md>), [session](<https://devfeed.tech/tags/session.md>), [test](<https://devfeed.tech/tags/test.md>)

### AI overview

PHP 8.6 adds partial function application, `Time\Duration`, the `Io\Poll` polling API for event loops, and `clamp()`. It changes session defaults by enabling strict mode and HttpOnly cookies and setting SameSite to Lax; custom session handlers lacking `create_sid()` and `validateId()` are deprecated, so existing apps should test login flows before upgrading. File writes now report flush or close failures through `false`, and many invalid values raise `ValueError`; stream operations can also throw structured `StreamException`s. The release deprecates `mbstring` regex functions in favor of PCRE with `u`, several legacy type aliases, `spl_object_hash()`, and `return` in `finally`. Trimming functions now remove form feeds by default. Other additions include Sodium post-quantum key encapsulation and TLS 1.3 early data support.

### Source excerpt

PHP 8.6 has been released. The new version adds partial function application, a Time\Duration class, a polling API for event loops and a clamp() function. PHP 8.6 also changes defaults that existing apps could trip over. Sessions now start with session.use_strict_mode and session.cookie_httponly turned on and session.cookie_samesite set to Lax. Custom session handlers that don't implement both create_sid() and validateId() are deprecated. If your app relied on the old defaults, test your login flows before ... More -> The post PHP 8.6 is out, and here's what changes for your code appeared first on Help Net Security.

## NetWasm 0.10 Speeds Up C# on WebAssembly, Now Faster Than Mono AOT

DevFeed: [NetWasm 0.10 Speeds Up C# on WebAssembly, Now Faster Than Mono AOT](<https://devfeed.tech/articles/netwasm-0-10-speeds-up-c-on-webassembly-now-faster-than-mono-aot-142922.md>)

Original publisher: [Read original article](<https://www.infoq.com/news/2026/11/NetWasm-0-10-Faster/>)

Author: Edin Kapić

Published: 2026-11-19T09:00:00Z

Content type: news

Language: en

Sources: [InfoQ](<https://devfeed.tech/sources/infoq.md>)

Topics: [WebAssembly](<https://devfeed.tech/topics/web-assembly.md>), [inlining](<https://devfeed.tech/topics/inlining.md>), [vectorization techniques](<https://devfeed.tech/topics/vectorization-techniques.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [toolchain](<https://devfeed.tech/topics/toolchain.md>)

Tags: [aot](<https://devfeed.tech/tags/aot.md>), [arithmetic](<https://devfeed.tech/tags/arithmetic.md>), [benchmark](<https://devfeed.tech/tags/benchmark.md>), [benchmarks](<https://devfeed.tech/tags/benchmarks.md>), [c-sharp](<https://devfeed.tech/tags/c-sharp.md>), [compiler](<https://devfeed.tech/tags/compiler.md>), [desktop](<https://devfeed.tech/tags/desktop.md>), [development](<https://devfeed.tech/tags/development.md>), [dotnet](<https://devfeed.tech/tags/dotnet.md>), [exception-handling](<https://devfeed.tech/tags/exception-handling.md>), [faster](<https://devfeed.tech/tags/faster.md>), [mono](<https://devfeed.tech/tags/mono.md>), [net](<https://devfeed.tech/tags/net.md>), [net-11](<https://devfeed.tech/tags/net-11.md>), [netwasm-0-10-faster](<https://devfeed.tech/tags/netwasm-0-10-faster.md>), [news](<https://devfeed.tech/tags/news.md>), [simd](<https://devfeed.tech/tags/simd.md>), [wasi](<https://devfeed.tech/tags/wasi.md>), [webassembly](<https://devfeed.tech/tags/webassembly.md>)

### AI overview

NetWasm 0.10's compiler optimizations made it faster than Mono AOT on the project's benchmark set: across 2,213 cases, version 0.10.8 at O3 with NetWasmGC took 0.41 times Mono AOT's time as a geometric mean, excluding five cases where Mono's LLVM removed the work. Changes across releases 0.10.1-0.10.8 included shared exception handling, inlining and redundant bounds-check removal, 128-bit WebAssembly SIMD with scalar fallback, and reuse of division results for remainder and range checks. The excerpt reports gains on quicksort, DoomSharp, and a vectorized fluid-equation solver, while desktop .NET 11 RC3 remained faster overall at 0.87 times NetWasm's time. Results used Wasmtime 49.0.3 on one Apple M1 Max; the authors note measurement sensitivity to function alignment, slower vector performance than desktop .NET, specific slow operations, and a NewtR regression.

### Source excerpt

Summary: NetWasm, an ahead-of-time compiler from C# to WebAssembly, has reworked exception handling, bounds-check elimination, SIMD and division in its 0.10 series. Across more than 2000 benchmark cases, the project reports running in 0.41 times the time of Mono AOT's WASI build. By Edin Kapić

## Java4Shell: when base64 decoding leads to remote code execution?

DevFeed: [Java4Shell: when base64 decoding leads to remote code execution?](<https://devfeed.tech/articles/java4shell-when-base64-decoding-leads-to-remote-code-execution-144011.md>)

Original publisher: [Read original article](<https://lemire.me/blog/2026/11/18/java4shell-when-base64-decoding-leads-to-remote-code-execution/>)

Author: Daniel Lemire

Published: 2026-11-18T19:43:03Z

Content type: article

Language: en

Sources: [Daniel Lemire](<https://devfeed.tech/sources/daniel-lemire.md>)

Topics: [openjdk](<https://devfeed.tech/topics/openjdk.md>), [Decoding](<https://devfeed.tech/topics/decoding.md>), [code analysis](<https://devfeed.tech/topics/code-analysis.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [Pull Request](<https://devfeed.tech/topics/pull-request.md>)

Tags: [amd-epyc](<https://devfeed.tech/tags/amd-epyc.md>), [assembly](<https://devfeed.tech/tags/assembly.md>), [avx](<https://devfeed.tech/tags/avx.md>), [avx-512-vbmi](<https://devfeed.tech/tags/avx-512-vbmi.md>), [base64](<https://devfeed.tech/tags/base64.md>), [brave](<https://devfeed.tech/tags/brave.md>), [bug](<https://devfeed.tech/tags/bug.md>), [bun](<https://devfeed.tech/tags/bun.md>), [chrome](<https://devfeed.tech/tags/chrome.md>), [chromium](<https://devfeed.tech/tags/chromium.md>), [cve](<https://devfeed.tech/tags/cve.md>), [cve-2026-114938](<https://devfeed.tech/tags/cve-2026-114938.md>), [decoding](<https://devfeed.tech/tags/decoding.md>), [deno](<https://devfeed.tech/tags/deno.md>), [edge](<https://devfeed.tech/tags/edge.md>), [epyc](<https://devfeed.tech/tags/epyc.md>), [fast](<https://devfeed.tech/tags/fast.md>), [gold](<https://devfeed.tech/tags/gold.md>), [openjdk](<https://devfeed.tech/tags/openjdk.md>), [reading](<https://devfeed.tech/tags/reading.md>)

### AI overview

The excerpt describes CVE-2026-114938, an OpenJDK Base64 decoder bug present since JDK 17.0.6: on x86-64 with AVX-512 VBMI, decoding 128 "A" characters followed by "=" allocates 98 bytes, then a malformed tail length produces a 64-byte masked store at offset 96. Two bytes fit; 62 are written past the array before Java throws IllegalArgumentException. The author says claims of a major security vulnerability are unverified. The excerpt also contrasts Java's fast path, which stops at whitespace, with a newer SIMD decoder that compacts whitespace; it lists browser and runtime deployments and reports 30x and 39x speedups for 64 KiB MIME input on two named processors.

### Source excerpt

Let us start with an example that triggers the issue. byte[] src = ("A".repeat(128) + "=").getBytes(StandardCharsets.US_ASCII); Base64.getDecoder().decode(src); One hundred and twenty-eight letters A and one =. The string is not valid base64, and a correct decoder rejects it. OpenJDK writes past the end of the array anyway. The bug is CVE-2026-114938. It has been in ... Continue reading Java4Shell: when base64 decoding leads to remote code execution?

## Understanding Lazy thread safety modes

DevFeed: [Understanding Lazy thread safety modes](<https://devfeed.tech/articles/understanding-lazy-thread-safety-modes-116292.md>)

Original publisher: [Read original article](<https://andrewlock.net/understanding-lazy-thread-safety-modes/>)

Author: Andrew Lock

Published: 2026-11-03T10:00:00Z

Content type: article

Language: en

Sources: [Andrew Lock | .NET Escapades](<https://devfeed.tech/sources/andrew-lock-net-escapades.md>)

Topics: [thread safe data sharing](<https://devfeed.tech/topics/thread-safe-data-sharing.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [locking](<https://devfeed.tech/topics/locking.md>)

Tags: [caching](<https://devfeed.tech/tags/caching.md>), [concurrency](<https://devfeed.tech/tags/concurrency.md>), [concurrent](<https://devfeed.tech/tags/concurrent.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [lazy](<https://devfeed.tech/tags/lazy.md>), [net-core](<https://devfeed.tech/tags/net-core.md>), [thread](<https://devfeed.tech/tags/thread.md>), [thread-safety](<https://devfeed.tech/tags/thread-safety.md>)

### AI overview

`Lazy<T>` defers factory execution until `Value` is accessed. `None` is for single-threaded use and caches factory exceptions; concurrent access is unsafe. `PublicationOnly` lets concurrent callers run the factory independently, publishes the first successful result for everyone, and does not cache exceptions--each factory call that throws still reports its own exception. `ExecutionAndPublication` runs the factory once while other callers wait, and caches any exception, so later accesses keep throwing it. The article says `ExecutionAndPublication` avoids duplicate work and allocations, while `PublicationOnly` may be faster when initialization is cheap, safe to repeat, and lock contention is significant. `LazyInitializer.EnsureInitialized` offers similar publication behaviors without a `Lazy<T>` allocation and does not cache exceptions. A proposed `cacheExceptions` option was approved but was not yet implemented in the described account.

### Source excerpt

In this post I look at how the different `LazyThreadSafetyMode` values work with `Lazy`, and how exceptions are handled for each mode

## Claude Code Mods: Custom Hooks to Fix My Biggest AI Coding Frustrations

DevFeed: [Claude Code Mods: Custom Hooks to Fix My Biggest AI Coding Frustrations](<https://devfeed.tech/articles/claude-code-mods-custom-hooks-to-fix-my-biggest-ai-coding-frustrations-107782.md>)

Original publisher: [Read original article](<https://towardsdatascience.com/claude-code-mods-custom-hooks-to-fix-my-biggest-ai-coding-frustrations/>)

Author: Chien Vu Minh

Published: 2026-10-30T11:00:00Z

Content type: tutorial

Language: en

Sources: [Towards Data Science](<https://devfeed.tech/sources/towards-data-science.md>)

Topics: [Claude Code](<https://devfeed.tech/topics/claude-code.md>), [hooks](<https://devfeed.tech/topics/hooks.md>), [extend](<https://devfeed.tech/topics/extend.md>), [Test automation](<https://devfeed.tech/topics/test-automation.md>), [policy-as-code](<https://devfeed.tech/topics/policy-as-code.md>), [agentic-coding](<https://devfeed.tech/topics/agentic-coding.md>), [Vibe coding](<https://devfeed.tech/topics/vibe-coding.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [Process](<https://devfeed.tech/topics/process.md>), [To-Do](<https://devfeed.tech/topics/todo.md>), [Code review](<https://devfeed.tech/topics/code-review.md>), [codex](<https://devfeed.tech/topics/codex.md>)

Tags: [agentic-ai](<https://devfeed.tech/tags/agentic-ai.md>), [ai-coding-assistants](<https://devfeed.tech/tags/ai-coding-assistants.md>), [anthropic](<https://devfeed.tech/tags/anthropic.md>), [api](<https://devfeed.tech/tags/api.md>), [api-key](<https://devfeed.tech/tags/api-key.md>), [api-keys](<https://devfeed.tech/tags/api-keys.md>), [architecture](<https://devfeed.tech/tags/architecture.md>), [aws](<https://devfeed.tech/tags/aws.md>), [base64](<https://devfeed.tech/tags/base64.md>), [bash](<https://devfeed.tech/tags/bash.md>), [claude](<https://devfeed.tech/tags/claude.md>), [claude-code](<https://devfeed.tech/tags/claude-code.md>), [code](<https://devfeed.tech/tags/code.md>), [context](<https://devfeed.tech/tags/context.md>), [custom](<https://devfeed.tech/tags/custom.md>), [developer-productivity](<https://devfeed.tech/tags/developer-productivity.md>), [editor-s-picks](<https://devfeed.tech/tags/editor-s-picks.md>), [hooks](<https://devfeed.tech/tags/hooks.md>), [overhead](<https://devfeed.tech/tags/overhead.md>), [plan](<https://devfeed.tech/tags/plan.md>), [progress](<https://devfeed.tech/tags/progress.md>), [tests](<https://devfeed.tech/tags/tests.md>)

### AI overview

The article describes four Claude Code mods that automate repeated workflow checks: secret-guard masks recognized `.env` values and blocks some risky commands; done-gate warns when tasks are marked complete without a passing test after code changes; plan-meter displays plan progress; and context-meter shows context usage and can request compaction. In replay tests, secret-guard's value mode blocked 2 of 369 harmless calls and stopped or redacted 10 of 12 crafted leaks, while command mode blocked 157 harmless calls and stopped 7 leaks. Neither is a security boundary. A simple mod check took 0.27 ms in the test harness and a median 0.6 ms live, compared with 55-99 ms for fresh-process settings hooks on one Windows machine. The four mods passed 135 tests on Claude Code 2.1.296. Mods run with the user's permissions, are not sandboxed, and may access files or start programs through declared API calls, so the author advises reviewing those calls before installation.

### Source excerpt

How I built four Claude Code mods to protect API keys, track plan progress, catch untested code, and monitor context usage -- with 135 passing tests and up to 100x less overhead than traditional hooks -- and why they can outperform traditional hooks. The post Claude Code Mods: Custom Hooks to Fix My Biggest AI Coding Frustrations appeared first on Towards Data Science.

## Kotlin Flow: Bugs That Look Correct at First

DevFeed: [Kotlin Flow: Bugs That Look Correct at First](<https://devfeed.tech/articles/kotlin-flow-bugs-that-look-correct-at-first-105704.md>)

Original publisher: [Read original article](<https://kt.academy/article/kaustubh_flow_bugs_that_look_correct_at_first>)

Published: 2026-10-26T00:00:00Z

Content type: article

Language: en

Sources: [Kt. Academy](<https://devfeed.tech/sources/kt-academy.md>)

Topics: [coroutines-flow](<https://devfeed.tech/topics/coroutines-flow.md>), [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [bugfixes](<https://devfeed.tech/topics/bugfixes.md>), [coroutine-testing](<https://devfeed.tech/topics/coroutine-testing.md>), [Exception handling](<https://devfeed.tech/topics/exception-handling.md>), [Exception](<https://devfeed.tech/topics/exception.md>)

Tags: [android](<https://devfeed.tech/tags/android.md>), [api](<https://devfeed.tech/tags/api.md>), [apis](<https://devfeed.tech/tags/apis.md>), [buffer](<https://devfeed.tech/tags/buffer.md>), [bugs](<https://devfeed.tech/tags/bugs.md>), [cancellation](<https://devfeed.tech/tags/cancellation.md>), [capacity](<https://devfeed.tech/tags/capacity.md>), [collector](<https://devfeed.tech/tags/collector.md>), [collectors](<https://devfeed.tech/tags/collectors.md>), [concurrency](<https://devfeed.tech/tags/concurrency.md>), [coroutine](<https://devfeed.tech/tags/coroutine.md>), [coroutines](<https://devfeed.tech/tags/coroutines.md>), [database](<https://devfeed.tech/tags/database.md>), [error-handling](<https://devfeed.tech/tags/error-handling.md>), [exception](<https://devfeed.tech/tags/exception.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [execution](<https://devfeed.tech/tags/execution.md>), [flow](<https://devfeed.tech/tags/flow.md>), [workshop-learning-programming](<https://devfeed.tech/tags/workshop-learning-programming.md>)

### AI overview

The excerpt explains four Kotlin Flow pitfalls and how to address them. Collecting a cold flow separately for multiple consumers reruns its upstream work; use `shareIn()` when those consumers should share one collection, choosing a suitable scope and `SharingStarted` policy. `catch` handles failures upstream of its position, so move operations whose exceptions it should handle before `catch`; cancellation should generally propagate. `conflate()` may replace pending values with newer ones when a collector is slow, so use it only when intermediate values can be skipped; buffering can decouple producer and consumer, but a finite buffer may fill. Finally, `stateIn()` with `WhileSubscribed()` will not start upstream until there is a subscriber, so a test that only calls `runCurrent()` can still see the initial value. Use `Eagerly` for immediate collection or start a collector when testing subscription-driven behavior.

### Source excerpt

Four well-known Kotlin Flow bugs that look correct at first, why they happen, and how to fix them

## The catch That Didn't: Kotlin Flow's Channel Trap

DevFeed: [The catch That Didn't: Kotlin Flow's Channel Trap](<https://devfeed.tech/articles/the-catch-that-didn-t-kotlin-flow-s-channel-trap-99317.md>)

Original publisher: [Read original article](<https://proandroiddev.com/the-catch-that-didnt-kotlin-flow-s-channel-trap-da1bbdea80f5?source=rss----c72404660798---4>)

Author: Ehab Elwan

Published: 2026-10-25T16:37:00Z

Content type: article

Language: en

Sources: [ProAndroidDev](<https://devfeed.tech/sources/proandroiddev-medium.md>)

Topics: [coroutines-flow](<https://devfeed.tech/topics/coroutines-flow.md>), [Exception handling](<https://devfeed.tech/topics/exception-handling.md>), [Exception](<https://devfeed.tech/topics/exception.md>)

Tags: [android](<https://devfeed.tech/tags/android.md>), [android-development](<https://devfeed.tech/tags/android-development.md>), [cancellation](<https://devfeed.tech/tags/cancellation.md>), [channel](<https://devfeed.tech/tags/channel.md>), [collector](<https://devfeed.tech/tags/collector.md>), [coroutines](<https://devfeed.tech/tags/coroutines.md>), [crash](<https://devfeed.tech/tags/crash.md>), [error](<https://devfeed.tech/tags/error.md>), [fallback](<https://devfeed.tech/tags/fallback.md>), [flow](<https://devfeed.tech/tags/flow.md>), [jetpack-compose](<https://devfeed.tech/tags/jetpack-compose.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [kotlin-coroutines](<https://devfeed.tech/tags/kotlin-coroutines.md>), [kotlin-flow](<https://devfeed.tech/tags/kotlin-flow.md>), [network](<https://devfeed.tech/tags/network.md>), [operator](<https://devfeed.tech/tags/operator.md>), [queue](<https://devfeed.tech/tags/queue.md>), [screen](<https://devfeed.tech/tags/screen.md>), [skip](<https://devfeed.tech/tags/skip.md>), [source](<https://devfeed.tech/tags/source.md>), [state](<https://devfeed.tech/tags/state.md>), [tools](<https://devfeed.tech/tags/tools.md>)

### AI overview

A `catch` placed after a channel-creating Kotlin Flow operator such as `flowOn` may miss an upstream error when downstream work is suspended: the source failure cancels collection, and `catch` can interpret that cancellation as a separate downstream failure. A queued value can also be lost when the source fails before it is collected. The excerpt reports reproductions on the JVM and Android with kotlinx.coroutines 1.11.0. Its main recommendation is to handle errors before the first channel-creating operator, in the layer that owns the source, and convert expected failures to values. Wrapping only a failing call in `try`/`catch` inside the flow builder is another option; omit `flowOn` when the builder is already main-safe. If the source cannot be changed, moving suspending work into `onEach` before `catch`, or using `conflate()` or `collectLatest` when skipped values or work are acceptable, can help with specific collector patterns. These workarounds do not restore queued values already lost; `collectLatest` also has a cancellation limitation. A `CoroutineExceptionHandler` may keep the app alive but does not ensure the `catch` block handles the error.

### Source excerpt

Why a catch after flowOn can skip your fallback or crash the app, and where to put it instead.TL;DR What breaks: a catch after flowOn, or after any other operator that creates a channel, can let the source's exception skip it, which crashes the app on Android, or drop a value still in the queue before the screen gets it. Reproduced on kotlinx.coroutines 1.11.0, on the JVM and on an Android device, with the pattern the official Android guide teaches. Who is affected: a collector that suspends per value (a network call or a snackbar per update), or an early stop such as first(). A collector that only writes UI state, like stateIn's, is safe from the crash. The fix: handle errors before the first operator that creates a channel, in the layer that owns the source. Move catch before flowOn (and before stateIn or shareIn) and turn the error into a value there, or wrap the one call that can fail in try/catch inside the flow builder. If every call is already main-safe, drop flowOn. Can't move it? If your collector suspends per value, move its work into onEach before catch, or use conflate() after catch or collectLatest { } when only the latest value matters. As a last resort, wrap the terminal call in try/catch, and ask the flow's owner to move catch. None of these saves a value already in the queue. Don't rely on a CoroutineExceptionHandler: the app survives, but your catch block almost never runs. How to spot it: the crash points at your own code above a catch that should have handled it, and its trace carries a Suppressed: cancellation. The rest of the article shows the crash, why it happens, and the ways out, with the runs behind each claim. Disclosure: drafted by me and refined with AI tools, which also helped create the tests.A crash your catch was written to prevent Take a chat app that shows a notification for each new message. The observer in this example has the same shape as Wire's: it posts the notifications, then marks the messages as notified, in a scope for t

## Python Program Lexical Structure

DevFeed: [Python Program Lexical Structure](<https://devfeed.tech/articles/python-program-lexical-structure-95798.md>)

Original publisher: [Read original article](<https://realpython.com/python-program-structure/>)

Author: John Sturtz

Published: 2026-10-22T14:00:00Z

Content type: tutorial

Language: en

Sources: [Real Python](<https://devfeed.tech/sources/real-python.md>)

Topics: [Python](<https://devfeed.tech/topics/python.md>), [syntax](<https://devfeed.tech/topics/syntax.md>), [execution](<https://devfeed.tech/topics/execution.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [Variable](<https://devfeed.tech/topics/variable.md>)

Tags: [2](<https://devfeed.tech/tags/2.md>), [22](<https://devfeed.tech/tags/22.md>), [3](<https://devfeed.tech/tags/3.md>), [about](<https://devfeed.tech/tags/about.md>), [academic](<https://devfeed.tech/tags/academic.md>), [added](<https://devfeed.tech/tags/added.md>), [all](<https://devfeed.tech/tags/all.md>), [allowed](<https://devfeed.tech/tags/allowed.md>), [also](<https://devfeed.tech/tags/also.md>), [alter](<https://devfeed.tech/tags/alter.md>), [am](<https://devfeed.tech/tags/am.md>), [applications](<https://devfeed.tech/tags/applications.md>), [area](<https://devfeed.tech/tags/area.md>), [blocks](<https://devfeed.tech/tags/blocks.md>), [elements](<https://devfeed.tech/tags/elements.md>), [make](<https://devfeed.tech/tags/make.md>), [program](<https://devfeed.tech/tags/program.md>), [python](<https://devfeed.tech/tags/python.md>), [structure](<https://devfeed.tech/tags/structure.md>), [up](<https://devfeed.tech/tags/up.md>)

### AI overview

Python statements usually end at a newline, but long statements can span lines through implicit continuation inside unmatched parentheses, brackets, or braces--a PEP 8 preferred approach--or explicit continuation with a final backslash, which cannot have trailing whitespace or a comment. PEP 8 recommends keeping lines to 79 characters, discourages semicolon-separated statements, and favors readable whitespace. Hash comments run to the line's end; Python has no dedicated block-comment syntax, and PEP 8 advises against using standalone triple-quoted strings as block comments because of docstrings. Whitespace is often optional between clearly distinct tokens, but required to separate identifiers and keywords. Leading indentation is significant and determines statement grouping; unexpected indentation raises an error. In the REPL, a bare expression displays its value, while the same expression alone in a script produces no output.

### Source excerpt

Dig into the Python program structure: the syntactic elements that make up statements, and how statements group into larger blocks.

## Error handling in Elixir

DevFeed: [Error handling in Elixir](<https://devfeed.tech/articles/error-handling-in-elixir-96525.md>)

Original publisher: [Read original article](<https://www.honeybadger.io/blog/elixir-error-handling/>)

Author: Paweł Świątkowski

Published: 2026-10-22T07:00:00Z

Content type: article

Language: en

Sources: [Honeybadger](<https://devfeed.tech/sources/honeybadger.md>)

Topics: [Elixir](<https://devfeed.tech/topics/elixir.md>), [Error Handling](<https://devfeed.tech/topics/error-handling.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [bestpractice](<https://devfeed.tech/topics/bestpractice.md>)

Tags: [2](<https://devfeed.tech/tags/2.md>), [3](<https://devfeed.tech/tags/3.md>), [about](<https://devfeed.tech/tags/about.md>), [alerts](<https://devfeed.tech/tags/alerts.md>), [all](<https://devfeed.tech/tags/all.md>), [also](<https://devfeed.tech/tags/also.md>), [api](<https://devfeed.tech/tags/api.md>), [app](<https://devfeed.tech/tags/app.md>), [article](<https://devfeed.tech/tags/article.md>), [best](<https://devfeed.tech/tags/best.md>), [best-practices](<https://devfeed.tech/tags/best-practices.md>), [developer](<https://devfeed.tech/tags/developer.md>), [elixir](<https://devfeed.tech/tags/elixir.md>), [elixir-articles](<https://devfeed.tech/tags/elixir-articles.md>), [error](<https://devfeed.tech/tags/error.md>), [error-handling](<https://devfeed.tech/tags/error-handling.md>), [handling](<https://devfeed.tech/tags/handling.md>), [practices](<https://devfeed.tech/tags/practices.md>), [signal](<https://devfeed.tech/tags/signal.md>), [this](<https://devfeed.tech/tags/this.md>), [with](<https://devfeed.tech/tags/with.md>)

### AI overview

Elixir offers several ways to signal failure, and the article recommends choosing based on whether it is expected and who can act on it. Use tagged tuples such as `{:error, :not_found}` for anticipated failures; keep reasons as atoms so callers can translate them into context appropriate messages, and use structs when they provide useful detail. Exceptions generally mark programmer misuse or unexpected infrastructure failures; rescue specific exceptions when recovery or reporting is appropriate, and use `reraise` to preserve the stacktrace. Division by zero is given as a conventional exception. Exits signal process termination and are handled with `catch` or usually by supervisors; throws pass values up the stack and are discouraged unless needed. The article suggests reporting errors with Honeybadger, then re-raising or re-emitting signals when appropriate. Its closing guidance favors tuples for expected failures, built-in exceptions for misuse, custom exceptions for failures without a suitable built-in type, and catching exits or throws from Erlang libraries.

### Source excerpt

With so many ways to signal about something going wrong, an Elixir developer might sometimes feel lost. Read this article to learn when to use which signal and what are the best practices for the different kinds.

## The Phantom OOM: How a Silent Session Leak Brought Down Our Microservice Every 48 Hours

DevFeed: [The Phantom OOM: How a Silent Session Leak Brought Down Our Microservice Every 48 Hours](<https://devfeed.tech/articles/the-phantom-oom-how-a-silent-session-leak-brought-down-our-microservice-every-48-hours-93933.md>)

Original publisher: [Read original article](<https://hackernoon.com/the-phantom-oom-how-a-silent-session-leak-brought-down-our-microservice-every-48-hours?source=rss>)

Author: Himashi Meththasena

Published: 2026-10-21T20:51:24Z

Content type: tutorial

Language: en

Sources: [HackerNoon](<https://devfeed.tech/sources/hackernoon.md>)

Topics: [Cloud Native Operations](<https://devfeed.tech/topics/cloud-native-operations.md>), [database-optimization](<https://devfeed.tech/topics/database-optimization.md>), [Cloud Architecture](<https://devfeed.tech/topics/cloud-architecture.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [Tool](<https://devfeed.tech/topics/tool.md>)

Tags: [async](<https://devfeed.tech/tags/async.md>), [asynchronous](<https://devfeed.tech/tags/asynchronous.md>), [background](<https://devfeed.tech/tags/background.md>), [coding](<https://devfeed.tech/tags/coding.md>), [connection-pool](<https://devfeed.tech/tags/connection-pool.md>), [container](<https://devfeed.tech/tags/container.md>), [crash](<https://devfeed.tech/tags/crash.md>), [database](<https://devfeed.tech/tags/database.md>), [debugging](<https://devfeed.tech/tags/debugging.md>), [devops](<https://devfeed.tech/tags/devops.md>), [fastapi](<https://devfeed.tech/tags/fastapi.md>), [leak](<https://devfeed.tech/tags/leak.md>), [memory](<https://devfeed.tech/tags/memory.md>), [memory-leak](<https://devfeed.tech/tags/memory-leak.md>), [microservice-architecture](<https://devfeed.tech/tags/microservice-architecture.md>), [microservices](<https://devfeed.tech/tags/microservices.md>), [oom](<https://devfeed.tech/tags/oom.md>), [out-of-memory](<https://devfeed.tech/tags/out-of-memory.md>), [phantom-oom](<https://devfeed.tech/tags/phantom-oom.md>), [python](<https://devfeed.tech/tags/python.md>), [software-engineering](<https://devfeed.tech/tags/software-engineering.md>)

### AI overview

A FastAPI service's memory rose steadily until Kubernetes killed its pod; increasing its memory limit only lengthened the crash cycle. The team traced the pattern to long-lived or unmanaged SQLAlchemy sessions in background tasks: exception and timeout paths skipped cleanup, while PostgreSQL showed idle connections and the gap between opened and closed sessions widened. They replaced manual session handling with a context manager that commits on success, rolls back on exceptions, and always closes the session, and set engine pool size, overflow, recycling, and pre-ping options. The excerpt reports memory stabilizing at 350 MB, no OOM exits for months, and 70% fewer active database connections after deployment.

### Source excerpt

If you've ever chased a phantom memory leak in a microservice architecture, you know how frustrating it is.

## Code Smell 322 - Request Data in Long-Lived Variables (PHP Vulnerability)

DevFeed: [Code Smell 322 - Request Data in Long-Lived Variables (PHP Vulnerability)](<https://devfeed.tech/articles/code-smell-322-request-data-in-long-lived-variables-php-vulnerability-93728.md>)

Original publisher: [Read original article](<https://maximilianocontieri.com/code-smell-322-request-data-in-long-lived-variables-php-vulnerability>)

Author: Maxi Contieri

Published: 2026-10-21T20:10:02Z

Content type: article

Language: en

Sources: [Maximiliano Contieri - Software Design](<https://devfeed.tech/sources/maximiliano-contieri-software-design.md>)

Topics: [PHP](<https://devfeed.tech/topics/php.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [Test-driven development](<https://devfeed.tech/topics/tdd.md>)

Tags: [code](<https://devfeed.tech/tags/code.md>), [code-execution](<https://devfeed.tech/tags/code-execution.md>), [code-smell](<https://devfeed.tech/tags/code-smell.md>), [code-smells](<https://devfeed.tech/tags/code-smells.md>), [cve-2026-109618](<https://devfeed.tech/tags/cve-2026-109618.md>), [cve-2026-109619](<https://devfeed.tech/tags/cve-2026-109619.md>), [php](<https://devfeed.tech/tags/php.md>), [php-vulnerability](<https://devfeed.tech/tags/php-vulnerability.md>), [request](<https://devfeed.tech/tags/request.md>), [variables](<https://devfeed.tech/tags/variables.md>), [vulnerability](<https://devfeed.tech/tags/vulnerability.md>)

### AI overview

Long-lived PHP worker state can retain a pointer to request-owned memory after the request ends; a later request may consume it before initialization, creating a use-after-free risk. Fatal errors, timeouts, memory exhaustion, or late diagnostic writes can bypass or undo normal resets, so the defect depends on both a stale-state write and a later read. The text recommends request-scoped ownership or explicit cleanup on every exit path, initialization before early consumers, blocking late updates, and consecutive-request tests that exercise failures, with tools such as AddressSanitizer, Valgrind, static analysis, and allocation-failure injection. It distinguishes this runtime-internals vulnerability from ordinary PHP globals, which do not automatically reproduce the CVE. The combined PHP patch resets vulnerable state and changes out-of-memory bailout handling; the article names PHP 8.5.12, 8.4.27, 8.3.36, and 8.2.35 as fixed releases. Confirmed exposure depends on SAPI, configuration, and affected state: it cites a demonstrated Apache mod_php path and documented PHP-FPM paths under specific conditions.

### Source excerpt

Your request is gone. Your pointer is not.

## JEP targeted to JDK 28: 543: Structured Concurrency

DevFeed: [JEP targeted to JDK 28: 543: Structured Concurrency](<https://devfeed.tech/articles/jep-targeted-to-jdk-28-543-structured-concurrency-92514.md>)

Original publisher: [Read original article](<https://inside.java/2026/10/21/jep543-target-jdk28/>)

Author: Viktor Klang

Published: 2026-10-21T00:00:00Z

Content type: release

Language: en

Sources: [Inside Java](<https://devfeed.tech/sources/inside-java.md>)

Topics: [Structured concurrency](<https://devfeed.tech/topics/structured-concurrency.md>), [Concurrency](<https://devfeed.tech/topics/concurrency.md>), [Exception handling](<https://devfeed.tech/topics/exception-handling.md>), [openjdk](<https://devfeed.tech/topics/openjdk.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [async](<https://devfeed.tech/topics/async.md>), [Erlang](<https://devfeed.tech/topics/erlang.md>)

Tags: [concurrency](<https://devfeed.tech/tags/concurrency.md>), [jdk](<https://devfeed.tech/tags/jdk.md>), [jdk-28](<https://devfeed.tech/tags/jdk-28.md>), [jep](<https://devfeed.tech/tags/jep.md>), [project-loom](<https://devfeed.tech/tags/project-loom.md>), [structured-concurrency](<https://devfeed.tech/tags/structured-concurrency.md>)

### AI overview

JEP 543 proposes finalizing Structured Concurrency in JDK 28 without further API changes. `StructuredTaskScope` groups related subtasks in a lexical scope: the owner forks them, joins them as a unit, and closes the scope, which cancels remaining subtasks and waits for them to terminate. The default policy fails when a subtask fails and cancels unfinished siblings; interruption of the owner also propagates cancellation. `Joiner` options support other completion policies, including returning the first successful result or collecting all successful results. Thread dumps can show scopes and their subtasks as a hierarchy. Cancellation depends on subtasks responding to interruption; uninterruptible work can delay scope closure indefinitely. The API is intended to complement, not replace, `ExecutorService` and `Future`, and is described as a preview through JDK 27.

### Source excerpt

The following JEP is targeted to JDK 28: 543: Structured Concurrency

## Part 2: Kotlin Flows -- Mastering Operators (Valves, Filters, and T-Joints)

DevFeed: [Part 2: Kotlin Flows -- Mastering Operators (Valves, Filters, and T-Joints)](<https://devfeed.tech/articles/part-2-kotlin-flows-mastering-operators-valves-filters-and-t-joints-91136.md>)

Original publisher: [Read original article](<https://proandroiddev.com/part-2-kotlin-flows-mastering-operators-valves-filters-and-t-joints-f9d7a8ebd64c?source=rss----c72404660798---4>)

Author: Sandeep Kella

Published: 2026-10-20T16:42:42Z

Content type: article

Language: en

Sources: [ProAndroidDev](<https://devfeed.tech/sources/proandroiddev-medium.md>)

Topics: [coroutines-flow](<https://devfeed.tech/topics/coroutines-flow.md>), [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [Exception handling](<https://devfeed.tech/topics/exception-handling.md>), [Exception](<https://devfeed.tech/topics/exception.md>)

Tags: [android](<https://devfeed.tech/tags/android.md>), [collect](<https://devfeed.tech/tags/collect.md>), [data](<https://devfeed.tech/tags/data.md>), [exception](<https://devfeed.tech/tags/exception.md>), [fallback](<https://devfeed.tech/tags/fallback.md>), [filter](<https://devfeed.tech/tags/filter.md>), [flow](<https://devfeed.tech/tags/flow.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [map](<https://devfeed.tech/tags/map.md>), [network](<https://devfeed.tech/tags/network.md>), [ui](<https://devfeed.tech/tags/ui.md>)

### AI overview

Kotlin Flow operators transform, filter, and handle errors as items travel through a flow: `filter` keeps matching values, `map` converts each value, and `catch` can emit a fallback for upstream exceptions. Operators return wrapped flows; intermediate operators do not start execution, while terminal operators such as `collect` do. The article recommends keeping filtering and formatting outside UI collection code. It contrasts Flow's sequential per-item processing with List operators that create a new list in memory. Its interview examples note that `catch` does not handle errors thrown downstream in `collect`, and compare search strategies: `flatMapConcat` runs sequentially, `flatMapMerge` concurrently with potentially out-of-order results, and `flatMapLatest` cancels outdated work.

### Source excerpt

Hey again! In Part 1, we built our Air Compressor (the Flow) and pulled the trigger on our Spray Gun (the .collect() function) to start the air moving. But let's be real--if you just blast raw air straight out of a compressor, you're going to get moisture, dirt, and uneven pressure. To do a professional paint job, you need attachments on your hose. In Kotlin Flows, these attachments are called Operators. They intercept the data while it's traveling down the pipe, changing it before it ever reaches the UI (the spray gun). The Breakdown: Valves and Filters Let's look at the three most common attachments you'll put on your hose: 1. The Moisture Trap (filter) Sometimes the compressor spits out water droplets along with the air. You don't want water ruining your paint job. The filter operator acts like a screen--it only lets things pass if they meet a certain condition. // Only emit air bursts that are perfectly dry airFlow.filter { air -> air.isDry == true } 2. The Paint Mixer (map) Right now, you just have raw air. But you want blue paint. The map operator intercepts the raw air, mixes blue paint into it, and sends it further down the line. It literally transforms the data type from A to B. // Transforms RawAir into BluePaint airFlow.map { rawAir -> Paint(color = "Blue", pressure = rawAir.pressure) } 3. The Safety Release Valve (catch) What happens if the compressor explodes or a pipe bursts? In code, this is an Exception (like a network crash). If you don't have a safety valve, the explosion travels all the way to the spray gun and breaks it (your app crashes). The catch operator safely handles the explosion. airFlow .catch { exception -> println("Whoops! Pipe burst: $exception") emit(BackupAir()) // We can even emit a fallback value! } Diagrammatic Mental Model: [Compressor] ---> ( filter: keep dry ) ---> ( map: add paint ) ---> ( catch: safety ) ---> [Spray Gun] raw air dry air blue paint safe paint UI updatesUnder the Hood: What happens internally? Operators in Flow

## Finally The Official Way of Secure DataStore is Here!

DevFeed: [Finally The Official Way of Secure DataStore is Here!](<https://devfeed.tech/articles/finally-the-official-way-of-secure-datastore-is-here-91132.md>)

Original publisher: [Read original article](<https://proandroiddev.com/finally-the-official-way-of-secure-datastore-is-here-ae878f5eb457?source=rss----c72404660798---4>)

Author: Burak Karaduman

Published: 2026-10-20T16:18:09Z

Content type: tutorial

Language: en

Sources: [ProAndroidDev](<https://devfeed.tech/sources/proandroiddev-medium.md>)

Topics: [Cryptography](<https://devfeed.tech/topics/cryptography.md>), [Android Security](<https://devfeed.tech/topics/android-security.md>), [Secure token management](<https://devfeed.tech/topics/secure-token-management.md>), [Jetpack](<https://devfeed.tech/topics/jetpack.md>), [coroutines-flow](<https://devfeed.tech/topics/coroutines-flow.md>), [Coroutines](<https://devfeed.tech/topics/coroutines.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [Test-driven development](<https://devfeed.tech/topics/tdd.md>)

Tags: [android](<https://devfeed.tech/tags/android.md>), [android-app-development](<https://devfeed.tech/tags/android-app-development.md>), [backup](<https://devfeed.tech/tags/backup.md>), [coroutines](<https://devfeed.tech/tags/coroutines.md>), [data](<https://devfeed.tech/tags/data.md>), [encryption](<https://devfeed.tech/tags/encryption.md>), [error-handling](<https://devfeed.tech/tags/error-handling.md>), [flow](<https://devfeed.tech/tags/flow.md>), [jetpack-datastore](<https://devfeed.tech/tags/jetpack-datastore.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [mobile-app-security](<https://devfeed.tech/tags/mobile-app-security.md>)

### AI overview

The excerpt shows how `androidx.datastore:datastore-tink` can encrypt a typed DataStore through an `AeadSerializer` backed by Tink and an Android Keystore master key, replacing custom AES/GCM storage code. It explains that encryption protects copied files but not data read by the app itself. Decryption or deserialization failures become DataStore corruption; a handler can reset a session, while irreplaceable data needs another recovery plan. Because Android backups can restore the encrypted file and keyset without the device-bound master key, the excerpt advises excluding both from cloud and device-transfer backups. It also outlines migration from legacy encrypted preferences and notes that the library is alpha, key rotation is manual, and migration was unit-tested but not tested on an install retaining real legacy data.

### Source excerpt

Securing data has always been a concern since the early days of app development. Platforms do their best to protect user data, but there are always edge cases. Attackers may still reach sensitive data, even in encrypted form, and if they get the key, the protection is meaningless. So yes, encryption helps, but it is not magic. On Android we started with SharedPreferences. It was simple, widely used, and even had built in encryption through EncryptedSharedPreferences. Then Kotlin Flow and Coroutines arrived, apps reached a global audience, and codebases grew. We now needed async operations, thread safety, type safety, custom objects, proper error handling and reactive streams. SharedPreferences was not designed for that, and DataStore was introduced to solve it. But Google deprecated the Jetpack Security (security-crypto) library, and DataStore had no built in encryption, so most of us wrote our own. Now there is androidx.datastore:datastore-tink, added in DataStore 1.3.0-alpha07. In this post we build a small encrypted session store: a login screen that saves an email and a token, and a home screen that reads them. We also show what happens when decryption fails. The full sample project (with Hilt) is on GitHub: burkido/official-datastore-encryption-sample What encryption protects, and what it does not Encrypting a file protects it when someone gets the file but not your app, for example from a rooted phone, a raw copy of the device storage or a copied backup. It does not protect against code inside your own app, because that code can simply read the decrypted value from DataStore. Encryption is one layer of security. It is not the whole solution.How we did it before Our old setup was similar to the one in this article. A security class created an AES/GCM key in the Android Keystore and managed the IV manually: fun encryptData(keyAlias: String, text: String): Pair<ByteArray, ByteArray> { val secretKey = generateSecretKey(keyAlias) cipher.init(Cipher.ENCRYPT_MODE, se

## Why do we need ud2 when int 6 is right there?

DevFeed: [Why do we need ud2 when int 6 is right there?](<https://devfeed.tech/articles/why-do-we-need-ud2-when-int-6-is-right-there-90671.md>)

Original publisher: [Read original article](<https://devblogs.microsoft.com/oldnewthing/20261019-00/?p=112781/>)

Author: Raymond Chen

Published: 2026-10-19T14:00:00Z

Content type: article

Language: en

Sources: [Raymond Chen](<https://devfeed.tech/sources/raymond-chen.md>)

Topics: [Exception](<https://devfeed.tech/topics/exception.md>), [Kernel](<https://devfeed.tech/topics/kernel.md>)

Tags: [code](<https://devfeed.tech/tags/code.md>), [exception](<https://devfeed.tech/tags/exception.md>), [invalid-opcode](<https://devfeed.tech/tags/invalid-opcode.md>), [kernel](<https://devfeed.tech/tags/kernel.md>), [old-new-thing](<https://devfeed.tech/tags/old-new-thing.md>), [operating-system](<https://devfeed.tech/tags/operating-system.md>), [software](<https://devfeed.tech/tags/software.md>)

### AI overview

The article explains why the x86 `ud2` instruction cannot be replaced by an explicit `int 6` to trigger an invalid-opcode fault. A fault reports the address of the faulting instruction, while a trap reports the address of the following instruction, which can confuse the operating system's exception handler. User-mode programs also lack permission to invoke `int 6` directly.

### Source excerpt

An interrupt is not a fault. The post Why do we need <CODE>ud2</CODE> when <CODE>int 6</CODE> is right there? appeared first on The Old New Thing.

## EveryThing You Need To Know About Scala

DevFeed: [EveryThing You Need To Know About Scala](<https://devfeed.tech/articles/everything-you-need-to-know-about-scala-65415.md>)

Original publisher: [Read original article](<https://blog.devops.dev/everything-you-need-to-know-about-scala-c833fe885c44?source=rss----33f8b2d9a328---4>)

Author: Rahul Patidar

Published: 2026-10-06T13:04:28Z

Content type: article

Language: en

Sources: [DevOps.dev](<https://devfeed.tech/sources/devops-dev.md>)

Topics: [Scala](<https://devfeed.tech/topics/scala.md>), [Functional programming](<https://devfeed.tech/topics/functional-programming.md>), [class](<https://devfeed.tech/topics/class.md>), [Closure](<https://devfeed.tech/topics/closure.md>), [constructor](<https://devfeed.tech/topics/constructor.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [Learning](<https://devfeed.tech/topics/learning.md>), [superclass](<https://devfeed.tech/topics/superclass.md>)

Tags: [app](<https://devfeed.tech/tags/app.md>), [block](<https://devfeed.tech/tags/block.md>), [class](<https://devfeed.tech/tags/class.md>), [classes](<https://devfeed.tech/tags/classes.md>), [closure](<https://devfeed.tech/tags/closure.md>), [design-patterns](<https://devfeed.tech/tags/design-patterns.md>), [exception](<https://devfeed.tech/tags/exception.md>), [exception-handling](<https://devfeed.tech/tags/exception-handling.md>), [factory](<https://devfeed.tech/tags/factory.md>), [frameworks](<https://devfeed.tech/tags/frameworks.md>), [function](<https://devfeed.tech/tags/function.md>), [functions](<https://devfeed.tech/tags/functions.md>), [monad](<https://devfeed.tech/tags/monad.md>), [none](<https://devfeed.tech/tags/none.md>), [nothing](<https://devfeed.tech/tags/nothing.md>), [null](<https://devfeed.tech/tags/null.md>), [packages](<https://devfeed.tech/tags/packages.md>), [recursion](<https://devfeed.tech/tags/recursion.md>), [scala](<https://devfeed.tech/tags/scala.md>), [syntax](<https://devfeed.tech/tags/syntax.md>)

### AI overview

The excerpt presents Scala interview topics through short explanations and code examples. It describes factory, singleton, and lazy initialization patterns; treating functions as values and higher-order functions; tail recursion, closures, placeholder syntax, partially applied functions, currying, purity, and anonymous functions. It also covers trait linearization in the diamond problem, monads, case class features, primary and auxiliary constructors, named Scala frameworks, exception handling without checked exceptions, BitSet, the App helper, package names, and Null, Nil, None, and Nothing. The supplied text ends mid-example in the factory pattern and is therefore an excerpt rather than evidence of the complete article.

### Source excerpt

Everyone who is a beginner in scala faces many problems and has many confusions while trying to understand important concepts in scala. In interviews, interviewers frequently ask about these concepts in Scala, and candidates are frequently unable to impress or explain these concepts to interviewers. So in today's post, I will be covering some important concepts in Scala, so whenever you go for your next interview, just read these concepts once and it will really help you to answer Scala Related Interview Questions. This post will cover the following topics: 1. Scala Design Patterns 2. First Class function 3. Higher-Order Functions 4. Tail Recursion in Scala. 5. Block of Code. 6. Closure 7. PlaceHolder Syntax: 8. Partially Applied Function: 9. Function Currying : 10. pure functions : 11. Anonymous Function: 12. Diamond Problem In scala: 13. traint in scala: 14. Monad in scala: 15. Case Classes In Scala. 16. constructors in Scala 17. Frameworks supported by Scala 18. Exception Handling in Scala 19. BitSet 20. app Class 21. Packages in Scala 22. Null, Nill, None, and Nothing in Scala Scala Design Patterns. Every time you develop some software, there are some common problems that everyone faces in his/her software engineering journey. To resolve these issues, we have some predefined general-purpose reusable solutions. These reusable solutions are nothing but design patterns. These are the types of templates that we can use as a solution whenever we encounter these issues. We have 3 kinds of design patterns in Scala. The factory design pattern: the main aim of the factory design pattern is to separate instance creation logic from the client. Here we implement instance creation logic in the factory class without exposing this logic to the client. It is used when we have multiple subclasses with one superclass and, based on the input, we need to return one of the inputs. Example trait Computer { def ram: String def hdd: String def cpu: String } case class PC(ram: String, h

## Measuring the Performance of Deterministic Exceptions

DevFeed: [Measuring the Performance of Deterministic Exceptions](<https://devfeed.tech/articles/measuring-the-performance-of-deterministic-exceptions-61685.md>)

Original publisher: [Read original article](<https://databasearchitects.blogspot.com/2026/09/measuring-performance-of-deterministic.html>)

Author: Thomas Neumann (noreply@blogger.com)

Published: 2026-09-29T14:30:15Z

Content type: article

Language: en

Sources: [Database Architects](<https://devfeed.tech/sources/database-architects.md>)

Topics: [Exception](<https://devfeed.tech/topics/exception.md>), [performance-optimization](<https://devfeed.tech/topics/performance-optimization.md>)

Tags: [c-plus-plus](<https://devfeed.tech/tags/c-plus-plus.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [performance](<https://devfeed.tech/tags/performance.md>), [state](<https://devfeed.tech/tags/state.md>)

### AI overview

The article prototypes C++ P0709 deterministic exceptions with help from an LLM, then compares pointer, carry-bit, register, and classic exception implementations. In microbenchmarks, the register and carry approaches are nearly identical; register is described as more portable, while the prototype remains limited to the Itanium ABI and is not production ready.

### Source excerpt

I have always been interested in Zero-Overhead Deterministic Exceptions from P0709, as they promised a nicer implementation model and they are much easier to integrate into JIT-compiled code. Some people forbid regular C++ exceptions, due to code size and performance concerns, which are concerns that P0709 explicitly wants to address. Unfortunately, there was no implementation available. But now, with LLMs, doing this kind of experiment is much more tractable. I basically gave the official P0709 specification to an LLM, and it built a first prototype in one shot. Admittedly my initial enthusiasm cooled down a bit after I found a lot of problems and corner cases, but after about one day of work I was able to build a reasonable prototype, which is something that would easily have taken me weeks or even months in the past. I tested it with complex code, and it handled everything fine, but note that it is still not production ready (e.g., Itanium ABI only). That prototype now allows us to quantify the differences between exception implementations. P0709 describes two ways to implement them: Either pass a hidden pointer to an error state to all functions that are marked with throws (we call this strategy pointer here), or use the carry bit to indicate errors and pass the error itself in registers if the bit is set (we call this strategy carry). That is a very nifty approach suggested by Herb Sutter, but it somewhat clashes with some of the function epilogues (e.g., on Windows), and such a flag is not available on all platforms. We thus introduced a third variant register here that simply uses another unused caller-saved register as an error indicator, which is more portable. The classic C++ exception handling mechanism we call dynamic. Microbenchmarks We first run some microbenchmarks to see the overall effects. These over-emphasize the differences as the benchmarks basically do nothing besides function calls (ns per outer call): Test failures dynamic pointer register ca

## Why is the x86 undefined instruction called ud2?

DevFeed: [Why is the x86 undefined instruction called ud2?](<https://devfeed.tech/articles/why-is-the-x86-undefined-instruction-called-ud2-61204.md>)

Original publisher: [Read original article](<https://blog.adafruit.com/2026/09/28/why-is-the-x86-undefined-instruction-called-ud2/>)

Author: Anne Barela

Published: 2026-09-28T20:32:34Z

Content type: article

Language: en

Sources: [Adafruit Industries](<https://devfeed.tech/sources/adafruit-industries-makers-hackers-artists-designers-and-engineers.md>)

Topics: [x86](<https://devfeed.tech/topics/x86.md>), [undefined\_behavior](<https://devfeed.tech/topics/undefined-behavior.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [Compilers and Linkers](<https://devfeed.tech/topics/compilers-and-linkers.md>)

Tags: [compiler](<https://devfeed.tech/tags/compiler.md>), [compilers](<https://devfeed.tech/tags/compilers.md>), [exception](<https://devfeed.tech/tags/exception.md>), [invalid-opcode](<https://devfeed.tech/tags/invalid-opcode.md>), [old-new-thing](<https://devfeed.tech/tags/old-new-thing.md>), [software](<https://devfeed.tech/tags/software.md>), [vintage-computing](<https://devfeed.tech/tags/vintage-computing.md>), [x86](<https://devfeed.tech/tags/x86.md>)

### AI overview

Raymond Chen explains the history and behavior of the x86 ud2 instruction. Compilers use it to mark unreachable code and ensure that an unexpected return from a [[noreturn]] function causes an invalid opcode exception. Earlier faulting byte sequences were less reliable because some encoded unused operands could cause an access violation when decoding crossed into an unmapped page.

### Source excerpt

Raymond Chen, writing at The Old New Thing, explains the history behind the x86 instruction ud2. It is an architecturally undefined instruction that always raises an invalid opcode exception. Compilers emit it to mark unreachable code. If a function marked [[noreturn]] somehow returns, the compiler puts a ud2 after the call so the program crashes [...]

## The Java Compiler That Became Its Own Test Case

DevFeed: [The Java Compiler That Became Its Own Test Case](<https://devfeed.tech/articles/the-java-compiler-that-became-its-own-test-case-59175.md>)

Original publisher: [Read original article](<https://www.codenameone.com/blog/parparvm-compiles-itself/>)

Author: Shai Almog

Published: 2026-09-24T00:00:00Z

Content type: article

Language: en

Sources: [CodeName One](<https://devfeed.tech/sources/codename-one.md>)

Topics: [Compiler](<https://devfeed.tech/topics/compiler.md>), [Java](<https://devfeed.tech/topics/java.md>), [Code](<https://devfeed.tech/topics/code.md>), [C](<https://devfeed.tech/topics/c.md>), [Collections](<https://devfeed.tech/topics/collections.md>), [Exception](<https://devfeed.tech/topics/exception.md>)

Tags: [c](<https://devfeed.tech/tags/c.md>), [code](<https://devfeed.tech/tags/code.md>), [collections](<https://devfeed.tech/tags/collections.md>), [compiler](<https://devfeed.tech/tags/compiler.md>), [exception](<https://devfeed.tech/tags/exception.md>), [java](<https://devfeed.tech/tags/java.md>)

### AI overview

ParparVM, a Java-to-C translator, is now self-hosting and can compile its own translator into a native executable. The process exposes runtime and reproducibility issues, including differences from JVM output, invalid C labels, and unstable declaration ordering.

### Source excerpt

Self-hosting turns ParparVM into a demanding test of its own runtime and generated output.

## Comparing exception behavior of magic statics, std::call\_once, and std::async

DevFeed: [Comparing exception behavior of magic statics, std::call\_once, and std::async](<https://devfeed.tech/articles/comparing-exception-behavior-of-magic-statics-std-call-once-and-std-async-57641.md>)

Original publisher: [Read original article](<https://devblogs.microsoft.com/oldnewthing/20260918-00/?p=112709>)

Author: Raymond Chen

Published: 2026-09-18T14:00:00Z

Content type: article

Language: en

Sources: [Raymond Chen](<https://devfeed.tech/sources/raymond-chen.md>)

Topics: [Exception](<https://devfeed.tech/topics/exception.md>), [async](<https://devfeed.tech/topics/async.md>), [Code](<https://devfeed.tech/topics/code.md>)

Tags: [async](<https://devfeed.tech/tags/async.md>), [code](<https://devfeed.tech/tags/code.md>), [exception](<https://devfeed.tech/tags/exception.md>), [old-new-thing](<https://devfeed.tech/tags/old-new-thing.md>)

### AI overview

The article compares how C++ magic statics, std::call_once, and std::async handle exceptions during initialization or execution. It explains which mechanisms retry after failure and which preserve and rethrow the exception.

### Source excerpt

Do you try again or give up? The post Comparing exception behavior of magic statics, <CODE>std::<WBR>call_<WBR>once</CODE>, and <CODE>std::<WBR>async</CODE> appeared first on The Old New Thing.

## std::call\_once vs. std::async

DevFeed: [std::call\_once vs. std::async](<https://devfeed.tech/articles/std-call-once-vs-std-async-42168.md>)

Original publisher: [Read original article](<https://devblogs.microsoft.com/oldnewthing/20260917-00/?p=112706>)

Author: Raymond Chen

Published: 2026-09-17T14:00:00Z

Content type: article

Language: en

Sources: [Raymond Chen](<https://devfeed.tech/sources/raymond-chen.md>)

Topics: [async](<https://devfeed.tech/topics/async.md>), [C++](<https://devfeed.tech/topics/c-plus-plus.md>), [implementation](<https://devfeed.tech/topics/implementation.md>), [undefined\_behavior](<https://devfeed.tech/topics/undefined-behavior.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [execution](<https://devfeed.tech/topics/execution.md>), [Compiler](<https://devfeed.tech/topics/compiler.md>)

Tags: [async](<https://devfeed.tech/tags/async.md>), [c-plus-plus](<https://devfeed.tech/tags/c-plus-plus.md>), [code](<https://devfeed.tech/tags/code.md>), [compiler](<https://devfeed.tech/tags/compiler.md>), [exception](<https://devfeed.tech/tags/exception.md>), [execution](<https://devfeed.tech/tags/execution.md>), [implementation](<https://devfeed.tech/tags/implementation.md>), [old-new-thing](<https://devfeed.tech/tags/old-new-thing.md>), [undefined-behavior](<https://devfeed.tech/tags/undefined-behavior.md>)

### AI overview

This article compares std::call_once with std::async for deferred execution in C++. It discusses retrieving cached results, repeated calls, thread safety, memory allocation, supported execution modes, and exception behavior, with additional commentary on implementation defects and data races in an older GCC implementation.

### Source excerpt

Simple vs complex machinery. The post <CODE>std::call_once</CODE> vs. <CODE>std::async</CODE> appeared first on The Old New Thing.

## Gson Deserialization and the InaccessibleObjectException

DevFeed: [Gson Deserialization and the InaccessibleObjectException](<https://devfeed.tech/articles/gson-deserialization-and-the-inaccessibleobjectexception-26583.md>)

Original publisher: [Read original article](<https://www.baeldung.com/java-gson-deserialization-inaccessibleobjectexception>)

Author: Marcin Buczkowski

Published: 2026-09-15T05:32:46Z

Content type: tutorial

Language: en

Sources: [Baeldung](<https://devfeed.tech/sources/baeldung.md>)

Topics: [Exception](<https://devfeed.tech/topics/exception.md>), [JSON](<https://devfeed.tech/topics/json.md>), [Tutorial](<https://devfeed.tech/topics/tutorial.md>), [Java](<https://devfeed.tech/topics/java.md>)

Tags: [exception](<https://devfeed.tech/tags/exception.md>), [gson](<https://devfeed.tech/tags/gson.md>), [how-to](<https://devfeed.tech/tags/how-to.md>), [java](<https://devfeed.tech/tags/java.md>), [json](<https://devfeed.tech/tags/json.md>), [json-gson](<https://devfeed.tech/tags/json-gson.md>), [tutorial](<https://devfeed.tech/tags/tutorial.md>)

### AI overview

This tutorial explains how Java's strong encapsulation and the Java Platform Module System can cause InaccessibleObjectException when Gson deserializes JSON through reflection. It focuses on modular projects, date handling, and Gson's maintenance status.

### Source excerpt

Learn how to resolve an InaccessibleObjectException when working with Gson and modern Java versions. The post Gson Deserialization and the InaccessibleObjectException first appeared on Baeldung.

## Resolving Exception: Cannot Deserialize From Object Value (No Delegate- Or Property-Based Creator)

DevFeed: [Resolving Exception: Cannot Deserialize From Object Value (No Delegate- Or Property-Based Creator)](<https://devfeed.tech/articles/resolving-exception-cannot-deserialize-from-object-value-no-delegate-or-property-based-creator-17378.md>)

Original publisher: [Read original article](<https://www.baeldung.com/java-jackson-fix-no-creator-exception>)

Author: Martin Blažević

Published: 2026-09-14T04:21:09Z

Content type: tutorial

Language: en

Sources: [Baeldung](<https://devfeed.tech/sources/baeldung.md>)

Topics: [Jackson](<https://devfeed.tech/topics/jackson.md>), [LocalDate](<https://devfeed.tech/topics/localdate.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [JSON](<https://devfeed.tech/topics/json.md>)

Tags: [article](<https://devfeed.tech/tags/article.md>), [exception](<https://devfeed.tech/tags/exception.md>), [how-to](<https://devfeed.tech/tags/how-to.md>), [jackson](<https://devfeed.tech/tags/jackson.md>), [jackson-exception](<https://devfeed.tech/tags/jackson-exception.md>), [java](<https://devfeed.tech/tags/java.md>), [json](<https://devfeed.tech/tags/json.md>), [library](<https://devfeed.tech/tags/library.md>), [tutorial](<https://devfeed.tech/tags/tutorial.md>)

### AI overview

This tutorial explains why Jackson can throw InvalidDefinitionException when it cannot determine how to construct an object during JSON deserialization. It demonstrates the problem with an immutable class and presents solutions including a no-argument constructor, property-based creators using @JsonCreator and @JsonProperty, and annotated factory methods. It also notes the correct annotation package for Jackson 3.x.

### Source excerpt

During JSON deserialization, Jackson may throw an InvalidDefinitionException when it can't determine how to create an instance of the target class. In this article, you'll learn how to fix this in Jackson 2.x and 3.x. The post Resolving Exception: Cannot Deserialize From Object Value (No Delegate- Or Property-Based Creator) first appeared on Baeldung.

[Next page](<https://devfeed.tech/topics/exception.md?cursor=WyIyMDI2LTA5LTE0VDA0OjIxOjA5KzAwOjAwIiwgImRmYWUwNzU5LTI2YTQtNDdiMS04MmIzLWYzNWRmNjI0MjRlMCJd>)