Skip to content

Unable to run yo on macOS Ventura Beta #753

@JakeHendy

Description

@JakeHendy

Type of issue

Bug.

My environment

  • OS version/details: macOS Ventura 13.0 Public Beta
  • Node version: 18.3.0
  • npm version: 8.11.0
  • Version of yo : 4.3.0

Expected behavior

When running any generator, the generator should complete successfully.

Current behavior

The generator stops because the insights package uses a version of os-name which doesn't have the latest macos-release in, and there is no try-catch surrounding the insights invocation:

yo/lib/cli.js

Line 54 in 1fe6ad1

const insight = new Insight({

This causes the cli to stop execution immediately.
Running the command with --no-insight does not stop this line being invoked.
Manually patching the macos-release file does of course, allow you to bypass this.

Steps to reproduce the behavior

Use macOS Ventura to run any yeoman generator.

Command line output

❯ yo --no-insight @microsoft/sharepoint                                 12:28:32
/usr/local/lib/node_modules/yo/node_modules/macos-release/index.js:27
	const [name, version] = nameMap.get(release);
	                        ^

TypeError: undefined is not iterable (cannot read property Symbol(Symbol.iterator))
    at macosRelease (/usr/local/lib/node_modules/yo/node_modules/macos-release/index.js:27:26)
    at osName (/usr/local/lib/node_modules/yo/node_modules/os-name/index.js:21:18)
    at new Insight (/usr/local/lib/node_modules/yo/node_modules/insight/lib/index.js:37:13)
    at Object.<anonymous> (/usr/local/lib/node_modules/yo/lib/cli.js:54:17)
    at Module._compile (node:internal/modules/cjs/loader:1105:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1159:10)
    at Module.load (node:internal/modules/cjs/loader:981:32)
    at Module._load (node:internal/modules/cjs/loader:827:12)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:77:12)
    at node:internal/main/run_main_module:17:47

Node.js v18.3.0

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions