Skip to content

Remove more old dependencies#6

Merged
GrahamCampbell merged 3 commits intomainfrom
remove-old-dependencies
Apr 23, 2026
Merged

Remove more old dependencies#6
GrahamCampbell merged 3 commits intomainfrom
remove-old-dependencies

Conversation

@GrahamCampbell
Copy link
Copy Markdown
Contributor

No description provided.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Removes several external runtime dependencies (chalk, supports-color, strip-ansi, p-limit) by replacing them with internal utilities and Node built-ins, while updating CLI/log styling to remain stream-aware.

Changes:

  • Added internal ANSI color utilities (src/utils/colors.js + color-keywords.js) and updated CLI/log reporters to use stdout/stderr-specific palettes.
  • Replaced p-limit dependency with a local implementation (src/utils/p-limit.js) and wired it into components/state storage.
  • Replaced strip-ansi usage with node:util.stripVTControlCharacters and added/updated unit tests for the new behavior.

Reviewed changes

Copilot reviewed 25 out of 25 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
test/unit/src/utils/serverless-utils/log-reporters/node/style.test.js Adds coverage ensuring node log reporter styles use stderr palettes.
test/unit/src/utils/p-limit.test.js Adds unit tests for the new internal concurrency limiter.
test/unit/src/utils/colors.test.js Adds coverage for the new internal color-level detection and formatting.
test/unit/src/state/S3StateStorage.test.js Extends tests to ensure queued writes continue after a failed write.
test/unit/src/load.test.js Switches ANSI stripping implementation to Node built-in utility.
test/unit/src/components-service.test.js Adds a test ensuring max concurrency is honored for parallel commands.
test/unit/src/cli/format-output.test.js Switches ANSI stripping implementation to Node built-in utility.
test/unit/src/cli/colors.test.js Adds tests for stdout/stderr CLI palette exports.
test/unit/src/cli/Progresses.test.js Adds tests for visible-width ellipsis/wrapping/height limiting.
test/unit/src/cli/Output.test.js Adds test verifying stdout/stderr palettes are applied correctly per stream.
test/unit/src/Context.test.js Switches ANSI stripping implementation to Node built-in utility.
src/utils/serverless-utils/lib/log-reporters/node/style.js Replaces chalk/supports-color styling with internal stderr color palette.
src/utils/serverless-utils/lib/log-reporters/node/log-reporter.js Reads stderr color support level from internal palette instead of supports-color.
src/utils/p-limit.js Introduces local p-limit replacement used by core modules.
src/utils/colors.js Introduces internal ANSI color formatting + color support detection.
src/utils/color-keywords.js Adds CSS keyword RGB table (used by colorize).
src/state/S3StateStorage.js Swaps dependency p-limit to local implementation.
src/index.js Uses stderr CLI palette for error-path “verbose logs available” message.
src/handle-error.js Uses stderr palette for details + consistent red styling for Error header.
src/cli/colors.js Replaces chalk with stream-specific palettes built from internal colors utility.
src/cli/Progresses.js Uses stderr palette + Node’s VT stripping instead of strip-ansi.
src/cli/Output.js Splits stdout vs stderr styling and switches to Node’s VT stripping.
src/Context.js Uses stderr palette for progress footer message.
src/ComponentsService.js Swaps dependency p-limit to local implementation.
package.json Removes chalk, supports-color, strip-ansi, and p-limit dependencies.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/utils/p-limit.js
Comment thread src/utils/colors.js Outdated
Comment thread src/utils/p-limit.js Outdated
Comment thread src/cli/Output.js Outdated
Comment thread src/cli/Output.js Outdated
Comment thread src/cli/Output.js Outdated
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 25 out of 25 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread test/unit/src/utils/serverless-utils/log-reporters/node/style.test.js Outdated
@GrahamCampbell GrahamCampbell merged commit ebdc8ea into main Apr 23, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants