coinbase / kryptology

Apache License 2.0
847 stars 123 forks source link

Errors should be publicly exported #12

Open qdm12 opened 2 years ago

qdm12 commented 2 years ago

Right now errors are in the internal directory. That means a repository importing this one cannot import those error variables and thus cannot check the error with errors.Is(err, ErrXYZ).

One could move errors to their own errors package in pkg/errors or have them locally defined for each exported package.

mikelodder7 commented 2 years ago

Thanks for this. We can move them or we accept PRs to make the change.