Skip to content

ns build fails, cannot find fast-glob #5935

Closed

Description

@patricklx

Issue Description

fast-glob is beeing used in lib/services/ios-project-service.ts, but its not in package.json
glob is used in lib\controllers\migrate-controller

Reproduction

No response

Relevant log output (if applicable)

Environment

No response

Please accept these terms

Activity

  1. added
    bug-pending-triage
    on Dec 12, 2025
  2. NathanWalker commented on Feb 27, 2026

    @NathanWalker
    Contributor

    resolved.

  3. aleclarson commented on Nov 28, 2026

    @aleclarson
    Contributor

    Could you reopen this? I reproduced the missing runtime dependencies in the published NativeScript CLI 9.1.2. I first encountered the fast-glob crash on 9.1.1 while starting an Android dev build.

    Reproduction

    Run this in a fresh directory. It needs no NativeScript project or Android SDK.

    cd "$(mktemp -d)"
    printf '{"private":true,"packageManager":"pnpm@11.5.1"}\n' > package.json
    pnpm --config.node-linker=isolated --config.hoist=false add -D nativescript@9.1.2 --ignore-scripts
    pnpm exec ns run android

    Actual behavior

    The CLI exits with code 127 during startup.

    Cannot find module 'fast-glob'
    Require stack:
    - …/nativescript/lib/services/ios-project-service.js
    - …/nativescript/lib/common/yok.js
    - …/nativescript/lib/bootstrap.js
    - …/nativescript/lib/nativescript-cli.js
    - …/nativescript/bin/tns
    

    The published package requires fast-glob in ios-project-service.js but omits it from dependencies. I also confirmed the second missing dependency from the original report with pnpm exec node -e 'require("nativescript/lib/controllers/migrate-controller.js")', which fails with Cannot find module 'glob'.

    Expected behavior

    The CLI should load its services and reach normal project validation when installed with isolated dependency resolution. Please declare both runtime dependencies in the published package, or remove the imports.

    Verified on macOS arm64, Node.js 26.13.1, and pnpm 11.5.1. The downstream impact and workspace workaround are tracked in octane-xplat/octane-xplat#319.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug-pending-triage

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions