Jamie King
dbb394fc8d
docs: spelling corrections
2024-03-12 18:36:24 -04:00
obrus-corcentric
79fe14e907
setLevel should respect level comparison option (#1901 )
...
* fix: `setLevel` should respect level comparison option
* test: add child logger test on respect level comparison
* Update lib/levels.js
---------
Co-authored-by: James Sumners <321201+jsumners@users.noreply.github.com>
2024-02-10 09:16:02 -05:00
obrus-corcentric
384df31c87
Add ability to override custom levels comparison ( #1883 )
...
* feat: add ability to override custom levels compare
* fix: use function instead of closure
* docs: update level comparison to docs
* test: update types tests for level comparison
* refactor: move default levels and sorting order to constants
* fix: made suggested changes in pr review
* fix: change enum annotation type
2024-02-01 15:16:55 +01:00
AJ Bienz
7a3df5ff2c
Pass logger instance as an argument in level-change event ( #1576 )
...
* include logger instance in `level-change` event
* updating types
2022-10-20 11:46:22 +02:00
Matteo Collina
b0fbe23341
removed flatstr as it is not needed anymore ( #1016 )
2021-04-20 22:54:22 +02:00
Matteo Collina
86744fa53c
Add pino.multistream ( #1004 )
...
* Add pino.multistream
Source code imported from https://github.com/pinojs/pino-multi-stream .
* Update docs/api.md
Co-authored-by: James Sumners <james@sumners.email>
* Update docs/api.md
Co-authored-by: James Sumners <james@sumners.email>
* Update docs/help.md
Co-authored-by: James Sumners <james@sumners.email>
* deleted multistream.js
* resue levels
Co-authored-by: James Sumners <james@sumners.email>
2021-04-10 23:09:56 +02:00
James Sumners
df893a77c5
Update to tap v15 ( #999 )
2021-04-01 12:44:40 -04:00
Matteo Collina
987b924192
Make the build pass again ( #962 )
2021-02-09 19:10:48 +01:00
salesh
98e31c0057
Fix for...in
2021-01-15 19:16:34 +01:00
salesh
2fd82b761f
Replacing var with let/const, somewhere left var because scope, somewhere left var because for + resolved all standard issues
2021-01-13 23:52:56 +01:00
Adam Davis
338e8f9ccb
Wrap prototype in factory and guard against loss of scope. ( #875 )
...
* test coverage
* return new instance in prototype factory
* PR feedback - add comment to test
2020-07-15 15:15:59 +02:00
James Sumners
8872c6ccb9
Implement a log method hook
2020-04-01 19:17:26 -04:00
Tomas Della Vedova
f3ab176c90
Add formatters for core log components ( #775 )
...
* WIP: added bindings and levels serializers
* Addressed comments
* Fixed test
* Moved from custom srializers to formatters
* Use stricter check in genLsCache
* Updated test
* Addressed comments
* Added log formatter and removed pino.* serializer
* Updated test
* Use factory for formatters object
* Added deprecations messages
- deprecated useLevelLabels
- deprecated changeLevelName
- deprecated pino.* serializer
* Updated test
* Addressed comments
* Fix test
* Improve code coverage
* Fixed levelKey handling
* Updated test
* Addressed comments
* Updated test
* Added formatters benchmarks
* Rename test
* 100% code coverage
* Added formatters to benchmark runner
* Updated documentation
* Update docs/api.md
Co-Authored-By: James Sumners <james@sumners.email>
* Update docs/api.md
Co-Authored-By: James Sumners <james@sumners.email>
* Update docs/api.md
Co-Authored-By: James Sumners <james@sumners.email>
* Update docs/api.md
Co-Authored-By: James Sumners <james@sumners.email>
* Update docs/api.md
Co-Authored-By: James Sumners <james@sumners.email>
* Update docs/api.md
Co-Authored-By: James Sumners <james@sumners.email>
* Addressed comments
Co-authored-by: James Sumners <james@sumners.email>
Co-authored-by: Matteo Collina <hello@matteocollina.com>
2020-03-18 14:18:02 +01:00
Andrew van Rooyen
72eb875edc
Deprecate the changeLevelName option and alias it to levelKey ( #772 )
...
* deprecate the `changeLevelName` option and alias it to `levelKey`
* use process.emitWarning instead of console.warn for deprecation message
* avoid accessing private state in changeLevelName deprecation test
2020-02-28 19:11:47 +01:00
Tommaso Allevi
919f5ad6f9
catch potential write errors on fatal flush sync ( #740 )
...
* Add forceFlushOnFatal flag
* Remove unused line
* Do nothing on error
* Update lib/levels.js
Co-Authored-By: David Mark Clements <david.mark.clements@gmail.com>
* Remove once
2019-11-18 09:49:06 +01:00
David Mark Clements
09e20d3388
always sync flush fatal log messages
2019-10-12 18:38:16 +02:00
Phil Gold
10a5d1cf50
fix(levels): useLevelLabels permanently mutates initial cache ( #684 )
...
* fix(levels): useLevelLabels permanently mutates initial cache
* simplify implimentation - always copy the instance state when recreating
2019-07-23 13:23:27 +02:00
Christoph Berg
2f5f054fe7
Don't use default levels if useOnlyCustomLevels is specified ( #522 )
2018-10-05 10:12:07 +02:00
husticdf
ce559baabf
Fix for issue 516 ( #517 )
...
* Fix for issue 516
https://github.com/pinojs/pino/issues/516
* Added unit test (#516 )
2018-09-18 18:06:30 +02:00
Arun Ranganathan
e870ff3811
Allow custom levels to override default and allow to remove default levels ( #515 )
2018-09-16 20:53:22 +02:00
Matteo Collina
d3e3aff74a
Updated standard to v12. ( #506 )
2018-08-29 16:24:38 +02:00
Arun Ranganathan
e6d8585c54
Add ability to change level name when creating the instance ( #503 )
2018-08-26 00:15:11 +02:00
James Sumners
72efea4d95
Add useLevelLabels option ( #492 )
...
* Add useLevelLabels option
* Add test for children writing level labels
2018-08-19 09:15:07 -04:00
davidmarkclements
f3de3fc63b
redudant code removal, increase cov
2018-08-12 23:51:07 +02:00
davidmarkclements
50cdd29906
rm addLevel
2018-07-15 23:15:01 +02:00
davidmarkclements
5aaa5454c6
custom levels bug fix
2018-07-14 02:00:13 +02:00
davidmarkclements
164120042c
custom levels - closes #446
2018-07-14 00:46:58 +02:00
davidmarkclements
e76946a801
100% coverage
2018-07-08 20:39:42 +02:00
davidmarkclements
2f94995541
final syntax tweaks
2018-06-12 19:37:28 +02:00
davidmarkclements
8f5016ee6a
more noise removal, slightly optimize child (maybe)
2018-06-11 19:49:36 +02:00
davidmarkclements
94ae3f8f45
more syntax polish & remove unnecessary prototype logger methods
2018-06-11 17:45:03 +02:00
davidmarkclements
80cd6d092c
mappings
2018-06-11 17:23:13 +02:00
davidmarkclements
d29fa7e482
no underscore prefixed properties, private state and methods using symbols
2018-06-11 17:00:43 +02:00
davidmarkclements
66647d6bfd
reduce noise in entry point
2018-06-08 13:14:56 +02:00
Rob McGuinness
2398af9059
add json begin token in lscache
2017-11-02 15:02:57 -04:00
Matteo Collina
df540c21e5
Faster child() implementation.
2017-07-11 14:01:34 +02:00
James Sumners
259792a2e0
Move module exports to end of files
2017-01-25 13:13:47 -05:00
James Sumners
f28d4416bb
Reorganize code for legibility
2017-01-24 23:17:38 -05:00