/alexandru-skills:cats-mtl-typed-errorsfrom alexandru-skills
Designs custom domain error types in Scala using Cats MTL Raise/Handle and allow/rescue, avoiding EitherT while preserving Cats Effect composition. Covers Scala 2/3 syntax and IO-only or F[_] usage.
Ships in alexandru-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Raise[F, E] in functions that can raise errors.Handle.allow/rescue (Scala 3) or Handle.allowF (Scala 2) to introduce a scoped error capability and handle it like try/catch.IO[Either[E, A]] and avoid EitherT[IO, E, A]; pure functions returning Either[E, A] are fine at API boundaries.F[_] is optional: you can write IO-specific code or keep F[_] for polymorphism, depending on the project.Raise[F, E] (and Monad[F] or Applicative[F])..raise and return successful values with pure.Handle.allow (Scala 3) or Handle.allowF (Scala 2) to create a scope where raises are valid..rescue to handle each error case explicitly.E as the checked-exception channel in the function signature.Raise[F, E] in functions that can fail; use Handle[F, E] when you also need to recover.using and context functions with allow; type inference is significantly better.allowF and explicit implicit parameters; expect more braces and explicit types.Either[E, A] for parsing/validation and lift into F where needed.EitherT just to get a typed error channel; Cats MTL provides the capability without the stack.references/custom-error-types.md for detailed guidance, Scala 2/3 syntax, and rationale from the Typelevel article.What SKILL.md sets; muted values are Claude Code's defaults
18 skills in this plugin
/akka-streamsScala reactive streaming with Akka Streams and Pekko Streams. Use for dataflow and reactive programming patterns, testing stream components, and understanding when NOT to use streams (prefer plain functions for transformations and I/O)./arrow-resourceKotlin + Arrow Resource lifecycle discipline with `Resource`, `ResourceScope`, `resourceScope`, and context parameters. Use for safe acquisition/release of files, streams, DB pools/connections, HTTP clients, background scopes, or multipart parts; preventing resource leaks and use-after-close bugs; designing companion `Resource` builders; using `arrow-autoclose` when only synchronous `AutoCloseable` cleanup is possible; composing resources with typed errors, cancellation, or parallel acquisition./arrow-typed-errorsModels Kotlin logical failures with Arrow's context-parameter Raise DSL and wrappers such as Either, nullable, Option, and Ior. Use when implementing or simplifying typed-error flows, translating error types, replacing verbose Either handling, validating input with accumulation, or selecting an error wrapper./cats-effect-ioHelps agents write and review Scala Cats Effect IO code. Use for suspending side effects and non-determinism in IO or F[_], choosing Sync/Async/Temporal/Concurrent/Clock/Random, handling blocking I/O, testing with TestControl, and composing resources, fibers, races, and structured concurrency safely./cats-effect-resourceHelps agents write and review Scala Cats Effect Resource code. Use for preventing resource leaks and use-after-release bugs, modeling disposable values with Resource, designing Resource-returning factories and constructor-injected services, wrapping Java AutoCloseable values, composing resources, and handling cancellation-safe release./code-refineRefines code through the three lenses in `code-refinements` with verified, behavior-preserving edits. Use when the user asks to refine a scope of code, such as a module, a directory, or the changes on a branch.npx claudepluginhub alexandru/skills --plugin alexandru-skillsOther plugins' skills for the same job