Enhancements:
Time.AppendFormat
where possible.Thanks to @caibirdme for their contributions to this release.
Enhancements:
Intp
, Stringp
, and other similar *p
field constructors
to log pointers to primitives with support for nil
values.Thanks to @jbizzle for their contributions to this release.
Enhancements:
Enhancements:
zapcore.OmitKey
to omit keys in an EncoderConfig
.RFC3339
and RFC3339Nano
time encoders.Thanks to @juicemia, @uhthomas for their contributions to this release.
Bugfixes:
MapObjectEncoder.AppendByteString
not adding value as a
string.Enhancements:
zaptest.WrapOptions
to wrap zap.Option
for creating test
loggers.Thanks to @iaroslav-ciupin, @lelenanam, @joa, @NWilson for their contributions to this release.
Bugfixes:
Enhancements:
Thanks to @nfarah86, @AlekSi, @JeanMertz, @philippgille, @etsangsplk, and @dimroc for their contributions to this release.
Enhancements:
*testing.TB
.zapcore.Field
to clean up GoDoc.Bugfixes:
go.uber.org/zap/buffer
.Thanks to @DiSiqueira and @djui for their contributions to this release.
Bugfixes:
Enhancements:
NewStdLogAt
, which extends NewStdLog
by allowing the user
to specify the level of the logged messages.Enhancements:
ContextMap
method to observer logs for simpler
field validation in tests.Enhancements:
go.uber.org/multierr
.Bugfixes:
Thanks to @richard-tunein and @pavius for their contributions to this release.
This release fixes two bugs.
Bugfixes:
This release adds a few small features and is fully backward-compatible.
Enhancements:
LineEnding
field to EncoderConfig
, allowing users to
override the Unix-style default.zap.AtomicLevel
implement fmt.Stringer
, which makes a
variety of operations a bit simpler.This release adds an enhancement to zap's testing helpers as well as the ability to marshal an AtomicLevel. It is fully backward-compatible.
Enhancements:
SugaredLogger
.AtomicLevel
implement encoding.TextMarshaler
.This release adds a gRPC compatibility wrapper. It is fully backward-compatible.
Enhancements:
zapgrpc
package that wraps zap's Logger and implements
grpclog.Logger
.This release fixes two bugs and adds some enhancements to zap's testing helpers. It is fully backward-compatible.
Bugfixes:
Enhancements:
Thanks to @moitias for contributing to this release.
This is zap's first stable release. All exported APIs are now final, and no
further breaking changes will be made in the 1.x release series. Anyone using a
semver-aware dependency manager should now pin to ^1
.
Breaking changes:
[]byte
to string
.Sync
methods to zapcore.Core
,
zap.Logger
, and zap.SugaredLogger
.testutils
package to zaptest
, which is less likely to
clash with other testing helpers.Bugfixes:
zapcore.NewCore
, which allows zap to
work with concurrency-safe WriteSyncer
implementations.fsync
standard out on Linux
systems.Enhancements:
Config
.CombineWriteSyncers
, a convenience function to tee multiple
WriteSyncer
s and lock the result.zaptest/observer
. This makes it
easier for particularly punctilious users to unit test their application's
logging.Thanks to @suyash, @htrendev, @flisky, @Ulexus, and @skipor for their contributions to this release.
This is the third release candidate for zap's stable release. There are no breaking changes.
Bugfixes:
zap.Any
are now correctly treated as binary blobs
rather than []uint8
.Enhancements:
log.Logger
instance.Thanks to @ansel1 and @suyash for their contributions to this release.
This is the second release candidate for zap's stable release. It includes two breaking changes.
Breaking changes:
#316: Zap's global loggers are now fully concurrency-safe
(previously, users had to ensure that ReplaceGlobals
was called before the
loggers were in use). However, they must now be accessed via the L()
and
S()
functions. Users can update their projects with
gofmt -r "zap.L -> zap.L()" -w .
gofmt -r "zap.S -> zap.S()" -w .
#309 and #317: RC1 was mistakenly shipped with invalid JSON and YAML struct tags on all config structs. This release fixes the tags and adds static analysis to prevent similar bugs in the future.
Bugfixes:
log
output now
correctly reports the logger's caller.Enhancements:
github.com/pkg/errors
.New(nil)
continues to return a no-op logger, NewNop()
is
now preferred. Users can update their projects with gofmt -r 'zap.New(nil) ->
zap.NewNop()' -w .
.github.com/uber-go/zap
now returns a
more informative error.Thanks to @skipor and @chapsuk for their contributions to this release.
This is the first release candidate for zap's stable release. There are multiple breaking changes and improvements from the pre-release version. Most notably:
zap
package. Code relevant
largely to extension authors is now in the zapcore
package.zapcore.Core
type makes it easy for third-party packages to use zap's
internals but provide a different user-facing API.Logger
is now a concrete type instead of an interface.L
and S
are included.This is a minor version, tagged to allow users to pin to the pre-1.0 APIs and upgrade at their leisure. Since this is the first tagged release, there are no backward compatibility concerns and all functionality is new.
Early zap adopters should pin to the 0.1.x minor version until they're ready to upgrade to the upcoming stable release.