Skip to content

Commit 31bfa33

Browse files
committed
Fix tests
1 parent 466bac0 commit 31bfa33

2 files changed

Lines changed: 16 additions & 4 deletions

File tree

CHANGELOG.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,20 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
66
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
77

88

9-
## [Unreleased](https://github.com/gravitton/errors/compare/v1.0.0...master)
9+
## [Unreleased](https://github.com/gravitton/errors/compare/v1.1.0...master)
1010

11+
## v1.1.0 (2026-04-22)(https://github.com/gravitton/errors/compare/v1.0.0...v1.1.0)
12+
### Added
13+
- `DataError` stack trace capture via `StackTrace()`
14+
- `DataError.Is` for sentinel matching with optional field scoping
15+
- `DataError.WithCause` for attaching a cause to the error chain
16+
- `DataError.GoString` for debugging output
17+
18+
### Changed
19+
- `MultiError.Append` renamed to `MultiError.Add`
20+
- `MultiError` mutex upgraded to `sync.RWMutex` for improved read concurrency
21+
- `MultiError.ErrorOrNil` and `Unwrap` now handle nil receiver safely
22+
- `MultiError.Error` and `GoString` are now concurrency-safe
1123

1224
## v1.0.0 (2025-10-17)
1325
### Added

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,8 @@ import (
4949
func Process() error {
5050
errs := errors.NewMulti()
5151

52-
errs.Append(process(1))
53-
errs.Append(process(2))
52+
errs.Add(process(1))
53+
errs.Add(process(2))
5454

5555
return errs.ErrorOrNil()
5656
}
@@ -65,7 +65,7 @@ func ProcessConcurrent() error {
6565
defer wg.Done()
6666

6767
if err := process(i); err != nil {
68-
errs.Append(errors.Wrap(err).WithField("process", i))
68+
errs.Add(errors.Wrap(err).WithField("process", i))
6969
}
7070
}(i)
7171
}

0 commit comments

Comments
 (0)