jadjoubran / laravel5-angular-material-starter

Get started with Laravel 5.3 and AngularJS (material)
https://laravel-angular.readme.io/
MIT License
1.66k stars 400 forks source link

Npm install fails on packagist stable version 3.2.0 - due to laravel-elixir version #353

Closed chihab closed 8 years ago

chihab commented 8 years ago

Hi,

When running npm install, I've got this error:

npm ERR! Linux 4.2.0-c9
npm ERR! argv "/home/ubuntu/.nvm/versions/node/v4.4.5/bin/node" "/home/ubuntu/.nvm/versions/node/v4.4.5/bin/npm" "install" "laravel-elixir"
npm ERR! node v4.4.5
npm ERR! npm  v2.15.5
npm ERR! code EPEERINVALID

npm ERR! peerinvalid The package laravel-elixir@4.2.1 does not satisfy its siblings' peerDependencies requirements!
npm ERR! peerinvalid Peer laravel-elixir-livereload@1.1.6 wants laravel-elixir@^5.0

npm ERR! Please include the following file with any support request:
npm ERR!     /home/ubuntu/workspace/laravel5-angular-material-starter/npm-debug.log

I've got to set laravel-elixir to version 5.0.0 on package.json to fix this.

    "laravel-elixir": "^5.0.0",
    "laravel-elixir-livereload": "^1.1.1",
    "main-bower-files": "^2.1.0",

Thanks.

milocosmopolitan commented 8 years ago

I'm not sure why you are trying to install "laravel-elixir-livereload": "^1.1.1". I believe livereload was replaced to "browserify": "~8.1.3" from past version. #290 Try with original package.json. I've successfully installed it without any issue.

chihab commented 8 years ago

Ok, thanks @milocosmopolitan. However, the version on Packagist is not up to date. So anyone who follows the Getting Started installation steps would get the same issue.

jadjoubran commented 8 years ago

Hi @chihab thanks for opening an issue

I wasn't able to reproduce your issue with a fresh install.. did you run composer install with :3.3.0-beta or were you upgrading?

chihab commented 8 years ago

Hi @jadjoubran ,

When installing from composer it seems to be downloading version 3.2.0

> composer clear-cache
> composer create-project jadjoubran/laravel5-angular-material-starter --prefer-dist
Installing jadjoubran/laravel5-angular-material-starter (3.2.0)
  - Installing jadjoubran/laravel5-angular-material-starter (3.2.0)
    Downloading: 100%         
  - ....
> cd laravel5-angular-material-starter
> grep elixir package.json
>
    "laravel-elixir-karma": "^0.2.2",
    "laravel-elixir": "^4.2.1",
    "laravel-elixir-livereload": "^1.1.1",

However, on packagist: https://packagist.org/packages/jadjoubran/laravel5-angular-material-starter, the current version seems to be:

I don't really understand why composer gets me the 3.2.0 version.

The 3.2.0 is the one that has the dependency version issue. (Should I modify issue title ?).

Thanks.

milocosmopolitan commented 8 years ago

@chihab try to install 3.3.0-beta with this command composer create-project jadjoubran/laravel5-angular-material-starter=3.3.0-beta --prefer-dist

I believe your command is for installing master branch composer create-project jadjoubran/laravel5-angular-material-starter --prefer-dist

chihab commented 8 years ago

Thanks @milocosmopolitan.

I suppose the packagist "default version" should be updated, everyone running the Getting Started installation steps should see the issue.

flick36 commented 8 years ago

@chihab the packagist use the latest stable version, as you can read, the 3.3.0-beta is tagged as BETA

milocosmopolitan commented 8 years ago

@chihab the newest version is still at beta stage. Packagist "default version" should be last stable version, to avoid issues being created when this project is being used. Unless you wish you test beta version to provide developers feedback or pull-request, you should try out last stable version first.

jadjoubran commented 8 years ago

Yes indeed, exactly what @milocosmopolitan and @flick36 said!

So the docs that you're seeing right now are up to date with the default version on packagist (stable)

But btw npm install is working perfectly fine on the stable release, if you think there's an issue please let me know

chihab commented 8 years ago

The npm install doesn't work on stable release, hence the issue :) Here are the exact commands I've been running. Please tell me if something is wrong on what I did.

> composer clear-cache
> composer create-project jadjoubran/laravel5-angular-material-starter --prefer-dist
Installing jadjoubran/laravel5-angular-material-starter (3.2.0)
  - Installing jadjoubran/laravel5-angular-material-starter (3.2.0)
    Downloading: 100%         
  - ....
> cd laravel5-angular-material-starter
> grep elixir package.json
>
    "laravel-elixir-karma": "^0.2.2",
    "laravel-elixir": "^4.2.1",
    "laravel-elixir-livereload": "^1.1.1",
> npm install
npm ERR! peerinvalid The package laravel-elixir does not satisfy its siblings' peerDependencies requirements!
npm ERR! peerinvalid Peer laravel-elixir-livereload@1.1.6 wants laravel-elixir@^5.0

npm ERR! System Darwin 14.5.0
npm ERR! command "/usr/local/Cellar/node5/5.11.1/bin/node" "/usr/local/bin/npm" "install"
npm ERR! cwd /private/tmp/laravel5-angular-material-starter
npm ERR! node -v v5.11.1
npm ERR! npm -v 2.0.0-alpha-5
npm ERR! code EPEERINVALID
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /private/tmp/laravel5-angular-material-starter/npm-debug.log
npm ERR! not ok code 0

Could someone try and tell me if you get the same issue ? Thanks.

jadjoubran commented 8 years ago

you can just satisfy the peerDependency by just bumping laravel elixir to 5.0.0 I didn't have this issue in the morning, not sure why it's happening for you Let me know if it works!

chihab commented 8 years ago

@jadjoubran,

This is exactly what I did and reported on the issue description :)

Again, if it doesn't work for me, it won't for others, unless Î am doing something wrong.

Should the package.json be fixed on the stable release ?

jadjoubran commented 8 years ago

oh that's right Yes it will probably break for others I will push a fix soon, thanks!

jadjoubran commented 8 years ago

Fixed in 3.2.1 👍

sombodi commented 7 years ago

Hi, i would like to comment that same thing just happened to me, except this time it was with eslint@3.0.2 which wants elixir<6.0.0-0 since we are all the way to 6.0.0-11 it won't match.. so I had to change package.json to "laravel-elixir-eslint": "beta" which solved it

npm ERR! peerinvalid The package laravel-elixir@6.0.0-14 does not satisfy its siblings' peerDependencies requirements! npm ERR! peerinvalid Peer laravel-elixir-eslint@3.0.2 wants laravel-elixir@>=3.0.0-0 <6.0.0-0

akinolu52 commented 7 years ago

Hi, am having this issue..

npm WARN EPEERINVALID laravel-elixir-eslint@3.0.2 requires a peer of laravel-elixir@>=3.0.0-0 <6.0.0-0 but none was installed.

package.json

"laravel-elixir": "^6.0.0-9", "laravel-elixir-eslint": "^3.0.0", "laravel-elixir-webpack-official": "^1.0.2",

i need help!

i tried this: npm install laravel-elixir-eslint --save-dev from https://www.npmjs.com/package/laravel-elixir-eslint but still not working...

xorenio commented 7 years ago

Good morning,

Im also having the same issue :(

npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.0.0 (node_modules/chokidar/node_modules/fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.0.17: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"}) npm WARN laravel-elixir-eslint@3.0.2 requires a peer of laravel-elixir@>=3.0.0-0 <6.0.0-0 but none was installed.

akinolu52 commented 7 years ago

i fixed the issue with this:

npm install laravel-elixir-eslint@beta --save-dev

akinolu52 commented 7 years ago

as for the warning i think it due to the fact that your OS(linx) is different from the expected OS but i dont think it is that neccessary

xorenio commented 7 years ago

Thanks for the fast reply and that did infact fix my issue but Im still getting this error in page ?? image

akinolu52 commented 7 years ago

i really cant see the error on the picture u post right now.. it better if u can copy and paste this error as a copy

am so happy to help.. :100:

sachin-rajput commented 7 years ago

try updating the gcc, if it is a linux box or dist. worked for me.