From 11f026abbf45a48bbb0da5d8721250bc49eaed58 Mon Sep 17 00:00:00 2001 From: Ben McCann <322311+benmccann@users.noreply.github.com> Date: Fri, 8 Nov 2024 12:40:14 -0800 Subject: [PATCH 1/2] chore: replace readable-stream with built-in stream --- .github/workflows/ci.yml | 2 +- index.js | 2 +- package.json | 1 - test/basic.test.js | 2 +- test/example/example.js | 2 +- 5 files changed, 4 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e08f055a..9391efa2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,7 +40,7 @@ jobs: contents: read strategy: matrix: - node-version: [18.17, 20, 22] + node-version: [18.19, 20, 22] os: [ubuntu-latest] pino-version: [^9.0.0] steps: diff --git a/index.js b/index.js index 0368a660..528b2b0c 100644 --- a/index.js +++ b/index.js @@ -2,7 +2,7 @@ const { isColorSupported } = require('colorette') const pump = require('pump') -const { Transform } = require('readable-stream') +const { Transform } = require('stream') const abstractTransport = require('pino-abstract-transport') const colors = require('./lib/colors') const { diff --git a/package.json b/package.json index 4f878716..2cfccafd 100644 --- a/package.json +++ b/package.json @@ -44,7 +44,6 @@ "on-exit-leak-free": "^2.1.0", "pino-abstract-transport": "^2.0.0", "pump": "^3.0.0", - "readable-stream": "^4.0.0", "secure-json-parse": "^2.4.0", "sonic-boom": "^4.0.1", "strip-json-comments": "^3.1.1" diff --git a/test/basic.test.js b/test/basic.test.js index 3437d1e4..e2a58304 100644 --- a/test/basic.test.js +++ b/test/basic.test.js @@ -2,7 +2,7 @@ process.env.TZ = 'UTC' -const { Writable } = require('readable-stream') +const { Writable } = require('stream') const os = require('os') const test = require('tap').test const pino = require('pino') diff --git a/test/example/example.js b/test/example/example.js index f16c181d..f9a7452e 100644 --- a/test/example/example.js +++ b/test/example/example.js @@ -2,7 +2,7 @@ const _prettyFactory = require('../../') const pino = require('pino') -const { Writable } = require('readable-stream') +const { Writable } = require('stream') function prettyFactory () { return _prettyFactory({ From 757cc38c51c3cb83724d51e59d483f189f9c170a Mon Sep 17 00:00:00 2001 From: Ben McCann <322311+benmccann@users.noreply.github.com> Date: Fri, 8 Nov 2024 13:07:04 -0800 Subject: [PATCH 2/2] drop node 18 from CI --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9391efa2..ba696fda 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,7 +40,7 @@ jobs: contents: read strategy: matrix: - node-version: [18.19, 20, 22] + node-version: [20, 22] os: [ubuntu-latest] pino-version: [^9.0.0] steps: