aidenybai / million

Optimize React performance and make your React 70% faster in minutes, not months.
https://million.dev
MIT License
16.35k stars 575 forks source link

Million lint currently doesn't support monorepo #1005

Open DannyAziz opened 7 months ago

DannyAziz commented 7 months ago

Describe the feature

Wasn't able to get million to work from inside a monorepo but noticed the GET call that was being made in my browser returned the following[{"cwd":"/Users/USER/Development/MONOREPOROOT,"port":52921,"version":0}] whereas the app I was testing is inside a nested folder

Opened up the specific app from a new Cursor window and everything works perfectly

Someway to provide a path to the extension or to the MillionLint call in my config file would be great!

Additional information

github-actions[bot] commented 7 months ago

Thanks for opening this issue! A maintainer will review it soon.

tobySolutions commented 7 months ago

Hmm, thank you for reporting this. That is definitely weird. I'll inform the team to look into this.

guipace commented 7 months ago

+1 on looking forward to it working with monorepos

A-Shleifman commented 7 months ago

Million is failing to connect when the root folder of the monorepo is opened in VSCode, however, there is no issue when opening the subproject folder directly.

github-actions[bot] commented 7 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs within the next 7 days.

ChiefORZ commented 7 months ago

well its still not working github bot -.-

tejas-hosamani commented 7 months ago

When I run npx @million/lint@latest

Need to install the following packages:
  @million/lint@latest
Ok to proceed? (y)
┌  ⚡ Million Lint
│
◇  Yarn detected.
│
◒  Installing @million/lint with Yarn.│
■  Warnings during installation. Command failed: yarn add @million/lint@latest --ignore-workspace-root-check
│
◇
│
◇  Would you like to continue anyway?
│  No
│
└  Setup failed.

I get this when I try installing million in monorepo. Should this be installed in a specific app/project within monorepo?


Edit: Is it okay to install it manually with yard add -D @million/lint?

github-actions[bot] commented 6 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs within the next 7 days.

cyrus-za commented 6 months ago

still doesnt work

tobySolutions commented 6 months ago

still doesnt work

Hey there @cyrus-za, this is being fixed by the team and will be available in the next release. Please bear with us.

tejas-hosamani commented 6 months ago

@tobySolutions , when is the next release? And what's the release cycle? I don't see a release after March 9th, so.

cyrus-za commented 6 months ago

still doesnt work

Hey there @cyrus-za, this is being fixed by the team and will be available in the next release. Please bear with us.

No problem. I was merely replying to the bot that wants to close the stale issue so I gave it new life :)

github-actions[bot] commented 5 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs within the next 7 days.

ChiefORZ commented 5 months ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs within the next 7 days.

still not released and fixed

faribauc commented 5 months ago

+1

Electron/Vite setup

NPMLog:


0 verbose cli /home/<user>/.nvm/versions/node/v21.7.1/bin/node /home/<user>/.nvm/versions/node/v21.7.1/bin/npm
1 info using npm@10.5.0
2 info using node@v21.7.1
3 timing npm:load:whichnode Completed in 0ms
4 timing config:load:defaults Completed in 1ms
5 timing config:load:file:/home/<user>/.nvm/versions/node/v21.7.1/lib/node_modules/npm/npmrc Completed in 1ms
6 timing config:load:builtin Completed in 1ms
7 timing config:load:cli Completed in 1ms
8 timing config:load:env Completed in 0ms
9 timing config:load:file:/home/<user>/<path>/<project>/.npmrc Completed in 1ms
10 timing config:load:project Completed in 2ms
11 timing config:load:file:/home/<user>/.npmrc Completed in 1ms
12 timing config:load:user Completed in 1ms
13 timing config:load:file:/home/<user>/.nvm/versions/node/v21.7.1/etc/npmrc Completed in 0ms
14 timing config:load:global Completed in 1ms
15 timing config:load:setEnvs Completed in 0ms
16 timing config:load Completed in 7ms
17 timing npm:load:configload Completed in 7ms
18 timing config:load:flatten Completed in 1ms
19 timing npm:load:mkdirpcache Completed in 0ms
20 timing npm:load:mkdirplogs Completed in 0ms
21 verbose title npm install @million/lint
22 verbose argv "install" "@million/lint"
23 timing npm:load:setTitle Completed in 1ms
24 timing npm:load:display Completed in 0ms
25 verbose logfile logs-max:10 dir:/home/<user>/.npm/_logs/2024-05-30T13_13_05_507Z-
26 verbose logfile /home/<user>/.npm/_logs/2024-05-30T13_13_05_507Z-debug-0.log
27 timing npm:load:logFile Completed in 4ms
28 timing npm:load:timers Completed in 0ms
29 timing npm:load:configScope Completed in 0ms
30 timing npm:load Completed in 19ms
31 timing arborist:ctor Completed in 0ms
32 silly logfile start cleaning logs, removing 2 files
33 silly logfile done cleaning log files
34 timing idealTree:init Completed in 320ms
35 timing idealTree:userRequests Completed in 1ms
36 silly idealTree buildDeps
37 silly fetch manifest @million/lint@*
38 timing arborist:ctor Completed in 0ms
39 http fetch GET 200 https://registry.npmjs.org/@million%2flint 1021ms (cache miss)
40 silly placeDep ROOT @million/lint@1.0.0-rc.14 OK for: <project>@1.0.0 want: *
41 silly fetch manifest @axiomhq/js@1.0.0-rc.3
42 silly fetch manifest @babel/core@7.24.6
43 silly fetch manifest @babel/types@7.24.6
44 silly fetch manifest @hono/node-server@^1.11.1
45 timing idealTree Completed in 1357ms
46 timing command:install Completed in 1362ms
47 verbose stack Error: Unsupported URL Type "workspace:": workspace:^
47 verbose stack     at unsupportedURLType (/home/<user>/.nvm/versions/node/v21.7.1/lib/node_modules/npm/node_modules/npm-package-arg/lib/npa.js:310:15)
47 verbose stack     at fromURL (/home/<user>/.nvm/versions/node/v21.7.1/lib/node_modules/npm/node_modules/npm-package-arg/lib/npa.js:367:13)
47 verbose stack     at Function.resolve (/home/<user>/.nvm/versions/node/v21.7.1/lib/node_modules/npm/node_modules/npm-package-arg/lib/npa.js:83:12)
47 verbose stack     at /home/<user>/.nvm/versions/node/v21.7.1/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/arborist/build-ideal-tree.js:1027:39
47 verbose stack     at run (/home/<user>/.nvm/versions/node/v21.7.1/lib/node_modules/npm/node_modules/promise-call-limit/dist/commonjs/index.js:67:22)
47 verbose stack     at /home/<user>/.nvm/versions/node/v21.7.1/lib/node_modules/npm/node_modules/promise-call-limit/dist/commonjs/index.js:84:9
47 verbose stack     at new Promise (<anonymous>)
47 verbose stack     at callLimit (/home/<user>/.nvm/versions/node/v21.7.1/lib/node_modules/npm/node_modules/promise-call-limit/dist/commonjs/index.js:35:69)
47 verbose stack     at #buildDepStep (/home/<user>/.nvm/versions/node/v21.7.1/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/arborist/build-ideal-tree.js:1041:11)
47 verbose stack     at async Arborist.buildIdealTree (/home/<user>/.nvm/versions/node/v21.7.1/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/arborist/build-ideal-tree.js:203:7)
48 verbose cwd /home/<user>/<path>/<project>
49 verbose Linux 6.5.0-28-generic
50 verbose node v21.7.1
51 verbose npm  v10.5.0
52 error code EUNSUPPORTEDPROTOCOL
53 error Unsupported URL Type "workspace:": workspace:^
54 verbose exit 1
55 timing npm Completed in 1449ms
56 verbose unfinished npm timer reify 1717074785593
57 verbose unfinished npm timer reify:loadTrees 1717074785596
58 verbose unfinished npm timer idealTree:buildDeps 1717074785918
59 verbose unfinished npm timer idealTree:#root 1717074785918
60 verbose code 1
61 error A complete log of this run can be found in: /home/<user>/.npm/_logs/2024-05-30T13_13_05_507Z-debug-0.log
ajnart commented 5 months ago

Same thing here: npx @million/lint@latest

npm ERR! code EUNSUPPORTEDPROTOCOL
npm ERR! Unsupported URL Type "workspace:": workspace:^
prasadpilla commented 5 months ago

CleanShot 2024-05-31 at 00 20 12 I am waiting for this too.

NisargIO commented 5 months ago

CleanShot 2024-05-31 at 00 20 12 I am waiting for this too.

This should be fixed in the latest version!

@prasadpilla @ajnart @faribauc

ajnart commented 5 months ago

CleanShot 2024-05-31 at 00 20 12 I am waiting for this too.

This should be fixed in the latest version!

@prasadpilla @ajnart @faribauc

Yup, you've told me on discord ! v18rc fixed it for me

rvetere commented 1 month ago

just installed the latest v1.0.0-rc.84 and it's not working in our monorepo with next.js