# exceptions

Published articles for exceptions.

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

## CodeSOD: Asynchronous Directories

DevFeed: [CodeSOD: Asynchronous Directories](<https://devfeed.tech/articles/codesod-asynchronous-directories-28505.md>)

Original publisher: [Read original article](<https://thedailywtf.com/articles/asynchronous-directories>)

Author: Remy Porter

Published: 2026-09-09T06:30:00Z

Content type: article

Language: en

Sources: [The Daily WTF](<https://devfeed.tech/sources/the-daily-wtf.md>)

Topics: [Vala](<https://devfeed.tech/topics/vala.md>), [async/await](<https://devfeed.tech/topics/async-await.md>), [Library](<https://devfeed.tech/topics/library.md>), [Programming](<https://devfeed.tech/topics/programming.md>)

Tags: [async](<https://devfeed.tech/tags/async.md>), [asynchronous](<https://devfeed.tech/tags/asynchronous.md>), [await](<https://devfeed.tech/tags/await.md>), [codesod](<https://devfeed.tech/tags/codesod.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [filesystem](<https://devfeed.tech/tags/filesystem.md>), [writing-code](<https://devfeed.tech/tags/writing-code.md>)

### AI overview

This article examines implementing an asynchronous version of Vala's directory-creation method when the core library provides only a synchronous version. The proposed function walks up the directory tree, then creates missing directories in reverse order, using exceptions for control flow.

### Source excerpt

Eri has a mix of a "true confession" and a "wait, really?" today. The programming language Vala bills itself as a C# like language that compiles into something pretty close to C performance, designed specifically for writing code against Gnome and its associated libraries. One of the C#-isms in brings in is async/await type semantics. You can yield someAsyncFunction(), which returns control to the caller, allowing it to proceed until the yielded function returns an actual value. Because it has asynchronous functions, many library functions for handling I/O are already async. So you can make_directory_async, which yields control so you can keep executing while waiting for the filesystem to make your directory. There are also synchronous versions of those methods. And then there's create_directory_with_parents, which will create a chain of directories for you. That's the synchronous version, and Vala's core library has decided not to provide an asynchronous version of it, which is my "wait, really?" I suspect it's really about the race conditions involved and the risks of things going wrong while doing it asynchronously; all solvable problems, but tricky ones to solve. But it's the problem Eri had, and this is their solution: /// Note: does not throw if target already exists async void create_directory_with_parents_async(File file, Cancellable? cancellable = null) throws Error { var to_create = new File[0]; var? current_target = file; while(current_target != null) { try { yield current_target.make_directory_async(Priority.DEFAULT, cancellable); } catch(IOError.NOT_FOUND e) { to_create += current_target; current_target = current_target.get_parent(); continue; } catch(IOError.EXISTS e) { break; } break; } for (int i = to_create.length - 1; i >= 0; --i) { try { yield to_create[i].make_directory_async(Priority.DEFAULT, cancellable); } catch(IOError.EXISTS e) { // Created by another process } } } If I'm reading this correctly, we start by trying to create the full path to

## Standardizing Exception Message Style in Ruby

DevFeed: [Standardizing Exception Message Style in Ruby](<https://devfeed.tech/articles/standardizing-exception-message-style-in-ruby-20535.md>)

Original publisher: [Read original article](<https://code.dblock.org/2026/09/05/standardizing-exception-message-style-in-ruby.html>)

Author: Daniel Doubrovkine (dblock@dblock.org)

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

Content type: article

Language: en

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

Topics: [Ruby](<https://devfeed.tech/topics/ruby.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [ci](<https://devfeed.tech/topics/ci.md>)

Tags: [ci](<https://devfeed.tech/tags/ci.md>), [exception](<https://devfeed.tech/tags/exception.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [grape](<https://devfeed.tech/tags/grape.md>), [lint](<https://devfeed.tech/tags/lint.md>), [open-source](<https://devfeed.tech/tags/open-source.md>), [plugin](<https://devfeed.tech/tags/plugin.md>), [ruby](<https://devfeed.tech/tags/ruby.md>), [standard](<https://devfeed.tech/tags/standard.md>)

### AI overview

The article explains a convention for Ruby exception messages: they should generally begin with lowercase and omit trailing punctuation because they follow the exception class name and a colon. It describes fixing seven inconsistent sites in Grape, documenting the convention, and releasing the rubocop-exception_messages RuboCop plugin to enforce casing and punctuation, with additional checks for redundant class names and interpolation markers.

### Source excerpt

While reviewing dozens of PRs from ericproulx optimizing Grape's internals recently, I noticed that the bare raise ArgumentError, "..." calls scattered across the codebase were inconsistent: some messages were capitalized, some ended in a period, most were not. Longtime readers know where this is going. Ruby's own core and standard library exceptions don't do this - TypeError: no implicit conversion from nil to integer, ArgumentError: wrong number of arguments, and so on all read lowercase and unpunctuated, because the message is meant to be read after the exception class name and a colon, not as a standalone sentence. Grape's own Grape::Exceptions::* classes already follow this convention. The bare raise ArgumentError, "..." calls in dsl/entity.rb, dsl/inside_route.rb, dsl/validations.rb, and validations/types/dry_type_coercer.rb didn't, so I fixed those seven sites and documented the convention in CONTRIBUTING.md, in #2909. To avoid regressions, I wrote rubocop-exception_messages, a RuboCop plugin gem with two cops: ExceptionMessages/Casing flags (and autocorrects) messages that don't start with a lowercase letter. ExceptionMessages/Punctuation flags (and autocorrects) messages with a trailing period, with an exception for a literal ellipsis ("still processing.."), which is stylistic rather than a sentence ending. Both cops recognize raise Class, "message" and raise Class.new("message") forms, and handle interpolated (dstr) messages by only checking the literal string segments (the first segment for casing, the last for punctuation), since interpolated values in the middle are out of the cop's control. # bad raise ArgumentError, 'Missing required option.' # good raise ArgumentError, 'missing required option' The gem ships as a modern RuboCop plugin (via lint_roller), so it's a one-line addition to a consuming project's .rubocop.yml: plugins: - rubocop-exception_messages rubocop-exception_messages 0.2.0 is out now, and I've added it back to Grape's own Gemfile and

## Clean Architecture: Use Cases Should NOT Catch Stripe Exceptions

DevFeed: [Clean Architecture: Use Cases Should NOT Catch Stripe Exceptions](<https://devfeed.tech/articles/clean-architecture-use-cases-should-not-catch-stripe-exceptions-26181.md>)

Original publisher: [Read original article](<https://journal.optivem.com/p/clean-architecture-use-cases-should-not-catch-stripe-exceptions>)

Author: Valentina Jemuović

Published: 2026-08-27T06:01:02Z

Content type: tutorial

Language: en

Sources: [Optivem Journal](<https://devfeed.tech/sources/optivem-journal.md>)

Topics: [Error Handling](<https://devfeed.tech/topics/error-handling.md>), [stripe](<https://devfeed.tech/topics/stripe.md>)

Tags: [architecture](<https://devfeed.tech/tags/architecture.md>), [error-handling](<https://devfeed.tech/tags/error-handling.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [stripe](<https://devfeed.tech/tags/stripe.md>)

### AI overview

The article addresses error handling in the application layer and argues that Clean Architecture use cases should not catch Stripe exceptions.

### Source excerpt

Error Handling - Application layer

## jetc.dev Newsletter Issue #328

DevFeed: [jetc.dev Newsletter Issue #328](<https://devfeed.tech/articles/jetc-dev-newsletter-issue-328-22960.md>)

Original publisher: [Read original article](<https://jetc.dev/issues/328.html>)

Author: CommonsWare

Published: 2026-08-25T14:00:00Z

Content type: article

Language: en

Sources: [jetc.dev | Issues](<https://devfeed.tech/sources/jetc-dev-issues.md>)

Topics: [Jetpack Compose](<https://devfeed.tech/topics/jetpack-compose.md>), [modules](<https://devfeed.tech/topics/modules.md>), [API](<https://devfeed.tech/topics/api.md>)

Tags: [api](<https://devfeed.tech/tags/api.md>), [batching](<https://devfeed.tech/tags/batching.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [images](<https://devfeed.tech/tags/images.md>), [jetpack-compose](<https://devfeed.tech/tags/jetpack-compose.md>), [modules](<https://devfeed.tech/tags/modules.md>), [newsletter](<https://devfeed.tech/tags/newsletter.md>), [published](<https://devfeed.tech/tags/published.md>), [videos](<https://devfeed.tech/tags/videos.md>)

### AI overview

Newsletter Issue #328 covers Jetpack Compose development topics, including API modules and composables, lazy-container lifecycle exceptions, recomposition and state-change batching, and selecting and copying text from images and videos.

### Source excerpt

API modules and composables! LazyColumn() exceptions! 'Select and copy text' for images and videos!

## How to Handle Global Errors in Modern Zoneless Angular

DevFeed: [How to Handle Global Errors in Modern Zoneless Angular](<https://devfeed.tech/articles/how-to-handle-global-errors-in-modern-zoneless-angular-37468.md>)

Original publisher: [Read original article](<https://www.angularspace.com/how-to-handle-global-errors-in-modern-zoneless-angular/>)

Author: Jaroslaw Zolnowski

Published: 2026-08-04T11:51:30Z

Content type: tutorial

Language: en

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

Topics: [Angular](<https://devfeed.tech/topics/angular.md>), [Error Handling](<https://devfeed.tech/topics/error-handling.md>), [Web Development](<https://devfeed.tech/topics/web-development.md>)

Tags: [angular](<https://devfeed.tech/tags/angular.md>), [async](<https://devfeed.tech/tags/async.md>), [errors](<https://devfeed.tech/tags/errors.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [how-to](<https://devfeed.tech/tags/how-to.md>), [modern](<https://devfeed.tech/tags/modern.md>), [user-experience](<https://devfeed.tech/tags/user-experience.md>), [web-development](<https://devfeed.tech/tags/web-development.md>)

### AI overview

This tutorial explains why global error handling changes when Angular applications move from Zone.js to a zoneless model. It introduces provideBrowserGlobalErrorListeners as an Angular v20 tool for handling errors that occur outside Angular's direct control, including unhandled Promise rejections and third-party scripts.

### Source excerpt

In the world of web development, unhandled errors are silent threats. They can degrade user experience, cause unpredictable application behavior, and leave developers in the dark. For years, Angular's error handling has benefited from a bit of "magic"

## GC and Exceptions in Wasmtime

DevFeed: [GC and Exceptions in Wasmtime](<https://devfeed.tech/articles/gc-and-exceptions-in-wasmtime-15142.md>)

Original publisher: [Read original article](<https://bytecodealliance.org/articles/wasmtime-gc>)

Author: Nick Fitzgerald

Published: 2026-07-20T00:00:00Z

Content type: release

Language: en

Sources: [Bytecode Alliance](<https://devfeed.tech/sources/bytecode-alliance.md>)

Topics: [WebAssembly](<https://devfeed.tech/topics/web-assembly.md>), [wasm](<https://devfeed.tech/topics/wasm.md>), [Exception](<https://devfeed.tech/topics/exception.md>), [toolchains](<https://devfeed.tech/topics/toolchains.md>)

Tags: [compilation](<https://devfeed.tech/tags/compilation.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [release](<https://devfeed.tech/tags/release.md>), [toolchains](<https://devfeed.tech/tags/toolchains.md>), [wasm](<https://devfeed.tech/tags/wasm.md>), [webassembly](<https://devfeed.tech/tags/webassembly.md>)

### AI overview

Wasmtime 47 enables the Wasm GC and exceptions proposals by default. The article explains how Wasm GC supports languages with object-and-reference data models by letting the runtime manage types and lifetimes, while the exceptions proposal provides more efficient exception handling for WebAssembly compilation targets.

### Source excerpt

The Wasm GC and exceptions proposals are both enabled by default in today's Wasmtime 47 release! We are excited to help bring more languages to WebAssembly and everywhere that Wasmtime runs. Getting to this point involved large Wasmtime changes and represents the culmination of years of engineering effort.

## Wastrel Compiles Hoot Scheme-to-WebAssembly Output

DevFeed: [Wastrel Compiles Hoot Scheme-to-WebAssembly Output](<https://devfeed.tech/articles/wastrelly-wabbits-35034.md>)

Original publisher: [Read original article](<https://wingolog.org/archives/2026/03/31/wastrelly-wabbits>)

Author: Andy Wingo

Published: 2026-03-31T20:34:23Z

Content type: article

Language: en

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

Topics: [WebAssembly](<https://devfeed.tech/topics/web-assembly.md>), [Compiler](<https://devfeed.tech/topics/compiler.md>), [scheme](<https://devfeed.tech/topics/scheme.md>)

Tags: [accidentally-quadratic](<https://devfeed.tech/tags/accidentally-quadratic.md>), [aot](<https://devfeed.tech/tags/aot.md>), [bigint](<https://devfeed.tech/tags/bigint.md>), [bignums](<https://devfeed.tech/tags/bignums.md>), [compiler](<https://devfeed.tech/tags/compiler.md>), [compilers](<https://devfeed.tech/tags/compilers.md>), [exception-handling](<https://devfeed.tech/tags/exception-handling.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [gc](<https://devfeed.tech/tags/gc.md>), [gcc](<https://devfeed.tech/tags/gcc.md>), [gmp](<https://devfeed.tech/tags/gmp.md>), [hoot](<https://devfeed.tech/tags/hoot.md>), [igalia](<https://devfeed.tech/tags/igalia.md>), [library](<https://devfeed.tech/tags/library.md>), [maps](<https://devfeed.tech/tags/maps.md>), [precision](<https://devfeed.tech/tags/precision.md>), [scheme](<https://devfeed.tech/tags/scheme.md>), [standard](<https://devfeed.tech/tags/standard.md>), [tail-calls](<https://devfeed.tech/tags/tail-calls.md>), [wasm](<https://devfeed.tech/tags/wasm.md>), [wastrel](<https://devfeed.tech/tags/wastrel.md>), [webassembly](<https://devfeed.tech/tags/webassembly.md>), [whippet](<https://devfeed.tech/tags/whippet.md>)

### AI overview

The article describes recent work on Wastrel, an ahead-of-time WebAssembly compiler, including compiling output from the Hoot Scheme-to-Wasm compiler. It covers implementing bignum operations with mini-gmp and updating Hoot to use standardized WebAssembly exception handling.

### Source excerpt

Good day! Today (tonight), some notes on the last couple months of Wastrel, my ahead-of-time WebAssembly compiler. Back in the beginning of February, I showed Wastrel running programs that use garbage collection, using an embedded copy of the Whippet collector, specialized to the types present in the Wasm program. But, the two synthetic GC-using programs I tested on were just ported microbenchmarks, and didn't reflect the output of any real toolchain. In this cycle I worked on compiling the output from the Hoot Scheme-to-Wasm compiler. There were some interesting challenges! bignums When I originally wrote the Hoot compiler, it targetted the browser, which already has a bignum implementation in the form of BigInt, which I worked on back in the day. Hoot-generated Wasm files use host bigints via externref (though wrapped in structs to allow for hashing and identity). In Wastrel, then, I implemented the imports that implement bignum operations: addition, multiplication, and so on. I did so using mini-gmp, a stripped-down implementation of the workhorse GNU multi-precision library. At some point if bignums become important, this gives me the option to link to the full GMP instead. Bignums were the first managed data type in Wastrel that wasn't defined as part of the Wasm module itself, instead hiding behind externref, so I had to add a facility to allocate type codes to these "host" data types. More types will come in time: weak maps, ephemerons, and so on. I think bignums would be a great proposal for the Wasm standard, similar to stringref ideally (sniff!), possibly in an attenuated form. exception handling Hoot used to emit a pre-standardization form of exception handling, and hadn't gotten around to updating to the newer version that was standardized last July. I updated Hoot to emit the newer kind of exceptions, as it was easier to implement them in Wastrel that way. Some of the problems Chris Fallin contended with in Wasmtime don't apply in the Wastrel case: sinc

## IntelliJ's New Kotlin Coroutine Inspections, Explained

DevFeed: [IntelliJ's New Kotlin Coroutine Inspections, Explained](<https://devfeed.tech/articles/intellij-s-new-kotlin-coroutine-inspections-explained-39320.md>)

Original publisher: [Read original article](<https://kt.academy/article/intellij-coroutines-new-warnings>)

Published: 2026-03-30T00:00:00Z

Content type: tutorial

Language: en

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

Topics: [IntelliJ IDEA](<https://devfeed.tech/topics/intellij-idea.md>), [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [kotlin-coroutines](<https://devfeed.tech/topics/kotlin-coroutines.md>), [Coroutines](<https://devfeed.tech/topics/coroutines.md>), [Android Studio](<https://devfeed.tech/topics/android-studio.md>), [Exception](<https://devfeed.tech/topics/exception.md>)

Tags: [android-studio](<https://devfeed.tech/tags/android-studio.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [intellij-idea](<https://devfeed.tech/tags/intellij-idea.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [kotlin-coroutines](<https://devfeed.tech/tags/kotlin-coroutines.md>), [workshop-learning-programming](<https://devfeed.tech/tags/workshop-learning-programming.md>)

### AI overview

This article explains new Kotlin coroutine inspections introduced in IntelliJ IDEA and also available in Android Studio. It describes warnings for coroutine usage patterns, including preferring awaitAll over await and currentCoroutineContext() over coroutineContext.

### Source excerpt

Exploration and explanation of new Kotlin coroutine inspections in IntelliJ IDEA.

## Taming chaos is a learnable skill

DevFeed: [Taming chaos is a learnable skill](<https://devfeed.tech/articles/taming-chaos-is-a-learnable-skill-37643.md>)

Original publisher: [Read original article](<https://swizec.com/blog/taming-chaos-is-a-learnable-skill>)

Author: hi@swizec.com (Swizec Teller)

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

Content type: opinion

Language: en

Sources: [Swizec Teller](<https://devfeed.tech/sources/swizec-teller.md>)

Topics: [Software Engineering](<https://devfeed.tech/topics/software-engineering.md>), [engineering-culture](<https://devfeed.tech/topics/engineering-culture.md>), [Low-Code / Internal Tools](<https://devfeed.tech/topics/internal-tools.md>)

Tags: [approach](<https://devfeed.tech/tags/approach.md>), [chaos](<https://devfeed.tech/tags/chaos.md>), [engineering](<https://devfeed.tech/tags/engineering.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [internal-tools](<https://devfeed.tech/tags/internal-tools.md>), [operations](<https://devfeed.tech/tags/operations.md>), [software-engineering](<https://devfeed.tech/tags/software-engineering.md>), [startup](<https://devfeed.tech/tags/startup.md>)

### AI overview

The article argues that handling interruptions, operational surprises, exceptions, and changing priorities is a learnable software-engineering skill. It recommends owning system problems, managing scope and tradeoffs, validating quality requirements, and maintaining a long-term vision despite short-term disruption.

### Source excerpt

How you approach software engineering makes it harder or easier to handle interruptions and other chaos. Writing a behavioral interview made me realize this is a learnable skill!

## nominal types in webassembly

DevFeed: [nominal types in webassembly](<https://devfeed.tech/articles/nominal-types-in-webassembly-35032.md>)

Original publisher: [Read original article](<https://wingolog.org/archives/2026/03/10/nominal-types-in-webassembly>)

Author: Andy Wingo

Published: 2026-03-10T08:19:34Z

Content type: article

Language: en

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

Topics: [WebAssembly](<https://devfeed.tech/topics/web-assembly.md>), [wasm](<https://devfeed.tech/topics/wasm.md>)

Tags: [exceptions](<https://devfeed.tech/tags/exceptions.md>), [hoot](<https://devfeed.tech/tags/hoot.md>), [igalia](<https://devfeed.tech/tags/igalia.md>), [isorecursive-types](<https://devfeed.tech/tags/isorecursive-types.md>), [nominal-types](<https://devfeed.tech/tags/nominal-types.md>), [structural-types](<https://devfeed.tech/tags/structural-types.md>), [type-equality](<https://devfeed.tech/tags/type-equality.md>), [types](<https://devfeed.tech/tags/types.md>), [wasm](<https://devfeed.tech/tags/wasm.md>), [wastrel](<https://devfeed.tech/tags/wastrel.md>), [webassembly](<https://devfeed.tech/tags/webassembly.md>)

### AI overview

This article explains WebAssembly's structural type equality, how recursive type groups approximate nominal typing within a module, and how the nominal typing proposal adds nominal types for stronger separation between types across modules.

### Source excerpt

Before the managed data types extension to WebAssembly was incorporated in the standard, there was a huge debate about type equality. The end result is that if you have two types in a Wasm module that look the same, like this: (type $t (struct i32)) (type $u (struct i32)) Then they are for all intents and purposes equivalent. When a Wasm implementation loads up a module, it has to partition the module's types into equivalence classes. When the Wasm program references a given type by name, as in (struct.get $t 0) which would get the first field of type $t, it maps $t to the equivalence class containing $t and $u. See the spec, for more details. This is a form of structural type equality. Sometimes this is what you want. But not always! Sometimes you want nominal types, in which no type declaration is equivalent to any other. WebAssembly doesn't have that, but it has something close: recursive type groups. In fact, the type declarations above are equivalent to these: (rec (type $t (struct i32))) (rec (type $u (struct i32))) Which is to say, each type is in a group containing just itself. One thing that this allows is self-recursion, as in: (type $succ (struct (ref null $succ))) Here the struct's field is itself a reference to a $succ struct, or null (because it's ref null and not just ref). To allow for mutual recursion between types, you put them in the same rec group, instead of each having its own: (rec (type $t (struct i32)) (type $u (struct i32))) Between $t and $u we don't have mutual recursion though, so why bother? Well rec groups have another role, which is that they are the unit of structural type equivalence. In this case, types $t and $u are not in the same equivalence class, because they are part of the same rec group. Again, see the spec. Within a Wasm module, rec gives you an approximation of nominal typing. But what about between modules? Let's imagine that $t carries important capabilities, and you don't want another module to be able to forge those c

## Modularizing SOLR Query Creation for Multi-Market Scale

DevFeed: [Modularizing SOLR Query Creation for Multi-Market Scale](<https://devfeed.tech/articles/modularizing-solr-query-creation-for-multi-market-scale-22544.md>)

Original publisher: [Read original article](<https://medium.com/walmartglobaltech/modularizing-solr-query-creation-for-multi-market-scale-a1f34e28b631?source=rss----905ea2b3d4d1---4>)

Author: Naman Parikh

Published: 2026-03-03T12:18:55Z

Content type: tutorial

Language: en

Sources: [Walmart Global Tech](<https://devfeed.tech/sources/walmart-global-tech.md>)

Topics: [Code](<https://devfeed.tech/topics/code.md>), [configuration](<https://devfeed.tech/topics/configuration.md>), [implementation](<https://devfeed.tech/topics/implementation.md>), [Testing](<https://devfeed.tech/topics/testing.md>), [debug](<https://devfeed.tech/topics/debug.md>)

Tags: [article](<https://devfeed.tech/tags/article.md>), [code](<https://devfeed.tech/tags/code.md>), [complexity](<https://devfeed.tech/tags/complexity.md>), [configuration](<https://devfeed.tech/tags/configuration.md>), [developer](<https://devfeed.tech/tags/developer.md>), [errors](<https://devfeed.tech/tags/errors.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [implementation](<https://devfeed.tech/tags/implementation.md>), [information-retrieval](<https://devfeed.tech/tags/information-retrieval.md>), [modular-monolith](<https://devfeed.tech/tags/modular-monolith.md>), [monolithic-architecture](<https://devfeed.tech/tags/monolithic-architecture.md>), [regression](<https://devfeed.tech/tags/regression.md>), [software-architecture](<https://devfeed.tech/tags/software-architecture.md>), [software-engineering](<https://devfeed.tech/tags/software-engineering.md>), [technical](<https://devfeed.tech/tags/technical.md>), [testing](<https://devfeed.tech/tags/testing.md>)

### AI overview

This article describes modularizing a 12,000-line SOLR query creation implementation used across multiple markets. It explains how separating query concerns, adding market-specific configuration, and using stronger typing aimed to reduce coupling, regression risk, and runtime errors.

### Source excerpt

Introduction When the SOLR query logic expanded into a 12,000-line monolithic implementation, each modification introduced significant risk, making every change feel akin to defusing a critical system. Adding a market-specific override required yet another if block, compounding complexity and slowing time-to-market. In this article, we will deep dive how we broke that SOLR query creation logic, enabling clean configuration per market, stronger typing, reducing technical debts and dramatically reduced runtime errors. Image generated with DALL-E via ChatGPTThe Problem: When SOLR Queries Creation Logic Become Technical Debt The SOLR query logic class was handling filtering logic, boosting logic, boost functions, pagination etc. All the parameters related to SOLR query was getting generated using single class. Overthe time, this core class handled various logics related to different type of queries: Primary search queries Item insertions via business tools Item insertions via semantic sources Thousands of lines tangled edge-case handling, scoring tweaks, and boosting logic. This unscalable approach: Blocked rapid iteration for new markets Tight Coupling: All query-handling logic lived in one massive class, making it difficult to cleanly separate concerns. Market-specific changes could unintentionally affect unrelated logic, requiring exhaustive regression testing. High Risk of Unintended Consequences: Changing business requirements (such as supporting different filtering or boosting strategies for a new market) entailed changing existing code that already served other markets. Developers had to be extremely cautious, as a bug or oversight could break unrelated functionality. No Configuration Flexibility: There was no clear system for externalizing market-specific configuration. Instead, all logic changes happened directly in code, preventing business users or product managers from making simple market changes without developer intervention. Increased Runtime exceptions

## Scalable API Response Handling Across Multi-Layered Architectures with Sandwich

DevFeed: [Scalable API Response Handling Across Multi-Layered Architectures with Sandwich](<https://devfeed.tech/articles/scalable-api-response-handling-across-multi-layered-architectures-with-sandwich-25924.md>)

Original publisher: [Read original article](<https://proandroiddev.com/scalable-api-response-handling-across-multi-layered-architectures-with-sandwich-39ab02ae8c90?source=rss-9bb203a4ab2e------2>)

Author: Jaewoong Eum

Published: 2026-02-08T06:25:14Z

Content type: tutorial

Language: en

Sources: [Stories by Jaewoong Eum on Medium](<https://devfeed.tech/sources/stories-by-jaewoong-eum-on-medium.md>)

Topics: [Android](<https://devfeed.tech/topics/android.md>), [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [API](<https://devfeed.tech/topics/api.md>), [kotlin-coroutines](<https://devfeed.tech/topics/kotlin-coroutines.md>), [Error Handling](<https://devfeed.tech/topics/error-handling.md>), [Network](<https://devfeed.tech/topics/network.md>)

Tags: [android](<https://devfeed.tech/tags/android.md>), [api](<https://devfeed.tech/tags/api.md>), [code](<https://devfeed.tech/tags/code.md>), [communication](<https://devfeed.tech/tags/communication.md>), [coroutines](<https://devfeed.tech/tags/coroutines.md>), [error-handling](<https://devfeed.tech/tags/error-handling.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [flow](<https://devfeed.tech/tags/flow.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [kotlin-multiplatform](<https://devfeed.tech/tags/kotlin-multiplatform.md>), [mvi](<https://devfeed.tech/tags/mvi.md>), [mvvm](<https://devfeed.tech/tags/mvvm.md>), [network](<https://devfeed.tech/tags/network.md>), [networking](<https://devfeed.tech/tags/networking.md>), [presentation](<https://devfeed.tech/tags/presentation.md>), [responses](<https://devfeed.tech/tags/responses.md>), [retrofit](<https://devfeed.tech/tags/retrofit.md>), [viewmodel](<https://devfeed.tech/tags/viewmodel.md>)

### AI overview

This tutorial explains how to handle Retrofit API responses, errors, and exceptions across multi-layered Android architectures such as MVVM and MVI. It presents Sandwich as a type-safe, composable approach and covers response handling, composition, merging, global error mapping, and Flow integration.

### Source excerpt

Unsplash@picoftasty Modern Android applications commonly adopt multi-layered architectures such as MVVM or MVI, where data flows through distinct layers: a data source, a repository, and a ViewModel (or presentation layer). Each layer has a specific responsibility, and network responses must propagate through all of them before reaching the UI. While this separation produces clean, testable code, it introduces a real challenge: how do you handle API responses, including errors and exceptions, as they cross each layer boundary? Most developers solve this by wrapping API calls in try-catch blocks and returning fallback values. This works for small projects, but as the number of API calls grows, the approach creates ambiguous results, scattered boilerplate, and lost context that downstream layers need. You end up with ViewModels that cannot tell whether an empty list means "no data" or "network failure," repositories that swallow important error details, and data sources that repeat the same error handling pattern dozens of times. In this article, you'll explore the problems that emerge when handling Retrofit API calls across layered architectures, why conventional approaches break down at scale, and how Sandwich provides a type safe, composable solution that simplifies response handling from the network layer all the way to the UI. You'll also walk through the full set of Sandwich APIs, from basic response handling to advanced patterns like sequential composition, response merging, global error mapping, and Flow integration, each with real world use cases that show when and why you would reach for them. Retrofit API calls with coroutines Most Android projects use Retrofit with Kotlin coroutines for network communication. A typical service interface looks like this: https://medium.com/media/ebcba33386d664d1cf69a89234d2e22a/href The service returns a List<Poster> directly. Retrofit deserializes the JSON response body and gives you the data. This works perfectly when the

## Writing Resilient Code That Bounces Back. The Artisan of the Day Is Zuzana Kunckova.

DevFeed: [Writing Resilient Code That Bounces Back. The Artisan of the Day Is Zuzana Kunckova.](<https://devfeed.tech/articles/writing-resilient-code-that-bounces-back-the-artisan-of-the-day-is-zuzana-kunckova-3995.md>)

Original publisher: [Read original article](<https://laravel.com/blog/writing-resilient-code-that-bounces-back-the-artisan-of-the-day-is-zuzana-kunckova>)

Author: Ana Tavares

Published: 2025-08-14T16:18:14Z

Content type: article

Language: en

Sources: [Laravel Blog](<https://devfeed.tech/sources/laravel-blog.md>)

Topics: [Resilience](<https://devfeed.tech/topics/resilience.md>), [Laravel](<https://devfeed.tech/topics/laravel.md>), [PHP](<https://devfeed.tech/topics/php.md>), [Software](<https://devfeed.tech/topics/software.md>), [Availability](<https://devfeed.tech/topics/availability.md>), [debugging](<https://devfeed.tech/topics/debugging.md>), [API](<https://devfeed.tech/topics/api.md>), [Database](<https://devfeed.tech/topics/database.md>), [monitor](<https://devfeed.tech/topics/monitor.md>), [Cache](<https://devfeed.tech/topics/cache.md>), [Website](<https://devfeed.tech/topics/website.md>)

Tags: [api](<https://devfeed.tech/tags/api.md>), [applications](<https://devfeed.tech/tags/applications.md>), [cache](<https://devfeed.tech/tags/cache.md>), [code](<https://devfeed.tech/tags/code.md>), [database](<https://devfeed.tech/tags/database.md>), [debugging](<https://devfeed.tech/tags/debugging.md>), [errors](<https://devfeed.tech/tags/errors.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [laravel](<https://devfeed.tech/tags/laravel.md>), [logs](<https://devfeed.tech/tags/logs.md>), [metrics](<https://devfeed.tech/tags/metrics.md>), [monitor](<https://devfeed.tech/tags/monitor.md>), [network](<https://devfeed.tech/tags/network.md>), [php](<https://devfeed.tech/tags/php.md>), [resilience](<https://devfeed.tech/tags/resilience.md>), [retry](<https://devfeed.tech/tags/retry.md>)

### AI overview

Zuzana Kunckova's video talk presents practical guidance for writing resilient applications. It covers validation, graceful error handling, meaningful monitoring and logging, retry strategies, caching, preserving user submissions, and graceful degradation when dependencies or networks fail.

### Source excerpt

The Larabelles founder shares her advice on writing resilent code.

## How to turn callback functions into suspend functions or Flow

DevFeed: [How to turn callback functions into suspend functions or Flow](<https://devfeed.tech/articles/how-to-turn-callback-functions-into-suspend-functions-or-flow-39322.md>)

Original publisher: [Read original article](<https://kt.academy/article/interop-callbacks-to-coroutines>)

Published: 2025-07-14T00:00:00Z

Content type: tutorial

Language: en

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

Topics: [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [kotlin-coroutines](<https://devfeed.tech/topics/kotlin-coroutines.md>), [callback](<https://devfeed.tech/topics/callback.md>), [functions](<https://devfeed.tech/topics/functions.md>), [Continuation](<https://devfeed.tech/topics/continuation.md>), [API](<https://devfeed.tech/topics/api.md>)

Tags: [callback](<https://devfeed.tech/tags/callback.md>), [cancellation](<https://devfeed.tech/tags/cancellation.md>), [continuation](<https://devfeed.tech/tags/continuation.md>), [coroutines](<https://devfeed.tech/tags/coroutines.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [functions](<https://devfeed.tech/tags/functions.md>), [guide](<https://devfeed.tech/tags/guide.md>), [how-to](<https://devfeed.tech/tags/how-to.md>), [interoperability](<https://devfeed.tech/tags/interoperability.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [kotlin-coroutines](<https://devfeed.tech/tags/kotlin-coroutines.md>), [suspend](<https://devfeed.tech/tags/suspend.md>), [workshop-learning-programming](<https://devfeed.tech/tags/workshop-learning-programming.md>)

### AI overview

A guide to adapting callback-based APIs for Kotlin Coroutines. It explains how to convert callbacks that return one value into suspending functions and how to adapt callbacks that emit multiple values into Flows, including handling cancellation and exceptions.

### Source excerpt

A guide on how to correctly convert callback-based functions into suspending functions or Flows in Kotlin Coroutines.

## KotlinConf 2025 Announcements

DevFeed: [KotlinConf 2025 Announcements](<https://devfeed.tech/articles/kotlinconf-2025-announcements-39349.md>)

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

Published: 2025-06-03T00:00:00Z

Content type: article

Language: en

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

Topics: [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [destructuring](<https://devfeed.tech/topics/destructuring.md>), [exceptions](<https://devfeed.tech/topics/exceptions.md>), [union types](<https://devfeed.tech/topics/union-types.md>), [syntax](<https://devfeed.tech/topics/syntax.md>), [Safe-Call Operator](<https://devfeed.tech/topics/safe-call-operator.md>)

Tags: [announcements](<https://devfeed.tech/tags/announcements.md>), [destructuring](<https://devfeed.tech/tags/destructuring.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [kotlinconf](<https://devfeed.tech/tags/kotlinconf.md>), [new-features](<https://devfeed.tech/tags/new-features.md>), [safe-call-operator](<https://devfeed.tech/tags/safe-call-operator.md>), [syntax](<https://devfeed.tech/tags/syntax.md>), [union-types](<https://devfeed.tech/tags/union-types.md>), [workshop-learning-programming](<https://devfeed.tech/tags/workshop-learning-programming.md>)

### AI overview

The article summarizes announcements from KotlinConf 2025, including K2 becoming stable, upcoming name-based destructuring, and rich errors with language-level support for result-or-error types and related operators.

### Source excerpt

The greatest announcements from KotlinConf 2025.

## Kotlin Exception Handling: Why Singleton Exceptions are a bad idea

DevFeed: [Kotlin Exception Handling: Why Singleton Exceptions are a bad idea](<https://devfeed.tech/articles/kotlin-exception-handling-why-singleton-exceptions-are-a-bad-idea-25732.md>)

Original publisher: [Read original article](<https://blog.shreyaspatil.dev/kotlin-exception-handling-why-singleton-exceptions-are-a-bad-idea/>)

Author: Shreyas Patil

Published: 2024-09-18T12:56:49Z

Content type: tutorial

Language: en

Sources: [Shreyas Patil's Blog](<https://devfeed.tech/sources/shreyas-patil-s-blog.md>)

Topics: [Exception](<https://devfeed.tech/topics/exception.md>), [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [debugging](<https://devfeed.tech/topics/debugging.md>), [App](<https://devfeed.tech/topics/app.md>), [Crashlytics](<https://devfeed.tech/topics/crashlytics.md>)

Tags: [android](<https://devfeed.tech/tags/android.md>), [best-practices](<https://devfeed.tech/tags/best-practices.md>), [coding](<https://devfeed.tech/tags/coding.md>), [crashlytics](<https://devfeed.tech/tags/crashlytics.md>), [debugging](<https://devfeed.tech/tags/debugging.md>), [errors](<https://devfeed.tech/tags/errors.md>), [exception-handling](<https://devfeed.tech/tags/exception-handling.md>), [exceptionhandling](<https://devfeed.tech/tags/exceptionhandling.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [java](<https://devfeed.tech/tags/java.md>), [jvm](<https://devfeed.tech/tags/jvm.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [kotlin-beginner](<https://devfeed.tech/tags/kotlin-beginner.md>), [kotlin-multiplatform](<https://devfeed.tech/tags/kotlin-multiplatform.md>), [mistakes](<https://devfeed.tech/tags/mistakes.md>), [programming-blogs](<https://devfeed.tech/tags/programming-blogs.md>), [programming-tips](<https://devfeed.tech/tags/programming-tips.md>)

### AI overview

This Kotlin micro-blog explains why singleton exception instances can produce incorrect stack traces and mislead debugging. It recommends avoiding singleton exceptions when stack traces matter, while noting they may be acceptable for internal state or informational exceptions that are not monitored at scale.

### Source excerpt

Understand why using singleton exceptions in Kotlin can be a bad practice and how it affects stack traces and debugging in your applications.

## SharedFlow vs StateFlow

DevFeed: [SharedFlow vs StateFlow](<https://devfeed.tech/articles/sharedflow-vs-stateflow-39374.md>)

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

Published: 2024-06-27T00:00:00Z

Content type: tutorial

Language: en

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

Topics: [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [LineageOS](<https://devfeed.tech/topics/lineageos.md>), [Back end](<https://devfeed.tech/topics/backend.md>), [WebSocket](<https://devfeed.tech/topics/websocket.md>)

Tags: [android](<https://devfeed.tech/tags/android.md>), [backend](<https://devfeed.tech/tags/backend.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [messages](<https://devfeed.tech/tags/messages.md>), [parameter](<https://devfeed.tech/tags/parameter.md>), [progress](<https://devfeed.tech/tags/progress.md>), [service](<https://devfeed.tech/tags/service.md>), [sharedflow](<https://devfeed.tech/tags/sharedflow.md>), [state](<https://devfeed.tech/tags/state.md>), [stateflow](<https://devfeed.tech/tags/stateflow.md>), [users](<https://devfeed.tech/tags/users.md>), [value](<https://devfeed.tech/tags/value.md>), [websocket](<https://devfeed.tech/tags/websocket.md>), [workshop-learning-programming](<https://devfeed.tech/tags/workshop-learning-programming.md>)

### AI overview

This tutorial explains the distinction between Kotlin's StateFlow and SharedFlow. StateFlow represents observable application state, while SharedFlow broadcasts events to observers. It discusses replay, required initial values, distinct updates, conflation, and examples for Android and backend services.

### Source excerpt

When to use SharedFlow and when to use StateFlow.

## Handling Runtime Exceptions

DevFeed: [Handling Runtime Exceptions](<https://devfeed.tech/articles/handling-runtime-exceptions-25055.md>)

Original publisher: [Read original article](<https://typealias.com/start/kotlin-exceptions/>)

Author: author@typealias.com (Dave Leeds)

Published: 2024-02-28T00:00:00Z

Content type: tutorial

Language: en

Sources: [Dave Leeds on Kotlin - typealias.com](<https://devfeed.tech/sources/dave-leeds-on-kotlin-typealias-com.md>)

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

Tags: [custom-exceptions](<https://devfeed.tech/tags/custom-exceptions.md>), [exception](<https://devfeed.tech/tags/exception.md>), [exception-handling](<https://devfeed.tech/tags/exception-handling.md>), [exception-types-in-kotlin](<https://devfeed.tech/tags/exception-types-in-kotlin.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [how-to](<https://devfeed.tech/tags/how-to.md>), [introduction](<https://devfeed.tech/tags/introduction.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [kotlin-programming](<https://devfeed.tech/tags/kotlin-programming.md>), [kotlin-throw-keyword](<https://devfeed.tech/tags/kotlin-throw-keyword.md>), [learn-to-program](<https://devfeed.tech/tags/learn-to-program.md>), [programming](<https://devfeed.tech/tags/programming.md>), [runtime-errors](<https://devfeed.tech/tags/runtime-errors.md>), [try-catch-blocks](<https://devfeed.tech/tags/try-catch-blocks.md>)

### AI overview

This Kotlin tutorial explains runtime exceptions, contrasting runtime problems with compile-time errors and introducing how to handle unexpected problems while a program runs.

### Source excerpt

In real life, when we decide to do something, we primarily think in terms of a successful experience. For example, if you're driving to your friend's house for dinner, you might look up the directions on a mapping app, make sure you've got enough gasoline in the car, and leave at the right time in order to arrive when dinner is hot. If everything goes according to plan, you'll arrive on time.

## Exceptional Exception Handling

DevFeed: [Exceptional Exception Handling](<https://devfeed.tech/articles/exceptional-exception-handling-23848.md>)

Original publisher: [Read original article](<http://testing.googleblog.com/2023/12/exceptional-exception-handling.html>)

Author: Google Testing Bloggers (noreply@blogger.com)

Published: 2023-12-05T13:19:00Z

Content type: tutorial

Language: en

Sources: [Google Testing Blog](<https://devfeed.tech/sources/google-testing-blog.md>)

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

Tags: [code](<https://devfeed.tech/tags/code.md>), [code-health](<https://devfeed.tech/tags/code-health.md>), [debugging](<https://devfeed.tech/tags/debugging.md>), [exception-handling](<https://devfeed.tech/tags/exception-handling.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [java](<https://devfeed.tech/tags/java.md>), [tott](<https://devfeed.tech/tags/tott.md>), [yiming-sun](<https://devfeed.tech/tags/yiming-sun.md>)

### AI overview

This article explains how oversized exception-handling blocks can obscure program logic, catch unintended exceptions, and lose root-cause information. Using Java examples, it recommends narrowing the try block, catching the specific exception, and preserving the original cause when rethrowing.

### Source excerpt

This is another post in our Code Health series. A version of this post originally appeared in Google bathrooms worldwide as a Google Testing on the Toilet episode. You can download a printer-friendly version to display in your office. by Yiming Sun Have you ever seen huge exception-handling blocks? Here is an example in Java, although you may have seen similar problems in Python, TypeScript, Kotlin, or any language that supports exceptions. Let's assume we are calling bakePizza() to bake a pizza, and it can be overbaked, throwing a PizzaOverbakedException. class PizzaOverbakedException extends Exception {}; void bakePizza () throws PizzaOverbakedException {}; try { // 100+ lines of code to prepare pizza ingredients. ... bakePizza(); // Another 100+ lines of code to deliver pizza to a customer. ... } catch (Exception e) { throw new IllegalStateException(); // Root cause ignored while throwing new exception. } Here are the problems with the above code: Obscuring the logic. The method bakePizza(), is obscured by the additional lines of code of preparation and delivery, so unintended exceptions from preparation and delivery may be caught. Catching the general exception. catch (Exception e) will catch everything, despite that we might only want to handle PizzaOverbakedException here. Rethrowing a general exception, with the original exception ignored. This means that the root cause is lost - we don't know what exactly goes wrong with pizza baking while debugging. Here is a better alternative, rewritten to avoid the problems above. class PizzaOverbakedException extends Exception {}; void bakePizza () throws PizzaOverbakedException {}; // 100+ lines of code to prepare pizza ingredients. ... try { bakePizza(); } catch (PizzaOverbakedException e) { // Other exceptions won't be caught. // Rethrow a more meaningful exception; so that we know pizza is overbaked. throw new IllegalStateException("You burned the pizza!", e); } // Another 100+ lines of code to deliver pizza to a cu

## KotlinConf'23-Kotlin & Functional Programming: pick the best, skip the rest by Urs Peter

DevFeed: [KotlinConf'23-Kotlin & Functional Programming: pick the best, skip the rest by Urs Peter](<https://devfeed.tech/articles/kotlinconf-23-kotlin-functional-programming-pick-the-best-skip-the-rest-by-urs-peter-27026.md>)

Original publisher: [Read original article](<https://appmattus.medium.com/kotlinconf23-kotlin-functional-programming-pick-the-best-skip-the-rest-by-urs-peter-8958d3dcb432?source=rss-be40b368c57e------2>)

Author: Matthew Dolan

Published: 2023-04-14T06:32:47Z

Content type: opinion

Language: en

Sources: [Stories by Matthew Dolan on Medium](<https://devfeed.tech/sources/stories-by-matthew-dolan-on-medium.md>)

Topics: [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [Functional programming](<https://devfeed.tech/topics/functional-programming.md>), [Programming](<https://devfeed.tech/topics/programming.md>), [exceptions](<https://devfeed.tech/topics/exceptions.md>)

Tags: [android](<https://devfeed.tech/tags/android.md>), [android-app-development](<https://devfeed.tech/tags/android-app-development.md>), [arrow](<https://devfeed.tech/tags/arrow.md>), [data-structures](<https://devfeed.tech/tags/data-structures.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [functional-programming](<https://devfeed.tech/tags/functional-programming.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [monad](<https://devfeed.tech/tags/monad.md>), [optional](<https://devfeed.tech/tags/optional.md>), [programming](<https://devfeed.tech/tags/programming.md>)

### AI overview

A review of Urs Peter's KotlinConf'23 talk on functional programming, covering monoids, functors, monads, and selective use of the Arrow framework. It highlights using Either for recoverable service errors, nullable comprehensions, and Arrow Optics for nested data updates.

### Source excerpt

KotlinConf'23 -- Kotlin & Functional Programming: pick the best, skip the rest by Urs Peterhttps://medium.com/media/b5b95f6bdbb507930534ef8279ba1d05/href I recently had the pleasure of listening to Urs Peter's talk on Kotlin & Functional. The speaker gave a great, simple summary of what a Monad is and how it works. In essence: a Monoid is combinable (plus) and has an identity (empty) element which when combined with another value returns that other value. a Functor is mappable (map) a Monad is composable (flatMap) The talk then went on to discuss some common monads, such as Collections and Optional. The highlight of the talk for me was when the speaker talked about cherry-picking the best features between Kotlin and Monads (using the Arrow framework). Use Monads selectively where needed and useful. Why use a Monad to replace try-catch blocks for the 95% of use cases? Let exceptions bubble up to a GlobalExceptionHandler. For the other 5%, where we're typically recovering in our service, prefer Either<A,B> over Result as it makes the contract explicit with easy access to the error reply. Prevent tedious null checks with Arrow's nullable{ } comprehension. With deeply nested data structures where you want to change something at the leaf level, use Arrow Optics instead of nested copy calls. While I enjoyed the talk, I would have loved to hear more best features. You can find my thoughts on more KotlinConf'23 talks at KotlinConf'23. Please let me know your thoughts. Join medium to read all of my articles or subscribe for e-mail updates.

## Interfaces 101 : Error Handling With Go Ep. 3

DevFeed: [Interfaces 101 : Error Handling With Go Ep. 3](<https://devfeed.tech/articles/interfaces-101-error-handling-with-go-ep-3-22213.md>)

Original publisher: [Read original article](<https://www.ardanlabs.com/blog/2023/02/interfaces-101-error-handling-with-go.html>)

Published: 2023-02-13T00:00:00Z

Content type: tutorial

Language: en

Sources: [William Kennedy](<https://devfeed.tech/sources/william-kennedy.md>)

Topics: [Go Language](<https://devfeed.tech/topics/go-language.md>), [interfaces](<https://devfeed.tech/topics/interfaces.md>), [Error Handling](<https://devfeed.tech/topics/error-handling.md>)

Tags: [compiler](<https://devfeed.tech/tags/compiler.md>), [error-handling](<https://devfeed.tech/tags/error-handling.md>), [error-interface](<https://devfeed.tech/tags/error-interface.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [false-positives](<https://devfeed.tech/tags/false-positives.md>), [go](<https://devfeed.tech/tags/go.md>), [go-error-handling](<https://devfeed.tech/tags/go-error-handling.md>), [golang](<https://devfeed.tech/tags/golang.md>), [implement](<https://devfeed.tech/tags/implement.md>), [interfaces](<https://devfeed.tech/tags/interfaces.md>), [video](<https://devfeed.tech/tags/video.md>)

### AI overview

This video explains Go error interfaces through a custom error type and a test that unexpectedly fails when the returned error appears to be nil. It covers how Go determines whether an interface value is nil and how to avoid false positives in custom interface implementations.

### Source excerpt

Introduction In episode 2, Miki examined the impact interfaces have on the performance of a Go program. To perform this experiment, Miki invoked a type's method in two ways: with the concrete type and as an interface function to measure the difference in execution time. The conclusion of this experiment was that calling a method with the concrete type is faster than using an interface. During the experiment, Miki made use of the build flag -gcflag='-m' to display which variables were being allocated on the heap and where the compiler was automatically inlining function calls.

## The curious case of bad blocks on an SSD, and how I got rid of them

DevFeed: [The curious case of bad blocks on an SSD, and how I got rid of them](<https://devfeed.tech/articles/the-curious-case-of-bad-blocks-on-an-ssd-and-how-i-got-rid-of-them-27111.md>)

Original publisher: [Read original article](<https://andrea.corbellini.name/2022/12/29/curious-ssd-badblocks/>)

Author: andreacorbellini

Published: 2022-12-29T04:00:00Z

Content type: article

Language: en

Sources: [Andrea Corbellini](<https://devfeed.tech/sources/andrea-corbellini.md>)

Topics: [NVMe](<https://devfeed.tech/topics/nvme.md>), [Linux](<https://devfeed.tech/topics/linux.md>), [Kernel](<https://devfeed.tech/topics/kernel.md>)

Tags: [badblocks](<https://devfeed.tech/tags/badblocks.md>), [errors](<https://devfeed.tech/tags/errors.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [filesystem](<https://devfeed.tech/tags/filesystem.md>), [information-technology](<https://devfeed.tech/tags/information-technology.md>), [kernel](<https://devfeed.tech/tags/kernel.md>), [linux](<https://devfeed.tech/tags/linux.md>), [nvme](<https://devfeed.tech/tags/nvme.md>), [smart](<https://devfeed.tech/tags/smart.md>), [ssd](<https://devfeed.tech/tags/ssd.md>), [storage](<https://devfeed.tech/tags/storage.md>), [ubuntu](<https://devfeed.tech/tags/ubuntu.md>)

### AI overview

The author investigates an NVMe SSD that develops severe read errors, filesystem hangs, and resets after being moved from a coffee-damaged laptop. Kernel logs show repeated errors, while SMART data appears largely acceptable despite some warning signs. The supplied excerpt ends during the self-test investigation.

### Source excerpt

I recently inherited a laptop that was broken by pouring some hot coffee on it. When I dissected it, it was pretty clear that most of it was unrecoverable: the CPU was completely fried, and its thermal paste splashed everywhere on the motherboard. (I wish I took a picture of it that I could share.) There were however a few pieces that looked in ...

## Always use feenableexcept() when doing floating point math

DevFeed: [Always use feenableexcept() when doing floating point math](<https://devfeed.tech/articles/always-use-feenableexcept-when-doing-floating-point-math-36251.md>)

Original publisher: [Read original article](<https://berthub.eu/articles/posts/always-do-this-floating-point/>)

Published: 2022-12-24T20:28:43Z

Content type: tutorial

Language: en

Sources: [Bert Hubert's writings](<https://devfeed.tech/sources/bert-hubert-s-writings.md>)

Topics: [floating-point](<https://devfeed.tech/topics/floating-point.md>), [C](<https://devfeed.tech/topics/c.md>), [C++](<https://devfeed.tech/topics/c-plus-plus.md>), [exceptions](<https://devfeed.tech/topics/exceptions.md>), [Optimization](<https://devfeed.tech/topics/optimization.md>), [gcc](<https://devfeed.tech/topics/gcc.md>), [Linux](<https://devfeed.tech/topics/linux.md>)

Tags: [c](<https://devfeed.tech/tags/c.md>), [c-plus-plus](<https://devfeed.tech/tags/c-plus-plus.md>), [compiler](<https://devfeed.tech/tags/compiler.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [floating-point](<https://devfeed.tech/tags/floating-point.md>), [linux](<https://devfeed.tech/tags/linux.md>), [math](<https://devfeed.tech/tags/math.md>), [optimization](<https://devfeed.tech/tags/optimization.md>), [programming](<https://devfeed.tech/tags/programming.md>)

### AI overview

This tutorial explains how floating-point exceptions, infinities, and NaNs can occur silently in C and C++ programs, especially under compiler optimization. It describes enabling floating-point exceptions under Linux with feenableexcept() and notes remaining issues involving SIMD optimization.

### Source excerpt

This is a refreshed & expanded copy of a very old page I hosted outside of this blog. I recently ran into "silent NaNs" again, and thought it might be a good idea to republish this advice here. A small post that documents something that almost no one appears to know. And if you do anything with floating point, you do need to know. Exceptions In C or C++, try this:

## Effective Kotlin Item 7: Prefer a nullable or Result result type when the lack of a result is possible

DevFeed: [Effective Kotlin Item 7: Prefer a nullable or Result result type when the lack of a result is possible](<https://devfeed.tech/articles/effective-kotlin-item-7-prefer-a-nullable-or-result-result-type-when-the-lack-of-a-result-is-possible-39285.md>)

Original publisher: [Read original article](<https://kt.academy/article/ek-nullable-result>)

Published: 2022-10-19T00:00:00Z

Content type: tutorial

Language: en

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

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

Tags: [avoid](<https://devfeed.tech/tags/avoid.md>), [exception](<https://devfeed.tech/tags/exception.md>), [exceptions](<https://devfeed.tech/tags/exceptions.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [workshop-learning-programming](<https://devfeed.tech/tags/workshop-learning-programming.md>)

### AI overview

This Kotlin article explains when to return nullable or Result types and when to throw exceptions. It recommends explicit return types for expected failures because they are clearer and more efficient to handle, while exceptions should be reserved for unexpected or exceptional conditions. It also notes reasonable uses of exceptions in some backend and Android processing patterns.

### Source excerpt

Why should we prefer to avoid throwing exceptions and using types to our advantage.

[Next page](<https://devfeed.tech/tags/exceptions.md?cursor=WyIyMDIyLTEwLTE5VDAwOjAwOjAwKzAwOjAwIiwgImI0ZWQ0NjZlLWFjMGItNGRlNS1hOGIyLTNhMTZjZTU4YjM5YyJd>)