GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - errbit/errbit-ruby: Plain-Ruby client for reporting exceptions to an Errbit server

BranchesTags
Open more actions menu

Latest commit

 

History

4 Commits
4 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
bin
bin
 
 
lib
lib
 
 
openapi
openapi
 
 
spec
spec
 
 
.gitignore
.gitignore
 
 
.rspec
.rspec
 
 
.rubocop.yml
.rubocop.yml
 
 
.ruby-version
.ruby-version
 
 
AGENTS.md
AGENTS.md
 
 
CLAUDE.md
CLAUDE.md
 
 
Gemfile
Gemfile
 
 
Gemfile.lock
Gemfile.lock
 
 
LICENSE.txt
LICENSE.txt
 
 
README.md
README.md
 
 
Rakefile
Rakefile
 
 
errbit-ruby.gemspec
errbit-ruby.gemspec
 
 

Repository files navigation

errbit-ruby

A dependency-free Ruby client for reporting exceptions to an Errbit server. Plain Ruby only — no Rails, no Rack required. Targets Ruby >= 4.0 and has zero runtime dependencies (uses only net/http, json, and uri from the standard library).

This gem talks to a new, purpose-built error-ingestion API — it is not compatible with the Airbrake or Sentry APIs. The API is specified in openapi/errbit-api.yaml.

Installation

Add to your Gemfile:

gem "errbit-ruby", require: "errbit"

or install directly:

gem install errbit-ruby

Usage

Configure once, near your application's boot:

require "errbit"

Errbit.configure do |config|
  config.host       = "https://errbit.example.com"
  config.project_id = ENV.fetch("ERRBIT_PROJECT_ID")
  config.api_key    = ENV.fetch("ERRBIT_API_KEY")

  # Optional: exception classes, class-name strings, or regexps to skip.
  config.ignore = [ArgumentError, /expected, harmless/i]
end

Then report exceptions where you rescue them:

begin
  risky_operation
rescue => e
  Errbit.notify(e)
  raise
end

Errbit.notify returns an Errbit::Result:

result = Errbit.notify(e)

result.success? # => true/false
result.ignored?  # => true if the exception matched config.ignore
result.failure?  # => true on a 4xx/5xx response from the server
result.id         # => server-assigned id, on success
result.error      # => server error message, on failure

A report is delivered synchronously over HTTP(S) on the calling thread. A network failure (timeout, connection refused, etc.) raises Errbit::DeliveryError; a well-formed error response from the server (400/401/404) does not raise — check result.failure? instead.

Development

bundle install
bundle exec rspec

bin/console starts an IRB session with the gem pre-configured against a placeholder host for manual experimentation.

API

See openapi/errbit-api.yaml for the full OpenAPI 3.1 definition of the single endpoint this gem calls:

POST /api/v1/projects/{project_id}/errors/{api_key}

License

MIT

About

Plain-Ruby client for reporting exceptions to an Errbit server

Resources

Readme
MIT license
Activity
Custom properties

Stars

1 star

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.