quasarframework / quasar

Quasar Framework - Build high-performance VueJS user interfaces in record time
https://quasar.dev
MIT License
25.89k stars 3.51k forks source link

Fails to run quasar dev on @quasar/app 1.4.3 #5970

Closed kimini507 closed 4 years ago

kimini507 commented 4 years ago

Describe the bug Upgrading to @quasar/app 1.4.3 makes the command quasar dev fail.

Top error message after running the quasar dev command is:

Error Unknown command "dev"

Tried to downgrade to @quasar/app^1.4.2 and app runs properly.

Codepen/jsFiddle/Codesandbox (required) I don't know how to set up this issue Codepen/jsFiddle/Codesandbox

To Reproduce Steps to reproduce the behavior:

  1. Upgrade or create a fresh project with @quasar/app^1.4.3
  2. Run quasar dev
  3. Error Unknown command "dev"

Expected behavior App should run in dev mode

Additional Info

What I've tried:

  1. Remove yarn.lock and node_modules (even .quasar on a different run) and reinstalled
  2. Cloned the repo again so it's fresh
  3. Removed and installed @quasar/cli (both in npm and in yarn one instance a time)
  4. Weird thing is, I tried to run quasar -v in my terminal and it shows 1.0.5 while when I ran it in my colleague's terminal, it shows 1.4.3 (after upgrade)

Before Upgrade

quasar info

Operating System - Windows_NT(10.0.18362) - win32/x64
NodeJs - 12.14.0

Global packages
  NPM - 6.13.4
  yarn - 1.19.1
  @quasar/cli - 1.0.5
  cordova - You have been opted out of telemetry. To change this, run: cordova telemetry on.
9.0.0 (cordova-lib@9.0.1)

Important local packages
  quasar - 1.5.11 -- Build high-performance VueJS user interfaces (SPA, PWA, SSR, Mobile and Desktop) in record time
  @quasar/app - 1.4.2 -- Quasar Framework local CLI
  @quasar/extras - 1.3.3 -- Quasar Framework fonts, icons and animations
  vue - 2.6.11 -- Reactive, component-oriented view layer for modern web interfaces.
  vue-router - 3.1.3 -- Official router for Vue.js 2
  vuex - 3.1.2 -- state management for Vue.js
  electron - Not installed
  electron-packager - Not installed
  electron-builder - Not installed
  @capacitor/core - Not installed
  @capacitor/cli - Not installed
  @capacitor/android - Not installed
  @capacitor/ios - Not installed
  @babel/core - 7.7.7 -- Babel compiler core.
  webpack - 4.41.3 -- Packs CommonJs/AMD modules for the browser. Allows to split your codebase into multiple bundles, which can be loaded on demand. Support loaders to preprocess files, i.e. 
json, jsx, es7, css, less, ... and your custom stuff.
  webpack-dev-server - 3.9.0 -- Serves a webpack app. Updates the browser on changes.
  workbox-webpack-plugin - 4.3.1 -- A plugin for your Webpack build process, helping you generate a manifest of local files that workbox-sw should precache.
  register-service-worker - 1.6.2 -- Script for registering service worker, with hooks

Quasar App Extensions
  @quasar/quasar-app-extension-testing - 1.0.0 -- A Quasar App Extension for managing Test Harnesses
  @quasar/quasar-app-extension-testing-unit-jest - 1.0.0 -- A Quasar App Extension for running Jest tests
  @quasar/quasar-app-extension-icon-genie - 1.1.3 -- A Quasar CLI Extension for Making All Your Icons

After Upgrade to 1.4.3

quasar info

Operating System        Windows_NT(10.0.18362) - win32/x64
NodeJs                  12.14.0

Global packages
  NPM                   6.13.4
  yarn                  1.19.1
  @quasar/cli           1.0.5
  cordova               You have been opted out of telemetry. To change this, run: cordova telemetry on.
9.0.0 (cordova-lib@9.0.1)

Networking
  Host                  BGINNB057
  Wi-Fi                 192.168.1.178

quasar -version

1.0.5

Platform (please complete the following information): OS: Windows 10 Node: 12.14.0 NPM: 6.13.4 Yarn: 1.19.1 Terminal: Powershell Browsers: Chrome

rstoenescu commented 4 years ago

Hi,

Cannot reproduce. Please provide more information. What terminal are you using? Did you try to delete node_modules and yarn.lock/package-lock.json and yarn/npm installl again?

hawkeye64 commented 4 years ago

I just created a new project and am also unable to reproduce -- works perfectly fine. I am on Ubuntu 18.04.

kimini507 commented 4 years ago

Hi guys, sorry for the late response, just came back to work.

I added additional information on the post above. Also I'm using powershell @rstoenescu .

There's something wrong with my environment and I can't pinpoint what. Upgrade to 1.4.3 works in my colleague's machine.

hawkeye64 commented 4 years ago

May be related to https://github.com/quasarframework/quasar/issues/3965 and https://github.com/quasarframework/quasar/issues/4224

kimini507 commented 4 years ago

@hawkeye64 , looked at the two issues you shared.

  1. Tried downgrading to node 10 (didn't work)
  2. Went back to node 12 (still not working)
  3. I used both CMD and PowerShell for testing (both in IDE - VSCode, and external shells)
  4. Tried reinstalling (uninstall/install) yarn, nodejs, project (cloned again, removed lock files and npm_modules)

More info: Right now in my repo, the @quasar/app version is 1.4.0 and 1.4.2 (i have 2 projects with the same issue)

@quasar/cli is 1.0.5

The quasar command successfully sees my directory as a quasar app before upgrade. But after running quasar upgrade -i and it upgrades my @quasar/app to 1.4.3, quasar dev or quasar -h shows the message:

  --------------
  => IMPORTANT !
  => Trigger this inside of a Quasar project (and npm/yarn install) for more commands.
  --------------

Right now I'm sticking to the current version where it's working.

pdanpdan commented 4 years ago

Are you inside a corporate network? can you check what is inside node_modules/@quasar subfolders? you might have some bullshit returned with a 200 response code by a filtering proxy.

kimini507 commented 4 years ago

Hi @pdanpdan , sadly I'm not inside a corporate network.

Here's what's inside the node_modules/@quasar:

Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----       07/01/2020  12:20 PM                app
d-----       07/01/2020  12:20 PM                babel-preset-app
d-----       07/01/2020  12:20 PM                extras
d-----       07/01/2020  12:20 PM                fastclick
d-----       07/01/2020  12:24 PM                quasar-app-extension-icon-genie
d-----       07/01/2020  12:20 PM                quasar-app-extension-testing
d-----       07/01/2020  12:22 PM                quasar-app-extension-testing-unit-jest

Also, I can confirm that it's my environment that has an issue. I tried upgrading my colleagues copy to @quasar/app^1.4.3 and it works perfectly.

What else should I do? I've already done the following:

  1. Reinstalling nodejs and yarn
  2. Removing the project and downloading again from repo
  3. Reinstalling @quasar/cli (both using yarn and npm)
  4. Used cmd and powershell (both in the IDE and out)
pdanpdan commented 4 years ago

Try this sequence in the folder of the project:

npm -g cache clean --force
npm -g cache verify

npm cache clean --force
npm cache verify

yarn global remove @quasar/cli
npm -g uninstall @quasar/cli
npm -g install @quasar/cli

yarn remove @quasar/cli
npm uninstall @quasar/cli

// delete node_modules, yarn.lock, package-lock.json

yarn

quasar info
kimini507 commented 4 years ago

@pdanpdan I'll try this sequence. Will get back to you tomorrow for this. Thanks!

kimini507 commented 4 years ago

@pdanpdan Thanks! It's working now. Looks like my global cache was messed up.

Looking back, it might be due to running quasar upgrade on two projects at the same time (where one or both fails).

wpplumber commented 3 years ago

see a solution here.

flowt-au commented 2 years ago

@pdanpdan I had a similar issue with Quasar v2.7.0 and @quasar/app-weback v3.5.2 on a Win10 box. After running your list of command above, all worked properly. Thanks, Murray

louiemej commented 1 year ago

"dev" command not found.

Screenshot_1

kub1x commented 11 months ago

I simply forgot to run npm install. Didn't expect to have this effect.

abazanov commented 10 months ago

I was in the wrong folder when it happened to me. When I cloned the empty repo onto my computer, it created a folder and put the code inside there. Make sure you are in the right folder when running the command.

tuantuanzi-code commented 7 months ago

Try this sequence in the folder of the project:

npm -g cache clean --force
npm -g cache verify

npm cache clean --force
npm cache verify

yarn global remove @quasar/cli
npm -g uninstall @quasar/cli
npm -g install @quasar/cli

yarn remove @quasar/cli
npm uninstall @quasar/cli

// delete node_modules, yarn.lock, package-lock.json

yarn

quasar info

hi, I have try this sequence, but still 'dev' is unknonw cmd, and my quasar info is : Operating System Windows_NT(10.0.22621) - win32/x64 NodeJs 16.14.0

Global packages NPM 8.3.1 yarn 1.22.22 @quasar/cli 2.4.0 @quasar/icongenie Not installed cordova Not installed

seems the existed project issue, I met the issue when I run under an existed project, it uses quasar v1.22.10 after checking package.json, then how can I try to install quasar/cli v1.22.10? I have tried "npm install -g @quasar/cli@1.22.10" but reports no match version found. and if I run under a new init project folder, it works well.

could you please help? thanks.