bower / bower

A package manager for the web
bower.io
MIT License
14.99k stars 1.85k forks source link

EMALFORMED Failed to read .bower.json #2622

Closed podshivalovdv closed 1 year ago

podshivalovdv commented 1 year ago

Hi, I'm having a strange issue with Bower, we run it in docker container with ubuntu and mount local directories with source code and dependencies into the container as /var/www/xxx. One one laptop with MacOS result of bower install is

bower                       EMALFORMED Failed to read /var/www/xxx/vendor/gildorwang-moment-precise-range/.bower.json

Additional error details
Unexpected end of JSON input

When I look at the /var/www/xxx/vendor/gildorwang-moment-precise-range/.bower.json in the container - it is empty. The name of the package is different every time. On another laptop with Windows+WSL everything works.

I couldn't find anything similar to that issue on the Internet unfortunately. If someone has any idea - please help.

Thanks!

In bower,json for the project we have

{
  "name": "xxx",
  "private": true,
  "version": "0.0.1",
  "_comment": "xxx",
  "devDependencies": {
    "angular": "1.2.9",
    "angular-resource": "1.2.9",
    "angular-animate": "1.2.9",
    "angular-mocks": "1.2.9",
    "angular-translate": "~2.8.1",
    "angular-bootstrap": "~0.11.0",
    "angular-ui-router": "~0.2.7",
    "angular-loading-bar": "~0.7.1",
    "a0-angular-storage": "^0.0.9",
    "angular-chart.js": "~0.5.3",
    "angular-file-upload": "2.5.0",
    "bootstrap-sass": "^3.0.0",
    "jquery": "2.1.3",
    "font-awesome": "~4.4.0",
    "moment": "~2.9.0",
    "angular-bootstrap-datetimepicker": "0.3.12",
    "gildorwang-moment-precise-range": "1.0.0",
    "angular-translate-loader-partial": "~2.8.1",
    "angular-ui-select": "^0.19.8",
    "angular-sanitize": "1.2.9",
    "angular-filter": "^0.5.17"
  },
  "dependencies": {
    "bootstrap": "3.0.0"
  },
  "resolutions": {
    "angular": "1.2.9"
  }
}
podshivalovdv commented 1 year ago

Nevermind, it was a problem with the docker image.