Okay
  Public Ticket #1171011
grunt bower error
Closed

Comments

  • Alberto started the conversation

    Hi,
    I installed the Groovy theme dependencies running npm install in the folder of the project but when I run grunt dev this error appear in terminal: 

    Fatal error: Path must be a string. Received [ '/var/folders/90/g8vh90p11198pb554n7rz_9m0000gn/T/Alberto/bower/jquery-14894-sjPUmB',

      [Function: _cleanupCallback] ]

    Every package is installed correctly.

    These are the versions of my environment
    bower --version: 1.8.0
    grunt --version: grunt-cli v1.2.0 grunt v.4.5
    npm -v: 3.10.10
    node -v: 6.10.4

    I made a try running bower install without grunt and the error above disappear but the angular App is broken...

    The urls of the app are like these:
    http://localhost:8080/#!/dashboard#%2Fartist-list
    http://localhost:8080/#!/dashboard#%2Fgenres
    http://localhost:8080/#!/dashboard#%2Fpages%2Fsignin

    Clicking on any element on the page the url change but the layout is alway the dashboard (without the "artist" section) and in the console appear an Angular error (see attachment).

    Thank you for the support!

    Attached files:  Schermata 2017-05-15 alle 12.21.36.png

  •  13
    Joao replied

    Hello,

    Can you tell which verison of angular are you using? the theme supports untill version 1.5 as in 1.6 some API's where removed, including this one.

    Best regards

  •  13
    Joao replied

    To fix this the .success method needs to be replaced with ".then"

    http://stackoverflow.com/questions/41169385/http-get-success-is-not-a-function

  • Alberto replied

    Hi,
    the angular version is the one that is installed running before npm install and then bower install.

    I fixed the error in these ways:
     - in bower.js modifying "angular:^1.5.3" with "angular": "~1.5.3" and adding   "resolutions": { "angular": "~1.5.3"}

    - in package.json modifying "grunt-contrib-jshint": "~0.10.0" in "grunt-contrib-jshint": "~0.12.0"

    However I've to running manually bower install.

  •  13
    Joao replied

    Hello,

    Yes I still havent had time to upgrade the theme to 1.6. The thing its that there are many API changes in 1.6 and will take me some time to fix it. Thanks for the info

    For this one however I think you can use 1.6 if you change the .success to .then as mentioned in the message bellow.

    Best regards
    Joao Garin