pkg/errors

Simple error handling primitives

View on GitHub ↗Jump to charts ↓

Summary Information

Updated 44 minutes ago
Added to GitGenius on September 8th, 2026
Created on December 27th, 2015
Open Issues & Pull Requests: 44 (+0)
GitHub issues: Enabled
Number of forks: 713
Total Stargazers: 8,257 (+0)
Total Subscribers: 102 (+0)

Repository Insights (GitGenius)

Median issue/PR response: 0.6 hours
Mean response time: 13.5 hours
90th percentile: 26.4 hours
Tracked items: 2

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 2
New in 7 days: 0
Closed in 7 days: 0
Avg open age: 972 days
Stale 30+ days: 2
Stale 90+ days: 0

Recent activity

Opened in 7 days: 0
Closed in 7 days: 0
Comments in 7 days: 0
Events in 7 days: 0

Top labels

No label distribution available yet.

Most active issues this week

No issue events were indexed in the last 7 days.

Detailed Description

pkg/errors is a Go error handling library that provides simple primitives for adding context to errors while preserving the original error value.

Go's traditional error handling pattern propagates errors up the call stack without context, making debugging difficult. The errors package solves this by offering the Wrap function, which adds contextual information to an error without destroying the underlying error value. Developers can then use the Cause function to retrieve the original error from a wrapped stack, allowing inspection of the root cause while maintaining the full error chain.

The tool suits any Go project where error context and debugging information matter. It is particularly valuable in applications where errors pass through multiple layers and you need to understand both what went wrong at the source and what was happening when the error occurred at each level. The package is straightforward to adopt: wrap errors with context as they propagate upward, and unwrap them when you need to inspect the original cause.

The project is in maintenance mode following Go's error handling proposals. Pull requests for bug fixes and issue reports are welcome, but the maintainers are not accepting proposals for new functionality. The roadmap indicates a planned final release, with the package moving toward stability rather than active feature development.