diene.go-errors-problems

module
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 24, 2026 License: MIT

README

Diene Go errors-problems library

CI Unit coverage Integration coverage Meta coverage Go Reference Commit activity

Diene's reproducible development environment is managed by Nix. Run direnv allow once, then use pls tasks from the loaded shell.

This repository inherits the all-features workspace baseline: split CI/CD, secrets, release configuration, validators, standards, and vendored agent-skill synchronization.

Commands

  • pls setup — synchronize installed diene package skills.
  • pls lint — run every pre-commit gate.
  • pls secret:scan — scan tracked content for secrets.
  • pls skills:sync — rebuild .claude/skills/vendor/ from installed packages.

Publishable Go module

github.com/AtomiCloud/diene.go-errors-problems is the Go family's RFC 9457 problem-details library — the Go "result slot" (C0 §5): no monad, idiomatic (T, error) with problem-typed errors. It ships the Problem envelope, the single-source type-URI builder, the typed registry and catalog export (C0 §14), the FromObject transformer, LocalError wrapping, and a consumer-facing testhelper package — all strict black-box tested and published by tag through the Go proxy.

go get github.com/AtomiCloud/diene.go-errors-problems@latest
uri, _ := problem.TypeURI(portal, "v1", "entity-not-found")
err := problem.NewError(problem.Problem{Type: uri, Title: "Entity not found", Status: 404})

Go commands

  • pls build — build every package in the module.
  • pls typecheck — compile every source package without running tests.
  • pls test / pls test:coverage — run unit, integration, and active meta tiers.
  • pls deadcode — run strict whole-repository and production passes plus the LLM-lax report.
  • pls up / pls down — start or stop local Redis.
  • ./scripts/ci/pkg-validate.sh all — run module-path, vet, API, docs, and example validators.

See the Go baseline for the language contract and template-maintenance boundary. See the Go library baseline for promotion, testing, compatibility, and publication policy.

Standards

Shared standards

Domain-specific documentation belongs under docs/domain/. The docs/standards/contracts/ location is reserved for the separately owned C0 contracts standard.

Go language variants

Directories

Path Synopsis
lib
problem
Package problem implements the AtomiCloud RFC 9457 problem-details contract (C0 §2/§14) in Go idiom.
Package problem implements the AtomiCloud RFC 9457 problem-details contract (C0 §2/§14) in Go idiom.
Package testhelper ships the Problem assertion helpers and builders that consumers of github.com/AtomiCloud/diene.go-errors-problems would otherwise repeat in every test: recovering a problem.Problem from a (T, error) result via errors.As, matching it field by field, and minting valid fixtures whose type URIs come from the single-source builder.
Package testhelper ships the Problem assertion helpers and builders that consumers of github.com/AtomiCloud/diene.go-errors-problems would otherwise repeat in every test: recovering a problem.Problem from a (T, error) result via errors.As, matching it field by field, and minting valid fixtures whose type URIs come from the single-source builder.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL