Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

chore: upgrade nopt to v9 - #11021

#11021
Open
nulllkomalll wants to merge 1 commit into
ember-cli:masterember-cli/ember-cli:masterfrom
nulllkomalll:upgrade-nopt-v9nulllkomalll/ember-cli:upgrade-nopt-v9Copy head branch name to clipboard
Open

chore: upgrade nopt to v9#11021
nulllkomalll wants to merge 1 commit into
ember-cli:masterember-cli/ember-cli:masterfrom
nulllkomalll:upgrade-nopt-v9nulllkomalll/ember-cli:upgrade-nopt-v9Copy head branch name to clipboard

Conversation

@nulllkomalll

Copy link
Copy Markdown

Description

This PR upgrades the nopt dependency from v3.0.6 directly to v9.0.0.

Context & Motivation

Upgrading nopt has previously been a challenge due to a breaking change introduced in nopt v8 regarding how strings starting with dashes (e.g., --options "--split 2") are parsed. Previous attempts to fix this involved complex "masking" logic to preserve legacy behavior.

However, modern nopt versions have moved toward stricter, more standard CLI parsing for better predictability. This PR takes a "surgical" approach: instead of adding complexity to the source code, it updates the test suite to use standard string formats. This allows us to benefit from the latest nopt features and security updates while keeping the ember-cli codebase clean.

Changes

  • Dependency Update: Upgraded nopt to ^9.0.0 in package.json.

  • Test Refactor: Updated tests/unit/models/command-test.js to use a standard string ('split-2-random') for the parseArgs string-parsing test.

  • Lockfile: Updated pnpm-lock.yaml to reflect the new dependency tree.

Verification Results

I have verified this change against the core unit test suites on a Windows environment:

  • tests/unit/models/command-test.js: 43 passing
  • tests/unit/cli/cli-test.js: 84 passing
View Test Verification Screenshots

Command Model Tests (43 Passing)

image

CLI Unit Tests (84 Passing)

image image

Related Issues

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.

1 participant

Morty Proxy This is a proxified and sanitized view of the page, visit original site.