Changelog
All notable changes to Logpilot are documented here. This project follows Semantic Versioning and Keep a Changelog.
[2.1.0] – 2026-03-01
Added
- HTTP transport – batch log entries and POST them to any HTTP endpoint (#88)
transportErrorevent – emitted when a transport'swritemethod throws, so failures never crash the host application (#91)- TypeScript: exported
TransportandFormatterinterfaces for custom implementations
Changed
FileTransportnow creates parent directories automatically if they don't exist
Fixed
- Fixed
prettyFormatterdropping metadata fields that containednullvalues (#94)
[2.0.0] – 2026-01-15
Breaking changes
Migrating from v1?
Version 2.0 includes breaking changes. See the migration guide below.
- Removed:
log.log()method – use the specific level methods (log.info(),log.error(), etc.) instead - Changed: The
formatconfig option is now calledformatterand accepts a function, not a string - Changed:
FileTransportoptionpathrenamed tofilenamefor clarity
Added
fatallog level (severity 50) – higher thanerror, intended for unrecoverable failuresprettyFormatterfor colourised development outputlog.child(metadata)– create a child logger with pre-attached context fields
Improved
- Timestamp precision increased from seconds to milliseconds
- 40% reduction in memory allocation per log entry (benchmark: #72)
[1.3.2] – 2025-11-20
Fixed
StdoutTransportwasn't flushing the buffer before process exit on Windows (#61)- Circular references in metadata no longer throw – they're replaced with
[Circular]
[1.3.0] – 2025-09-05
Added
FileTransportwith daily log rotation and configurable retention periodlog.setLevel(level)– change the minimum log level at runtime
[1.0.0] – 2025-06-01
Initial stable release.
Loggerclass withdebug,info,warn, anderrorlevelsjsonFormatter– structured JSON outputStdoutTransport– write to stdout- Full TypeScript definitions
Migrating from v1
Update the formatter config
// v1
const log = new Logger({ format: 'json' });
// v2
const { jsonFormatter } = require('logpilot/formatters');
const log = new Logger({ formatter: jsonFormatter });
Replace log.log() calls
// v1
log.log('info', 'Server started');
// v2
log.info('Server started');
Update FileTransport option name
// v1
new FileTransport({ path: './logs/app.log' });
// v2
new FileTransport({ filename: './logs/app.log' });