avanzu / AdminThemeBundle

Admin Theme based on the AdminLTE Template for easy integration into symfony
MIT License
280 stars 148 forks source link

bower Errors invalid-meta during fetching vendors #240

Closed lukasz-yasecure closed 6 years ago

lukasz-yasecure commented 6 years ago

Hey. After using command:

php bin/console avanzu:admin:fetch-vendor

I get few Errors which I don't know how to handle:

1)

[Error] bower pickadate# invalid-meta for:/tmp/s3test/bower/88e9dc170fe23ea1efbcf95aa85c8e9d-28107-fL8QRd/bower.json [Error] bower pickadate# invalid-meta The "main" field has to contain only 1 file per filetype; found multiple .js files: ["lib/picker.js","lib/picker.date.js","lib/picker.time.js"] bower pickadate#* invalid-meta The "main" field has to contain only 1 file per filetype; found multiple .css files: ["lib/themes/default.css","lib/themes/default.date.css","lib/themes/default.time.css"]

2)

[Error] bower ionicons# invalid-meta for:/tmp/s3test/bower/058ec18616846dd8772e15a7a0750818-28107-XarfT1/bower.json [Error] bower ionicons# invalid-meta The "name" is recommended to be lowercase, can contain digits, dots, dashes bower ionicons# invalid-meta The "main" field cannot contain globs (example: ".js")

3)

[Error] bower adminlte#~2.3.0 invalid-meta for:/tmp/s3test/bower/b3525921156bfa51d142854276a74fc9-28107-S0R7Dz/bower.json bower adminlte#~2.3.0 invalid-meta The "name" is recommended to be lowercase, can contain digits, dots, dashes

4)

[Error] bower ionicons#* mismatch Version declared in the json (2.0.0) is different than the resolved one (2.0.1)

What should I do with that?

Debug info

Component Version
Symfony version 3.3.10
AdminThemeBundle 1.3.10
Operating System Debian 3.16.36

2018-05-10_11h57_59 2018-05-10_11h58_21

|

xmontero commented 6 years ago

I only get the error about the ionicons...

uglifycss: unable to process "/files/www/hellotrip/repos/pre/2018-05-11_10.13.29/dislodge-galvanize/web/bundles/avanzuadmintheme/vendor/ionicons/css/ionicons.min.css"
        Error: ENOENT: no such file or directory, open '/files/www/hellotrip/repos/pre/2018-05-11_10.13.29/dislodge-galvanize/web/bundles/avanzuadmintheme/vendor/ionicons/css/ionicons.min.css'

I'm going to see if locking the versions to an older one works.

xmontero commented 6 years ago

Okey, I think it's the following:

According to this: https://github.com/ionic-team/ionicons/releases?after=v4.0.0-10 (press "show 8 newer tags"), the ionicons project jumped from "stable 2.0.1" into "stable 4.0.0" directly.

image

There were really versions of 4.0.0-1, 4.0.0-2 etc, but they were considered non-stable by bower.

I may know this because I yesterday deployed to avanzu/AdminThemeBundle to production and it's ionicons version is:

$ cd /my/nice/project
$ cd vendor/avanzu/admin-theme-bundle/Resources/public/vendor/ionicons
$ cat cat .bower.json

and I see this line:

  "version": "2.0.1",

instead, deploying today it says:

 "version": "4.0.0",

On the other hand it happens that although in github they've been releasing 4.0.0-xx versions, the final 4.0.0 has been tagged 17 hours ago, which is what it breaks our compatibility.

image

So, I'm going to lock down the ionicons into 2.0.1 which was the latest known to soundly work with avanzu/AdminThemeBundle without errors.

I'll fix it on top of 1.3.10, which is my version. The same fix could be ported to 2.0.x I guess.

Will try, and will tell. If it works I'll do a PR.

xmontero commented 6 years ago

Pull-Requested here https://github.com/avanzu/AdminThemeBundle/pull/245

Please mergers, upgrade tag to v1.3.11

While it's not accepted, you can workaround in my fork doing this:

In repositories add:

"repositories": [
    {
        "type": "vcs",
        "url": "https://github.com/xmontero/AdminThemeBundle.git"
    }
]

in the require section, require the dev branch named issue240

"require": [
    "avanzu/admin-theme-bundle": "dev-issue240"
]
shakaran commented 6 years ago

Probably this will be need to backport in 2.x branch (aka master) unless that ionicons 4.x would be supported in 2.x. Closing this issue. Thanks for the report and the PR