Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] npm owner does not support workspaces #4600

Closed
2 tasks done
nlf opened this issue Mar 22, 2022 · 6 comments
Closed
2 tasks done

[BUG] npm owner does not support workspaces #4600

nlf opened this issue Mar 22, 2022 · 6 comments
Assignees
Labels
Bug thing that needs fixing Priority 1 high priority issue Release 8.x work is associated with a specific npm 8 release

Comments

@nlf
Copy link
Contributor

nlf commented Mar 22, 2022

Is there an existing issue for this?

  • I have searched the existing issues

This issue exists in the latest npm version

  • I am using the latest npm

Current Behavior

running npm owner commands from within a workspace in a project logs the following error

npm ERR! code ENOWORKSPACES
npm ERR! This command does not support workspaces.

Expected Behavior

commands should work as expected. we'll need to modify the getPkg method such that it is workspace aware, as well as add the execWorkspaces method which appears it can call exec directly.

Steps To Reproduce

  1. Clone this repo
  2. cd workspaces/arborist
  3. npm owner ls
  4. See error...

Environment

  • npm: 8.5.5
  • Node.js: 16.13.2
  • OS Name: OSX
  • System Model Name: M1 MBP
  • npm config:
; copy and paste output from `npm config ls` here
@nlf nlf added Release 8.x work is associated with a specific npm 8 release Bug thing that needs fixing Needs Triage needs review for next steps labels Mar 22, 2022
@darcyclarke
Copy link
Contributor

Interesting, looks like npm doctor also is throwing in this setting. I know there was an initial set of commands we decided wouldn't support workspaces out the gate (ref. https://github.com/npm/rfcs/blob/main/accepted/0038-workspaces-run-cmds.md#3-unsupported) but given that we now support auto detection, I think we need to just triple check each command works when navigating into a workspace dir.

@fritzy fritzy added Priority 2 secondary priority issue and removed Needs Triage needs review for next steps labels Mar 30, 2022
@fritzy
Copy link
Contributor

fritzy commented Mar 30, 2022

@darcyclarke you may want to move this to a priority 1, since this is due to recent changes.

@alexjoverm
Copy link

alexjoverm commented Apr 6, 2022

Agree with @fritzy here. We use semantic-release at Storyblok to automatically release all our SDK packages. Semantic release runs npm owner under the hood, and due to this issue, the releases of our whole SDK ecosystem were broken.

In case this is happening to you, for us downgrading to 16.13.2 on our Github Actions config worked well 👌 https://github.com/storyblok/storyblok-js/runs/5855290031

@bnb
Copy link
Contributor

bnb commented Apr 9, 2022

Interesting, looks like npm doctor also is throwing in this setting. I know there was an initial set of commands we decided wouldn't support workspaces out the gate (ref. https://github.com/npm/rfcs/blob/main/accepted/0038-workspaces-run-cmds.md#3-unsupported) but given that we now support auto detection, I think we need to just triple check each command works when navigating into a workspace dir.

I just ran into npm doctor not supporting workspaces. Hilariously, I tried running it to see if it'd be able to help me figure out why one of my workspaces isn't working despite all my configuration being apparently correct.

@darcyclarke darcyclarke added Priority 1 high priority issue and removed Priority 2 secondary priority issue labels Apr 19, 2022
@wraithgar wraithgar self-assigned this Apr 27, 2022
@wraithgar
Copy link
Member

wraithgar commented May 4, 2022

This is fixed in v8.9.0

@mattclough1
Copy link

mattclough1 commented Jun 29, 2023

Is it expected that npm set gives the same error?

Edit: I see this is covered in #6099

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug thing that needs fixing Priority 1 high priority issue Release 8.x work is associated with a specific npm 8 release
Projects
None yet
Development

No branches or pull requests

7 participants