Some days I'm having a problem with my composer that does not make much sense (it does not have a default / default logic, the errors are almost random), so I'm not able to solve it, what happens is as follows
I have a mini framework, and I'm updating it as I need the resources, the steps are as follows:
1 - I access the framework.
2 - I push on github.
3 - I update the packagist.
4 - I update the composer
in the project that I'm using it (This step is the problem)
If I indicate to update only the dependency in question, it works correctly, but if I give the command 'composer update'
it removes some dependencies (sometimes all) and installs again, and it does not update autoloader
if the 'vendor/composer'
folder is not deleted, and to complicate it, this process of the update command is taking more than 20 minutes, causing several alerts like this.
exceeded the timeout of 300 seconds.
But this update of the dependencies are not consistent, that is, they are not the same ones that always update, each time is different.
List of dependencies requesting update without having been modified more often:
PHPDocumentor (This is the one that takes the most time and the updates are inconsistent)
Synfony
Doctrine
Guzzlehttp
robinherbots / jquery.inputmask (This updates 100% of the time and takes a long time)
cocur / slugify
components / jquery
zendframework
And when each of these dependencies have other dependencies, they are also 100% up-to-date, taking a long time to complete, failing to alert and / or not completing.
And the second problem is the issue of updating github/gitlab
within composer
.
autoload
file is updated to include some vendor
new, and is given update command, it does the whole process, indicates success, but does not include the new composer.json
in namespace
, so that this step I need to delete the folder namespace
give the command autoload
and wait + - 20 minutes (has already reached more than 40) to update everything and I can go back to work.
Additional information:
Test: Ubuntu OS 16.4
Production: Debian OS 7.
PHP: 7. GIT: Last version.
Permissions for the 777 folders.
IDE: Netbeans 8.2
Broadband Internet 50MB Stable.
composer.json
{
"name": "contabil app center",
"description": "",
"type": "Biblioteca",
"license": "BSD-3",
"version": "1.0",
"authors": [
{
"name": "Gabriel",
"email": ""
}
],
"minimum-stability": "dev",
"require": {
"php": ">=5.3.8",
"guzzlehttp/guzzle": "~6.0",
"slim/pdo": "~1.9",
"cocur/slugify": "dev-master",
"components/jquery": "~3.2.1",
"wixel/gump": "dev-master",
"phpmailer/phpmailer": "^5.2",
"easy-cont/vidb": "dev-master",
"phpdocumentor/phpdocumentor": "2.*"
},
"autoload": {
"psr-4": {
"appModel\": "model/app",
"appView\": "view/app",
"appController\": "controller/app",
"appFinancialRestatement\":"model/app/calculations/financial-calculations",
"appFinancialIndices\":"model/app/calculations/financial-calculations",
"appDebitWorksheet\":"model/app/calculations/financial-calculations",
"appFIPE\":"model/app/fipe",
"phpToJs\":"interactors",
"siteModel\": "model/site",
"indexView\": "view/site",
"siteController\": "controller/site"
}
}
}