composer-asset-plugin and components not detected correctly

PHP Tools [?] extends Visual Studio with set of advanced features to work more efficiently with PHP code.

composer-asset-plugin and components not detected correctly

Postby urosg » May 19th, 2018, 4:12 am

Hi,

I recently updated VS2017 to latest version (15.7.1) and noticed that with a new project there were missing dependencies detected which were actually not missing.

I suspected that it has to do with the VS version but actually is the PHPtools.

I had now tested with old versions I had still on my disk from previous installations and tried with 1.24.10015 which works OK.

Then I downloaded 1.26.10601 which breaks the correct support.
Version 1.27.10773 still broken.
Version 1.28.10839 still broken.

Now looking at the changelog I suspect this got broken in version 1.26.

Please check and fix as soon as possible.

Thank you!
urosg
 
Posts: 43
Joined: February 24th, 2016, 2:05 am

Re: composer-asset-plugin and components not detected correc

Postby urosg » May 19th, 2018, 4:18 am

I now also tested with 1.25.10474 version and in this version it works. So in 1.26 it breaks.

Please see http://support.devsense.com/viewtopic.php?f=21&t=1748&p=7896&hilit=composer+bower#p7896 where I already reported the same problem and you fixed it / this was in 1.19.8685 version.
urosg
 
Posts: 43
Joined: February 24th, 2016, 2:05 am

Re: composer-asset-plugin and components not detected correc

Postby Miloslav Beno » May 21st, 2018, 8:58 am

Hello!

Thanks for the feedback. Let me check this and get back to you asap.

Thanks!
Miloslav Beno │ DEVSENSE s.r.o. │ @miloslavbenomiloslav@devsense.com
User avatar
Miloslav Beno
 
Posts: 1212
Joined: January 7th, 2012, 8:36 pm

Re: composer-asset-plugin and components not detected correc

Postby Miloslav Beno » May 21st, 2018, 11:00 am

Hello,

Could you please tell me how to reproduce it?

I've created project with yii2 framework and I can see all the composer packages:

yii - composer.png


Thanks!
You do not have the required permissions to view the files attached to this post.
Miloslav Beno │ DEVSENSE s.r.o. │ @miloslavbenomiloslav@devsense.com
User avatar
Miloslav Beno
 
Posts: 1212
Joined: January 7th, 2012, 8:36 pm

Re: composer-asset-plugin and components not detected correc

Postby urosg » May 22nd, 2018, 7:31 am

Create new project / directory:

use the composer.json:
Code: Select all
{
  "name": "test-project",
  "description": "TEST Project",
  "license": "proprietary",
  "require": {
    "php": ">=5.4.0",
    "yiisoft/yii2": ">=2.0",
    "yiisoft/yii2-bootstrap": ">=2.0",
    "yiisoft/yii2-swiftmailer": ">=2.0",
    "yiisoft/yii2-jui": ">=2.0",
    "fxp/composer-asset-plugin": "~1.0"
  },
  "suggest": {
    "bower-asset/flexslider": "*"

  },
  "require-dev": {
    "yiisoft/yii2-debug": "*",
    "yiisoft/yii2-gii": "*",
    "yiisoft/yii2-faker": "*"
  },
  "config": {
    "fxp-asset": {
      "installer-paths": {
        "bower-asset-library": "vendor/bower",
        "npm-asset-library": "vendor/npm"
      }
    }
  }
}


in command line first run:
Code: Select all
php composer.phar global require "fxp/composer-asset-plugin:*"


then run
Code: Select all
php composer.phar update


then create new project from existing code and you have missing dependencies shown.
urosg
 
Posts: 43
Joined: February 24th, 2016, 2:05 am

Re: composer-asset-plugin and components not detected correc

Postby urosg » May 22nd, 2018, 8:57 am

This goes for old projects, with "brand new" projects the composer has a new repository for bower/npm assets and with that this dependency problems don't exist.
urosg
 
Posts: 43
Joined: February 24th, 2016, 2:05 am

Re: composer-asset-plugin and components not detected correc

Postby Miloslav Beno » May 22nd, 2018, 3:24 pm

Hi,

I see, thanks for the steps!

I will not be able to take a look at it this week, because of a business trip. But once I'm back I'm on it.

Thanks again!
Miloslav Beno │ DEVSENSE s.r.o. │ @miloslavbenomiloslav@devsense.com
User avatar
Miloslav Beno
 
Posts: 1212
Joined: January 7th, 2012, 8:36 pm

Re: composer-asset-plugin and components not detected correc

Postby urosg » June 1st, 2018, 5:53 am

Hi,

did you perhaps get around to checking this issue?

Thanks!
urosg
 
Posts: 43
Joined: February 24th, 2016, 2:05 am


Return to PHP Tools

Who is online

Users browsing this forum: No registered users and 6 guests

cron

User Control Panel

Login

Who is online

In total there are 6 users online :: 0 registered, 0 hidden and 6 guests (based on users active over the past 5 minutes)
Most users ever online was 62 on January 7th, 2012, 10:54 pm

Users browsing this forum: No registered users and 6 guests
Phalanger