Local build not work
-
Hi @rstoenescu ,
I need to make some tests using forked repository where I added some components.
But if I do a npm run build I got these errors:> quasar-framework@0.12.0 build j:\git\quasar\quasar > node build/script.build.js Cleaned build artifacts. Building... [Error] Stylus could not compile src/themes/quasar.ios.styl file... j:\git\quasar\quasar\build\script.build.stylus.js:37 throw err ^ Error: stylus:18:9 14| $toolbar-background ?= $light 15| $toolbar-active-color ?= $light 16| $toolbar-faded-color ?= composite-color($toolbar-color) 17| 18| @import './quasar.core.variables' ---------------^ 19| 20| @import '../components/*/*.ios' 21| @import '../css-components/*/*.ios' failed to locate @import file ./quasar.core.variables.styl at Evaluator.visitImport (j:\git\quasar\quasar\node_modules\stylus\lib\visitor\evaluator.js:915:21) at Evaluator.Visitor.visit (j:\git\quasar\quasar\node_modules\stylus\lib\visitor\index.js:28:40) at Evaluator.visit (j:\git\quasar\quasar\node_modules\stylus\lib\visitor\evaluator.js:160:18) at Evaluator.visitRoot (j:\git\quasar\quasar\node_modules\stylus\lib\visitor\evaluator.js:707:27) at Evaluator.Visitor.visit (j:\git\quasar\quasar\node_modules\stylus\lib\visitor\index.js:28:40) at Evaluator.visit (j:\git\quasar\quasar\node_modules\stylus\lib\visitor\evaluator.js:160:18) at Evaluator.evaluate (j:\git\quasar\quasar\node_modules\stylus\lib\visitor\evaluator.js:247:15) at Renderer.render (j:\git\quasar\quasar\node_modules\stylus\lib\renderer.js:86:26) at j:\git\quasar\quasar\build\script.build.stylus.js:34:16 at Array.forEach (native) npm ERR! Windows_NT 10.0.14393 npm ERR! argv "J:\\nodejs\\node.exe" "C:\\Users\\FSG\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "run" "build" npm ERR! node v6.9.1 npm ERR! npm v4.0.3 npm ERR! code ELIFECYCLE npm ERR! quasar-framework@0.12.0 build: `node build/script.build.js` npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the quasar-framework@0.12.0 build script 'node build/script.build.js'. npm ERR! Make sure you have the latest version of node.js and npm installed. npm ERR! If you do, this is most likely a problem with the quasar-framework package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! node build/script.build.js npm ERR! You can get information on how to open an issue for this project with: npm ERR! npm bugs quasar-framework npm ERR! Or if that isn't available, you can get their info via: npm ERR! npm owner ls quasar-framework npm ERR! There is likely additional logging output above. npm ERR! Please include the following file with any support request: npm ERR! j:\git\quasar\quasar\npm-debug.log
Seems to me as I’m missing something installed
Environment: Windows 10 Pro 64bit, node 6.9.1, npm 4.0.3
Any hint?Francesco
-
@fsgiudice hi, does this help?
‘’‘js
npm install -g npm-windows-upgrade
npm-windows-upgrade
‘’’
Then erase node_modules and npm install again. -
Hi @rstoenescu
nope, same error.Also updated to latest node 6.9.2 and npm 4.0.5 but same results.
npm run dev works correctly, instead npm run build not.
It seems to me as some other global is missing.
Thank you for your effort.Francesco
-
Are you experiencing this with Quasar’s repo or with an app?
-
@rstoenescu,
actually with my fork of https://github.com/quasarframework/quasar.
To be sure, I have cloned your repository directly and, in a empty folder, I did:git clone https://github.com/quasarframework/quasar.git npm install npm run dev
and it works, but if I do
npm run build
the error is exactly the same reported above.
Francesco
-
@fsgiudice have you installed npm-windows-upgrade? I just tried building Quasar on Win
107 under cygwin:IEUser@IE11Win7 ~/quasar-dev $ npm run build > quasar-framework@0.12.1 build C:\cygwin\home\IEUser\quasar-dev > node build/script.build.js Cleaned build artifacts. Building... dist/quasar.ios.styl 118.00kb dist/quasar.ios.css 226.23kb dist/quasar.mat.styl 120.56kb dist/quasar.mat.css 247.62kb dist/quasar.ios.standalone.css 279.33kb dist/quasar.mat.standalone.css 300.64kb dist/quasar.ios.standalone.min.css 220.42kb dist/quasar.mat.standalone.min.css 239.52kb dist/quasar.common.js 312.03kb dist/quasar.es6.js 280.72kb dist/quasar.standalone.js 312.38kb dist/quasar.standalone.min.js 199.98kb dist/quasar.standalone.min.js.map 538.39kb dist/quasar.standalone.min.js.gz 44.10kb IEUser@IE11Win7 ~/quasar-dev $ IEUser@IE11Win7 ~/quasar-dev $ npm -v 3.10.8 IEUser@IE11Win7 ~/quasar-dev $ node -v v6.9.1 IEUser@IE11Win7 ~/quasar-dev
edit: Wait, silly me. That’s Windows 7.
-
@rstoenescu
Yes, already done months ago and again with your last request.
But I’m not under cygwin environment.
Tell me something about this, because it could be the difference. -
Scott
-
@s.molinari
Sorry for misunderstanding, I know what cygwin is, but what is relation with npm and node?
Is it a prerequisite of those?
Because I use gnuwin32 for some other things and probably it clashes. -
I have no idea, but are you on a 32bit machine?
Scott
-
@s.molinari
No, 64bit -
Hmm…wouldn’t you want to use gnuwin64 then? Not sure that would make any difference, but it just might considering Node is working with 64 bits.
Scott
-
Seems like Stylus breaks. It may be due to the
@imports
within Stylus files. @fsgiudice do you have some time to make some experiments?- Search *.styl files and change imports that start with ‘./’ by removing this string.
and second test: - Replace in all styl file imports ‘/’ to ‘’… maybe the path separator is an issue in Stylus on Windows10 ?
- Search *.styl files and change imports that start with ‘./’ by removing this string.
-
@rstoenescu
Bingo!
changing to@import 'src/themes/quasar.core.variables' @import 'src/components/*/*.mat' @import 'src/css-components/*/*.mat' @import 'src/vue-components/*/*.mat' @import 'src/themes/quasar.core.definitions'
and other files
modified: build/script.build.stylus.js modified: src/themes/quasar.core.definitions.styl modified: src/themes/quasar.core.variables.styl modified: src/themes/quasar.ios.styl modified: src/themes/quasar.mat.styl
now npm run build works.
But now I get error on npm run dev
So it is definitively a path problem on build script files.
I’m checking if I can find the error.Francesco
-
Update:
no result playing with paths. As written before latter case works in build mode, former in dev mode. -
@fsgiudice Will see what I can do. Won’t be able to take care of this too soon though. Simply ignore the build step if you are writing code for Quasar. Just “npm run dev” and add pages to the ‘/dev’ that use the features you are working on.
-
@rstoenescu
Hi, I already did so.
But with build I can use my fork like quasar-edge in package.json in my test apps.
The other way I tried was to add new components directly to my project, but there were collisions with some paths.
Now I will try using quasar-edge and adding components to apps.
I hope I was clear.
Anyway thank you for your time.
Francesco -
@fsgiudice if you write components for Quasar you already have a playground app working there (/dev folder, which is run on npm run dev and compiles Quasar on the fly). Add a page for each new component and test it out there. No need to compile and then use in another repo.