Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Composer is not working in vagrant synced folders of a virtual machine #9627

Closed
webprogrammierer opened this issue Jan 18, 2021 · 57 comments
Closed
Labels
Milestone

Comments

@webprogrammierer
Copy link

webprogrammierer commented Jan 18, 2021

Solution and details

If you experience failed to open stream: No such file or directory or Plugin initialization failed or class not found type of issue, and are using VirtualBox / Vagrant, this is caused by the VirtualBox filesystem being buggy and not allowing access to the files right after they have been written (https://www.virtualbox.org/ticket/8761).

The workaround we implemented is the following:

If Composer:

  • runs as user vagrant
  • or Composer runs on a Linux machine where lsmod lists vboxguest (virtualbox guest additions)
  • or you set the COMPOSER_RUNTIME_ENV environment variable to virtualbox

then Composer does very short sleep() calls right before plugins are initialized to give the filesystem some time to properly acknowledge the files are there, so that the plugins can be initialized.



Initial issue:

  [ErrorException]
  md5_file(./coffee.api.php): failed to open stream: No such file or directory

This error is only an example for a lot of different error messages of Composer 2 when using it in the Virtual Machine (Drupal VM, drupalvm.com).

Composer has massive problem with the files in the shared folders (virtualbox).

Is there any new dev version that solves the problems? The problem exists for many years.

@stof
Copy link
Contributor

stof commented Jan 19, 2021

I don't think composer can do anything here. That's an issue coming from the virtualbox shared folder filesystem, where files are reported as non-existent in PHP filesystem APIs. This issue has been reported to virtualbox since years AFAIK but does not seem to have been fixed.
And the faster composer becomes, the more likely it is to trigger this virtualbox issue (which seem to appear when trying to read from the filesystem too soon after writing to it).

@webprogrammierer
Copy link
Author

I tried to solve the problem and spendet hours on it. But it is still unsolved.

I need a solution where composer is running without error messages. Can you help?
How to develop with composer if it is not working?
And Drupal 9 can NOT be used without composer. So we need a solution urgently.

@stof
Copy link
Contributor

stof commented Jan 19, 2021

@webprogrammierer put your vendor folder outside the virtualbox shared folders. That's the workaround I know of (I'm not using virtualbox myself).

@webprogrammierer
Copy link
Author

Maybe this helps. But within the Drupal core and within Drupal modules there are also composer dependencies. And I can not move the core and module outside the shared folders.

Any further solutions?

@webprogrammierer
Copy link
Author

There are a lot of (tons of) error messages like this one:

  [ErrorException]
  opendir(./src/Asm89): failed to open dir: Operation not permitted

WE NEED a solution.

@Seldaek Seldaek added this to the 2.0 milestone Jan 26, 2021
@Seldaek Seldaek added the Bug label Jan 26, 2021
@Seldaek
Copy link
Member

Seldaek commented Jan 26, 2021

For some context about this issue, and why it's not fixed yet:

Now I think it may be possible to provide a workaround in Composer by waiting until files are available before proceeding, but I don't really want to install virtualbox to debug this myself tbh. I'd be happy if someone with the problem could work on this.

If we could detect that we run in virtualbox somehow (maybe check for /sbin/mount.vboxsf presence if that's reliable?) and then either do a short sleep after unzip, or probably better/more future proof would be to poll for files within the new package dir, and sleep until they are available/readable without errors. I hope that would "fix" it.

Tagging @rpkamp @bilogic @frickenate @ramsey @ramondelafuente @amacsmith here as all of you experienced this in other linked issues and may be interested in helping fix this.

@bilogic
Copy link
Contributor

bilogic commented Jan 26, 2021

@Seldaek thanks, happy to help. But right now, I can't remember how to replicate the issue with composer. What I do know is that:

  1. My best solution is found here Suspected cache issue with conveyor Jeroen-G/laravel-packager#101 (comment), it is basically a retry-until-succeed loop
  2. For reasons unknown to me, some PHP can work fine, but others consistently run into issues. My point here is that, there could be an even better solution than my best solution
  3. Will attempt to create a fix for composer once I can replicate the issue

@webprogrammierer
Copy link
Author

You can fix the problem?

@phpguru
Copy link

phpguru commented Jan 27, 2021

I am experiencing what appears to be similar situation using Docker for Windows. If I run composer dump-autoload on the Windows host machine, the resulting rendered autoload_classmap and autoload_static have about 6,000 entries; if I enter the Linux docker container and run composer dump-autoload on the Linux guest, I have about 5,500 entries. It is reproduceable. I've tried different volume mounting methods within my docker-compose.yml. The project is Laravel, and the issue pertains to migrations and seeds folder for a very large database (1,500+ PHP classes to map). I have not been able to identify any other workaround, other than to install composer on the host and/or not use Docker. A few more details here.

@webprogrammierer
Copy link
Author

So the problem is Composer! Or not?

@stof
Copy link
Contributor

stof commented Jan 28, 2021

@webprogrammierer no. the issue is with the shared filesystem of the VM (IIRC, Docker for Windows relies on a VM running Linux and so involves such shared folder).

@phpguru try to write a simple PHP script using \FilesystemIterator to iterate over the files in your big folders and count them. I suspect that you might face the same issue than the one faced by composer (but maybe there's a timing condition involved, as it is not clear whether some files are never synced to the VM or whether they only have a delay before appearing)

@rpkamp
Copy link

rpkamp commented Feb 1, 2021

This is not a problem in Composer and as such I don't believe it should be solved in Composer.

What I'm using right now and is working fine for me, is the workaround described here: #9361 (comment)

@webprogrammierer
Copy link
Author

I can not find the workaround.

Could you copy and paste the workaround details here?

@webprogrammierer
Copy link
Author

Could you copy and paste the workaround details here?

@rpkamp
Copy link

rpkamp commented Feb 12, 2021

Create a file /usr/local/bin/zip in the VM with the following content:

#!/bin/sh

/usr/bin/unzip "\$@"
sleep 0.2

It hijacks zip on your system so that every time composer executes zip it will execute this script rather than the actual zip program. This script will then call the actual zip program and then wait for 200ms after zip finished so that hopefully in that time changes have been really synced to disk.
You can of course play with the 0.2 to see if any other values works better. 0.1 did not work for me, but that probably also depends on disk speed (I do have an NVMe SSD, but it's a few years old, so I'm not sure how that would stack up against a more modern SSD).

@tomaszstrojny
Copy link

According to @rpkamp I used the workaround but had to change the script a little for Laravel Homestead.

I had to create a script /usr/local/bin/unzip with such content:

#!/bin/sh

/usr/bin/unzip "$@"
sleep 0.2

And remember you have to give it chmod +x /usr/local/bin/unzip.

@kalnode
Copy link

kalnode commented Feb 28, 2021

@tomaszstrojny's solution above worked for me (Laravel Homestead project, php7.4, virtualbox and vagrant)

Here it is summarized with more details, for those who need it:

  1. Create a script named unzip, somewhere. May as well be in the root of your project (where composer.json lives), with:
#!/bin/sh

/usr/bin/unzip "$@"
sleep 0.2
  1. Enter the Vagrant instance: vagrant ssh

  2. Copy the script to usr/local/bin (of the Vagrant instance):
    sudo cp /path/to/unzip /usr/local/bin

  3. Allow the file to be executeable, with:
    sudo chmod +x /usr/local/bin/unzip

  4. Try running composer install again, in your site root (still in vagrant ssh)

@Seldaek
Copy link
Member

Seldaek commented Mar 9, 2021

Do most/all of you use vagrant as the username within the VM? I'm thinking we could conditionally sleep in a few places (like before plugin initialization, and after all packages are installed) if the user is vagrant, that'd allow it to be smarter than sleeping after every unzip which slows things down quite a bit if you have lots of packages to install.

@inverse
Copy link

inverse commented Mar 10, 2021

@Seldaek that's the default but I can imagine some people overwrite it. Would making it customisable through an env var be acceptable? Could be a nice workaround for people with this limitation.

@Seldaek
Copy link
Member

Seldaek commented Mar 10, 2021

Ok it should detect vagrant username or COMPOSER_RUNTIME_ENV env var set to virtualbox, and do a few sleeps that are hopefully strategically-enough placed that they fix the issue without causing too much slowdown.

Please try it with composer self-update --snapshot and let me know if it pans out.

@viliusle
Copy link

I had same issue, and fix with sleep was not helpful. Are you sure this problem should be fixed with sleep?

p.s. I personally fixed it by moving composer step to outside of Vagrant.

@maganius
Copy link

maganius commented Mar 17, 2021

i'm using Virtualbox and have the same error:

Installing dependencies from lock file (including require-dev)
Package operations: 1 install, 86 updates, 0 removals
  - Installing composer/package-versions-deprecated (1.11.99.1): Extracting archive
Plugin initialization failed (include(/media/sf_VirtualBox/web/vendor/composer/package-versions-deprecated/src/PackageVersions/Installer.php): failed to open stream: No such file or directory), uninstalling plugin
  - Removing composer/package-versions-deprecated (1.11.99.1)
    Install of composer/package-versions-deprecated failed


  [ErrorException]
  include(/media/sf_VirtualBox/web/vendor/composer/package-versions-deprecated/src/PackageVersions/Installer.php): failed to open stream: No such file or directory

it's my composer -vvv

Writing /home/hansz/.cache/composer/files/backpack/crud/67cb7c3366138e2a67c524f03c58498f11394307.zip into cache from /media/sf_VirtualBox/web/vendor/composer/tmp-8cef65d02275a54ccdc0e78f2925ee24
  - Installing composer/package-versions-deprecated (1.11.99.1): Extracting archive
Executing command (CWD): rm -rf '/media/sf_VirtualBox/web/vendor/composer/package-versions-deprecated/src'
Executing async command (CWD): unzip -qq  '/media/sf_VirtualBox/web/vendor/composer/tmp-2e0c908d81b1ccfb69eeb05979309245' -d '/media/sf_VirtualBox/web/vendor/composer/2a08521a'
Executing command (CWD): rm -rf '/media/sf_VirtualBox/web/vendor/composer/package-versions-deprecated'
Executing async command (CWD): rm -rf '/media/sf_VirtualBox/web/vendor/composer/2a08521a'
Plugin initialization failed (include(/media/sf_VirtualBox/web/vendor/composer/package-versions-deprecated/src/PackageVersions/Installer.php): failed to open stream: No such file or directory), uninstalling plugin
  - Removing composer/package-versions-deprecated (1.11.99.1)
Executing async command (CWD): rm -rf '/media/sf_VirtualBox/web/vendor/composer/package-versions-deprecated'
    Install of composer/package-versions-deprecated failed
Downloading https://packagist.org/downloads/
[201] https://packagist.org/downloads/


  [ErrorException]
  include(/media/sf_VirtualBox/web/vendor/composer/package-versions-deprecated/src/PackageVersions/Installer.php): failed to open stream: No such file or directory


Exception trace:
 () at phar:///usr/local/bin/composer/vendor/composer/ClassLoader.php:480
 Composer\Util\ErrorHandler::handle() at phar:///usr/local/bin/composer/vendor/composer/ClassLoader.php:480
 include() at phar:///usr/local/bin/composer/vendor/composer/ClassLoader.php:480
 Composer\Autoload\includeFile() at phar:///usr/local/bin/composer/vendor/composer/ClassLoader.php:346
 Composer\Autoload\ClassLoader->loadClass() at n/a:n/a
 spl_autoload_call() at n/a:n/a
 class_exists() at phar:///usr/local/bin/composer/src/Composer/Plugin/PluginManager.php:228
 Composer\Plugin\PluginManager->registerPackage() at phar:///usr/local/bin/composer/src/Composer/Installer/PluginInstaller.php:79
 Composer\Installer\PluginInstaller->Composer\Installer\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/FulfilledPromise.php:20
 React\Promise\FulfilledPromise->then() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:74
 React\Promise\Deferred->React\Promise\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:166
 React\Promise\Deferred->processQueue() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:95
 React\Promise\Deferred->resolve() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/FulfilledPromise.php:20
 React\Promise\FulfilledPromise->then() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:76
 React\Promise\Deferred->React\Promise\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:166
 React\Promise\Deferred->processQueue() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:95
 React\Promise\Deferred->resolve() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/FulfilledPromise.php:20
 React\Promise\FulfilledPromise->then() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:74
 React\Promise\Deferred->React\Promise\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:166
 React\Promise\Deferred->processQueue() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:95
 React\Promise\Deferred->resolve() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/FulfilledPromise.php:20
 React\Promise\FulfilledPromise->then() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:76
 React\Promise\Deferred->React\Promise\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:166
 React\Promise\Deferred->processQueue() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:95
 React\Promise\Deferred->resolve() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/FulfilledPromise.php:20
 React\Promise\FulfilledPromise->then() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:76
 React\Promise\Deferred->React\Promise\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:166
 React\Promise\Deferred->processQueue() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:95
 React\Promise\Deferred->resolve() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/FulfilledPromise.php:20
 React\Promise\FulfilledPromise->then() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:76
 React\Promise\Deferred->React\Promise\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:166
 React\Promise\Deferred->processQueue() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:95
 React\Promise\Deferred->resolve() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Promise.php:42
 React\Promise\Promise->React\Promise\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/src/Composer/Util/ProcessExecutor.php:296
 Composer\Util\ProcessExecutor->countActiveJobs() at phar:///usr/local/bin/composer/src/Composer/Util/Loop.php:96
 Composer\Util\Loop->wait() at phar:///usr/local/bin/composer/src/Composer/Installer/InstallationManager.php:457
 Composer\Installer\InstallationManager->waitOnPromises() at phar:///usr/local/bin/composer/src/Composer/Installer/InstallationManager.php:441
 Composer\Installer\InstallationManager->executeBatch() at phar:///usr/local/bin/composer/src/Composer/Installer/InstallationManager.php:368
 Composer\Installer\InstallationManager->downloadAndExecuteBatch() at phar:///usr/local/bin/composer/src/Composer/Installer/InstallationManager.php:267
 Composer\Installer\InstallationManager->execute() at phar:///usr/local/bin/composer/src/Composer/Installer.php:697
 Composer\Installer->doInstall() at phar:///usr/local/bin/composer/src/Composer/Installer.php:534
 Composer\Installer->doUpdate() at phar:///usr/local/bin/composer/src/Composer/Installer.php:247
 Composer\Installer->run() at phar:///usr/local/bin/composer/src/Composer/Command/UpdateCommand.php:236
 Composer\Command\UpdateCommand->execute() at phar:///usr/local/bin/composer/vendor/symfony/console/Command/Command.php:245
 Symfony\Component\Console\Command\Command->run() at phar:///usr/local/bin/composer/vendor/symfony/console/Application.php:835
 Symfony\Component\Console\Application->doRunCommand() at phar:///usr/local/bin/composer/vendor/symfony/console/Application.php:185
 Symfony\Component\Console\Application->doRun() at phar:///usr/local/bin/composer/src/Composer/Console/Application.php:310
 Composer\Console\Application->doRun() at phar:///usr/local/bin/composer/vendor/symfony/console/Application.php:117
 Symfony\Component\Console\Application->run() at phar:///usr/local/bin/composer/src/Composer/Console/Application.php:122
 Composer\Console\Application->run() at phar:///usr/local/bin/composer/bin/composer:63
 require() at /usr/local/bin/composer:25

@Seldaek
Copy link
Member

Seldaek commented Mar 18, 2021

@maganius so you run composer inside virtualbox? I guess by detecting virtualbox guest additions it might be possible to act for all vbox users and not only vagrant. As far as I know you need the guest additions to be able to do vboxfs shared directories, so that's probably a good indicator? lsmod | grep vboxguest runs quick enough that it doesn't hurt to run it once per Composer run I guess.

@emreylmaz
Copy link

@LanmanGroup thanks! Sorry I completely messed that up and forgot the install step for plugins, only did it the sleep on update. Anyway please try again with latest composer self-update --snapshot, if that really doesn't fix it then maybe I'll give up.

This answer solved my problem thank you.

@marcelhoogantink
Copy link

marcelhoogantink commented Mar 22, 2021

Had the same issue with virtual-box and vagrant, but after activating nfs in homestead.yaml, it was fixed:

folders:
- map: ~/code/new-site
to: /home/vagrant/code/new-site
type: "nfs"
- map: ~/code/second-site
to: /home/vagrant/code/second-site
type: "nfs"

@j-grucza
Copy link

Ok it should detect vagrant username or COMPOSER_RUNTIME_ENV env var set to vagrant, and do a few sleeps that are hopefully strategically-enough placed that they fix the issue without causing too much slowdown.

Please try it with composer self-update --snapshot and let me know if it pans out.

@Seldaek Thank you so much for this! I was having the same issues with composer failing in vagrant (installing Drupal 9 & various modules). A couple weeks ago I thought I had gotten it to work with the hack to add a sleep to unzip, but yesterday I wiped my environment clean to try provisioning my vagrant machine from scratch, and couldn't get it to work. By adding this environment variable and updating composer, it was able to run successfully.

@Seldaek
Copy link
Member

Seldaek commented Apr 1, 2021

Please beware: COMPOSER_RUNTIME_ENV now expects virtualbox instead of vagrant. But I also added support for lsmod to detect vbox guest additions so it should hopefully not be needed at all to set the environment variable.

All this is now part of Composer 2.0.12 which was just released.

@spider-mane
Copy link

Please beware: COMPOSER_RUNTIME_ENV now expects virtualbox instead of vagrant. But I also added support for lsmod to detect vbox guest additions so it should hopefully not be needed at all to set the environment variable.

All this is now part of Composer 2.0.12 which was just released.

@Seldaek bro you're a godsend! I literally stumbled onto this thread today while looking into something else, but this virtualbox issue has been driving me crazy for over a month. Thank you for this!

@gggeek
Copy link

gggeek commented Apr 2, 2021

A workaround and not a solution, but in case anyone reads up to here, and still has problems with VirtualBox shared-filesystem being both slow and unreliable, for apps other than composer:

my goto solution for running php-on-linux on a windows host has been for years to

  • run linux in virtualbox (or vmware)
  • run php in linux, including composer
  • do not use vbox (nor vmware) native file-shares
  • do not share the host disk to vbox, but do the opposite: share the linux disk's www root to windows via samba

pros:

  • never have any issue with fielsystem casing (windows not liking hello.txt and Hello.txt in same folder)
  • all linux things run at native speeds
  • samba share perfs on the windows side are "quite good" for most operations. Never had caching issues with file metadata
  • allows to encrypt your data using vbox encription, no need for bitlocker or veracrypt

cons:

  • need to be able to install and configure samba
  • php code is not accessible without the vm running
  • size of vm disk might spiral out of control
  • running tortoisegit on windows to manipulate git repos in the samba shares works, but it is much slower than git cli in linux. Also there might be locking issues if the two gits are run at the same time
  • running phpstorm in windows is suboptimal as a) it will not refresh files instantaneously on disk changes, nor b) have access to all the cli tools running in the vm

@mxr576
Copy link
Contributor

mxr576 commented Apr 5, 2021

My gut says my old issue was also somehow related to my old issue which was about running >=15 (Drupal) Composer installations on a dedicated AWS instance in parallel. So probably this issue is not about Vagrant or Virtualbox, it is more like about parallelism and filesystems. We tried to tweak inode size on the AWS instance but that did not help. The only currently working solution is not sharing Composer cache between those parallel builds, which increases network traffic and kinda eliminates the purpose of Composer package caching. I wonder if this fix would also solve that problem, I may give it once.
#9568

@bilogic
Copy link
Contributor

bilogic commented Apr 27, 2021

@Seldaek

The issue is affecting me again and I have some new insights though I'm not sure if you still want to pursue the issue.

It seems that when the problem is present, RecursiveDirectoryIterator() will have missing entries after unzipping.
Perhaps a test could be to count the number of files. See Jeroen-G/laravel-packager#101 (comment) and the post right before.

Thanks!

@Seldaek
Copy link
Member

Seldaek commented Apr 27, 2021

@bilogic it's affecting you again with laravel-packager or with latest Composer? Because the fix we did only does pauses in Composer when we expect something right after an unzip or similar might break. If a third party package does filesystem operations it may still break, and they'll have to fix that themselves.

@bilogic
Copy link
Contributor

bilogic commented Apr 27, 2021

@Seldaek Sorry I wasn't clear. No issues with Composer.

What I wanted to say was I have some "new" findings which came from facing the issue with laravel-packager.

@Seldaek
Copy link
Member

Seldaek commented Apr 27, 2021

Ok yeah that does make sense IMO that it would not find the files while iterating, at least it seems to correlate with the fact the files are not yet readable/accessible when accessed directly via include.

davidacmoreira-cx added a commit to cxsca/cx-composer-cli that referenced this issue May 14, 2021
* Include stdout as well as stderr if git stash/diff/.. fails, fixes composer#9720

* Remove version argument from why and enforce it for why-not command, refs composer#9693

* Fix compiler on Windows (composer#9730)

* Preserve file permissions on Windows self-update (composer#9733)

Windows file operations result in different file permissions depending
if the file is copied or moved. A copy operation applies permissions
from the destination folder (or file if it already exists and does not
use inheritance), while a move operation generally preserves the source
file permissions.

Windows PHP `rename` uses MoveFileEx so if the user is running as an
admin and the destination is in a common (non-user) location, then the
permission for other users will be replaced by the admin user. Likewise
for the UAC elevation feature, which uses the cmd.exe `move` command.

This fix uses copy and delete operations on Windows, so that other users
can continue to run composer.phar

* Proxy handling docs and tweaks (composer#9735)

* Fix functional tests to use the same PHP version as PHPUnit runs with

* Add support for @php <abs path to binary from PATH>, fixes composer#9726

* Fix issue extracting archives into paths that already exist, fixes composer/installers#479

* Avoid using str_replace for dev-master replacement as that may be a valid part of a branch name, fixes composer#9739

* Fix php-proxying of binaries to avoid proxying phar files, fixes composer#9742

* Make sure that single files installed via file downloader get the executable bit set if they are a binary file, refs composer#9742

* Fix var shadowing

* Fix unclear error when a package can be found in lock but not in the remote repo, fixes composer#9750

* Update release step to use php8 as it produces slightly different output wrt white-space, fixes composer#9746

* Bump phpstan to level 3 (composer#9734)

Clean up PackageInterface/CompletePackageInterface, add missing methods, type things in solver as BasePackage, added CompleteAliasPackage, ..

* Update GitHub token pattern

GitHub is updating the format of auth tokens from `a-z0-9` to `A-Za-z0-9` ([notice](https://github.blog/changelog/2021-03-04-authentication-token-format-updates/)).
I'm not sure why `.` is allowed, but I dare not to remove it. In this PR, the token validation regex is updated to allow `A-Za-z0-9` instead of the current all lower-case `a-z` and disallowed `_`.

* Document GH token usage and also make sure we redact them in Process debug output, refs composer#9757

* Remove output "summary" from fund command. Fund does not provide this type of format. (composer#9748)

* Clarify behavior of name in VCS repo, closes composer#9752

* Add --format json to search command (composer#9747)


Co-authored-by: Jordi Boggiano <j.boggiano@seld.be>

* Attempt working around Vagrant filesystem issues, added COMPOSER_RUNTIME_ENV env var (set to vagrant), fixes composer#9627

* Prefer @phpstan- annotations as that is what we run against

* Fix phpdoc

* Make full functional test output more reliable

* Create pull_request_template.md

* Only call sapi_windows_set_ctrl_handler() for CLI requests (composer#9771)

* MaxFileSizeException should reject download job (composer#9778)

* Also attempt working around Vagrant filesystem issues when installing plugins initially, refs composer#9627

* Add source package name to debug info when enabling plugins

* Add dev mode env var for scripts run (composer#9793)

Co-authored-by: Vitali Tsyrkin <vitalit@playtika.com>

* Update github token pattern to match their latest updates

* Update changelog

* Tweak virtualbox detection and improve it by detecting vbox additions, refs composer#9627

* Update changelog

* Fixed detection of hg version when localized, fixes composer#9753

* Fix type warning on php8.1, refs composer#9770

* Support --no-dev combined with --locked in outdated/show commands, fixes composer#9788

* Improve InstalledVersions docs slightly

* Fix doctype annotations

* Change root.dev-requirement to root.dev in installed.php as the root is not required per se, and this simply tracks the dev mode at install time

* Fix tests

* Make ComposerRepository::configurePackageTransportOptions() protected. (composer#9818)

* Fix doctype annotations

* Switch to composer/metadata-minifier, fixes composer#9727

* Add new dep to the tests

* Change default preferred-install to dist, add --prefer-install=auto|dist|source to allow specifying auto (composer#9603)

Fixes composer#9546
Fixes composer#9674

* Add warning when loading plugins of type composer-installer as they are unlikely to function correctly and should be upgraded to the composer-plugin type

* Fix output listing some updates that do not really happen when updating mirrors/--lock, fixes composer#9812

* Make sure update mirrors/--lock keeps the release date of the original reference when dev versions have newer commits, refs composer#9812

* Fire POST_FILE_DOWNLOAD event for metadata fetched by ComposerRepository.

* Clean stuff up and deprecate old usages for PostFileDownloadEvent

* Add repository instance to Pre/PostFileDownloadEvent metadata

* Added link to composer.org docs on ProcessTimedOutException (composer#9796)

* ComposerRepository::asyncFetchFile() does not pass the downloaded URL to PostFileDownloadEvent (composer#9827)

* Update 00-intro.md

* Upgrade to xdebug-handler 2 (composer#9832)

This adds support for Xdebug3 modes and changes the default behaviour
from always restarting if Xdebug is loaded, to only restarting if Xdebug
is active.

Xdebug is considered active if it is loaded, and for Xdebug3, if it is
running in a mode other than `xdebug.mode=off`.

* Fix source links, fixes composer#9836

* Allow PreFileDownloadEvent to carry transport options for metadata (composer#9831)

* Use jsonc highlighting

* "composer init --autoload" - Interactive generates PSR-4 autoloader in composer.json (composer#9829)

- Generates PSR-4 autoload entry in composer.json.
- Run dump-autoload, if no dependencies are set

* Fix install step at the end of init command

* Fix install step at the end of init command

* Merge pull request from GHSA-h5h8-pc6h-jvvx

* Fix external process calls to avoid user input being able to pass extra parameters

* Tweak some fixes

* Merge pull request from GHSA-h5h8-pc6h-jvvx

* Fix external process calls to avoid user input being able to pass extra parameters

* Tweak some fixes

* Update changelog

* Update changelog

* Add basic source/dist validation

* Allow ints in source/dist reference

* Also make sure type is correct for preg_match

* BinaryInstaller: install full binaries on WSL when bin-compat=auto (composer#9855)

* Hint at a branch rename if we detect dev-master can not be found but dev-main or dev-default exists, fixes composer#9850

* Also condense dev-* versions if there are many, refs composer#9850

* Introduce a cross-platform safe version of is_readable to support UNC / wsl$ paths on Windows (composer#9861)

* Fix handling of inline-update-constraints with refs or stability flags, fixes composer#9847

* Link to GitLab documentation for auth (composer#9833)



Co-authored-by: Jordi Boggiano <j.boggiano@seld.be>

* Avoid leaving the event stack in a dirty state if an event listener throws, fixes composer#9846

* Fix invalid interface usage

* Fix type issues with root package interface

* Also handle throwable on supported php versions

* Fix EOL of text files (composer#9877)

* Fix update fork changes

* Add skipping svn downloader

* Revert skipping in svn downloader

Co-authored-by: Jordi Boggiano <j.boggiano@seld.be>
Co-authored-by: Nils Adermann <naderman@naderman.de>
Co-authored-by: John Stevenson <john-stevenson@blueyonder.co.uk>
Co-authored-by: Ayesh Karunaratne <ayesh@aye.sh>
Co-authored-by: ochorocho <jochen.roth@b13.com>
Co-authored-by: Brandon Kelly <brandon@pixelandtonic.com>
Co-authored-by: Stephan <glaubinix@users.noreply.github.com>
Co-authored-by: vitman <vitalyhome@tut.by>
Co-authored-by: Vitali Tsyrkin <vitalit@playtika.com>
Co-authored-by: Adam <adam@phenaproxima.net>
Co-authored-by: Markus Staab <markus.staab@redaxo.de>
Co-authored-by: Antoine Makdessi <amakdessi@me.com>
Co-authored-by: Andreas Scheibel <contact@camya.com>
Co-authored-by: Markus Staab <47448731+clxmstaab@users.noreply.github.com>
Co-authored-by: timrizzi <tim.rizzi@gmail.com>
Co-authored-by: Michael Voříšek <mvorisek@mvorisek.cz>
@hochleitner
Copy link

hochleitner commented May 19, 2021

I'd like to add another issue under vagrant and Virtualbox. Composer 2.0.12 solved many of my Problems with packages but there's still one which I can't install: phpstan. This one throws an error all the time. It's a dev-dependency of slim-skeleton in my case.

To reproduce, I did the following:

  1. composer self-update (to make sure it's >= 2.0.12, got 2.0.13)
  2. export COMPOSER_RUNTIME_ENV=virtualbox
  3. composer create-project slim/slim-skeleton test -vvv

This is the output:

vagrant@vagrant:/vagrant/code/repos$ composer create-project slim/slim-skeleton test -vvv
Loading config file /home/vagrant/.config/composer/config.json
Loading config file /home/vagrant/.config/composer/auth.json
Reading /home/vagrant/.config/composer/composer.json
Loading config file /home/vagrant/.config/composer/config.json
Loading config file /home/vagrant/.config/composer/auth.json
Loading config file /home/vagrant/.config/composer/composer.json (/home/vagrant/.config/composer/composer.json)
Loading config file /home/vagrant/.config/composer/auth.json
Reading /home/vagrant/.config/composer/auth.json
Checked CA file /etc/ssl/certs/ca-certificates.crt: valid
Executing command (/home/vagrant/.config/composer): git branch -a --no-color --no-abbrev -v
Executing command (/home/vagrant/.config/composer): git describe --exact-match --tags
Executing command (CWD): git --version
Executing command (/home/vagrant/.config/composer): git log --pretty="%H" -n1 HEAD --no-show-signature
Executing command (/home/vagrant/.config/composer): hg branch
Executing command (/home/vagrant/.config/composer): fossil branch list
Executing command (/home/vagrant/.config/composer): fossil tag list
Executing command (/home/vagrant/.config/composer): svn info --xml
Running 2.0.13 (2021-04-27 13:11:08) with PHP 8.0.3 on Linux / 5.4.0-58-generic
Loading config file /home/vagrant/.config/composer/config.json
Loading config file /home/vagrant/.config/composer/auth.json
Reading /home/vagrant/.config/composer/composer.json
Loading config file /home/vagrant/.config/composer/config.json
Loading config file /home/vagrant/.config/composer/auth.json
Loading config file /home/vagrant/.config/composer/composer.json (/home/vagrant/.config/composer/composer.json)
Loading config file /home/vagrant/.config/composer/auth.json
Reading /home/vagrant/.config/composer/auth.json
Executing command (/home/vagrant/.config/composer): git branch -a --no-color --no-abbrev -v
Executing command (/home/vagrant/.config/composer): git describe --exact-match --tags
Executing command (/home/vagrant/.config/composer): git log --pretty="%H" -n1 HEAD --no-show-signature
Executing command (/home/vagrant/.config/composer): hg branch
Executing command (/home/vagrant/.config/composer): fossil branch list
Executing command (/home/vagrant/.config/composer): fossil tag list
Executing command (/home/vagrant/.config/composer): svn info --xml
Creating a "slim/slim-skeleton" project at "./test"
Loading config file /home/vagrant/.config/composer/config.json
Loading config file /home/vagrant/.config/composer/auth.json
Executing command (/vagrant/code/repos): git branch -a --no-color --no-abbrev -v
Reading /home/vagrant/.config/composer/composer.json
Loading config file /home/vagrant/.config/composer/config.json
Loading config file /home/vagrant/.config/composer/auth.json
Loading config file /home/vagrant/.config/composer/composer.json (/home/vagrant/.config/composer/composer.json)
Loading config file /home/vagrant/.config/composer/auth.json
Reading /home/vagrant/.config/composer/auth.json
Downloading https://repo.packagist.org/packages.json
[200] https://repo.packagist.org/packages.json
Writing /home/vagrant/.cache/composer/repo/https---repo.packagist.org/packages.json into cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-slim~slim-skeleton.json from cache
Downloading https://repo.packagist.org/p2/slim/slim-skeleton.json if modified
[304] https://repo.packagist.org/p2/slim/slim-skeleton.json
Installing slim/slim-skeleton (4.3.0)
Reading /home/vagrant/.cache/composer/files/slim/slim-skeleton/c42bcb3f12ae570c8c5898521f0697f0b9bf622a.zip from cache
  - Loading slim/slim-skeleton (4.3.0) from cache
  - Installing slim/slim-skeleton (4.3.0): Extracting archive
Executing async command (CWD): unzip -qq  '/vagrant/code/repos/vendor/composer/tmp-b020f9087e27d48f0462fdfd9bb89717' -d '/vagrant/code/repos/vendor/composer/1fb6e474'
Executing command (CWD): rm -rf '/vagrant/code/repos/test'
Executing command (CWD): rm -rf '/vagrant/code/repos/vendor/composer/1fb6e474'
Executing command (CWD): rm -rf '/vagrant/code/repos/vendor/composer/'
Executing command (CWD): rm -rf '/vagrant/code/repos/vendor'
Downloading https://packagist.org/downloads/
[201] https://packagist.org/downloads/
Created project in /vagrant/code/repos/test
Reading ./composer.json (/vagrant/code/repos/test/composer.json)
Loading config file /home/vagrant/.config/composer/config.json
Loading config file /home/vagrant/.config/composer/auth.json
Loading config file ./composer.json (/vagrant/code/repos/test/composer.json)
Reading /home/vagrant/.config/composer/composer.json
Loading config file /home/vagrant/.config/composer/config.json
Loading config file /home/vagrant/.config/composer/auth.json
Loading config file /home/vagrant/.config/composer/composer.json (/home/vagrant/.config/composer/composer.json)
Loading config file /home/vagrant/.config/composer/auth.json
Reading /home/vagrant/.config/composer/auth.json
Loading composer repositories with package information
Downloading https://repo.packagist.org/packages.json
[200] https://repo.packagist.org/packages.json
Writing /home/vagrant/.cache/composer/repo/https---repo.packagist.org/packages.json into cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-monolog~monolog.json from cache
Downloading https://repo.packagist.org/p2/monolog/monolog.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-php-di~php-di.json from cache
Downloading https://repo.packagist.org/p2/php-di/php-di.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-slim~psr7.json from cache
Downloading https://repo.packagist.org/p2/slim/psr7.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-slim~slim.json from cache
Downloading https://repo.packagist.org/p2/slim/slim.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-jangregor~phpstan-prophecy.json from cache
Downloading https://repo.packagist.org/p2/jangregor/phpstan-prophecy.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpstan~extension-installer.json from cache
Downloading https://repo.packagist.org/p2/phpstan/extension-installer.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpstan~phpstan.json from cache
Downloading https://repo.packagist.org/p2/phpstan/phpstan.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpunit~phpunit.json from cache
Downloading https://repo.packagist.org/p2/phpunit/phpunit.json if modified
[304] https://repo.packagist.org/p2/monolog/monolog.json
[304] https://repo.packagist.org/p2/php-di/php-di.json
[304] https://repo.packagist.org/p2/slim/psr7.json
[304] https://repo.packagist.org/p2/slim/slim.json
[304] https://repo.packagist.org/p2/jangregor/phpstan-prophecy.json
[304] https://repo.packagist.org/p2/phpstan/extension-installer.json
[304] https://repo.packagist.org/p2/phpstan/phpstan.json
[304] https://repo.packagist.org/p2/phpunit/phpunit.json
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-psr~log.json from cache
Downloading https://repo.packagist.org/p2/psr/log.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-psr~container.json from cache
Downloading https://repo.packagist.org/p2/psr/container.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-php-di~invoker.json from cache
Downloading https://repo.packagist.org/p2/php-di/invoker.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-php-di~phpdoc-reader.json from cache
Downloading https://repo.packagist.org/p2/php-di/phpdoc-reader.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-opis~closure.json from cache
Downloading https://repo.packagist.org/p2/opis/closure.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-fig~http-message-util.json from cache
Downloading https://repo.packagist.org/p2/fig/http-message-util.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-psr~http-factory.json from cache
Downloading https://repo.packagist.org/p2/psr/http-factory.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-psr~http-message.json from cache
Downloading https://repo.packagist.org/p2/psr/http-message.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-ralouphie~getallheaders.json from cache
Downloading https://repo.packagist.org/p2/ralouphie/getallheaders.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-symfony~polyfill-php80.json from cache
Downloading https://repo.packagist.org/p2/symfony/polyfill-php80.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-nikic~fast-route.json from cache
Downloading https://repo.packagist.org/p2/nikic/fast-route.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-psr~http-server-handler.json from cache
Downloading https://repo.packagist.org/p2/psr/http-server-handler.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-psr~http-server-middleware.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-weirdan~prophecy-shim.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-doctrine~instantiator.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-myclabs~deep-copy.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phar-io~manifest.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phar-io~version.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpspec~prophecy.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpunit~php-code-coverage.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpunit~php-file-iterator.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpunit~php-invoker.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpunit~php-text-template.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpunit~php-timer.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~cli-parser.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~code-unit.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~comparator.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~diff.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~environment.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~exporter.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~global-state.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~object-enumerator.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~resource-operations.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~type.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~version.json from cache
[304] https://repo.packagist.org/p2/psr/log.json
[304] https://repo.packagist.org/p2/psr/container.json
[304] https://repo.packagist.org/p2/php-di/invoker.json
[304] https://repo.packagist.org/p2/php-di/phpdoc-reader.json
Downloading https://repo.packagist.org/p2/psr/http-server-middleware.json if modified
Downloading https://repo.packagist.org/p2/weirdan/prophecy-shim.json if modified
Downloading https://repo.packagist.org/p2/doctrine/instantiator.json if modified
Downloading https://repo.packagist.org/p2/myclabs/deep-copy.json if modified
[304] https://repo.packagist.org/p2/opis/closure.json
[304] https://repo.packagist.org/p2/fig/http-message-util.json
[304] https://repo.packagist.org/p2/psr/http-factory.json
[304] https://repo.packagist.org/p2/psr/http-message.json
[304] https://repo.packagist.org/p2/ralouphie/getallheaders.json
[304] https://repo.packagist.org/p2/symfony/polyfill-php80.json
[304] https://repo.packagist.org/p2/nikic/fast-route.json
[304] https://repo.packagist.org/p2/psr/http-server-handler.json
Downloading https://repo.packagist.org/p2/phar-io/manifest.json if modified
Downloading https://repo.packagist.org/p2/phar-io/version.json if modified
Downloading https://repo.packagist.org/p2/phpspec/prophecy.json if modified
Downloading https://repo.packagist.org/p2/phpunit/php-code-coverage.json if modified
Downloading https://repo.packagist.org/p2/phpunit/php-file-iterator.json if modified
Downloading https://repo.packagist.org/p2/phpunit/php-invoker.json if modified
Downloading https://repo.packagist.org/p2/phpunit/php-text-template.json if modified
Downloading https://repo.packagist.org/p2/phpunit/php-timer.json if modified
[304] https://repo.packagist.org/p2/psr/http-server-middleware.json
[304] https://repo.packagist.org/p2/weirdan/prophecy-shim.json
[304] https://repo.packagist.org/p2/doctrine/instantiator.json
[304] https://repo.packagist.org/p2/myclabs/deep-copy.json
Downloading https://repo.packagist.org/p2/sebastian/cli-parser.json if modified
Downloading https://repo.packagist.org/p2/sebastian/code-unit.json if modified
Downloading https://repo.packagist.org/p2/sebastian/comparator.json if modified
Downloading https://repo.packagist.org/p2/sebastian/diff.json if modified
[304] https://repo.packagist.org/p2/phar-io/manifest.json
[304] https://repo.packagist.org/p2/phar-io/version.json
[304] https://repo.packagist.org/p2/phpspec/prophecy.json
[304] https://repo.packagist.org/p2/phpunit/php-code-coverage.json
[304] https://repo.packagist.org/p2/phpunit/php-file-iterator.json
[304] https://repo.packagist.org/p2/phpunit/php-invoker.json
[304] https://repo.packagist.org/p2/phpunit/php-text-template.json
[304] https://repo.packagist.org/p2/phpunit/php-timer.json
Downloading https://repo.packagist.org/p2/sebastian/environment.json if modified
Downloading https://repo.packagist.org/p2/sebastian/exporter.json if modified
Downloading https://repo.packagist.org/p2/sebastian/global-state.json if modified
Downloading https://repo.packagist.org/p2/sebastian/object-enumerator.json if modified
Downloading https://repo.packagist.org/p2/sebastian/resource-operations.json if modified
Downloading https://repo.packagist.org/p2/sebastian/type.json if modified
Downloading https://repo.packagist.org/p2/sebastian/version.json if modified
[304] https://repo.packagist.org/p2/sebastian/cli-parser.json
[304] https://repo.packagist.org/p2/sebastian/code-unit.json
[304] https://repo.packagist.org/p2/sebastian/comparator.json
[304] https://repo.packagist.org/p2/sebastian/diff.json
[304] https://repo.packagist.org/p2/sebastian/environment.json
[304] https://repo.packagist.org/p2/sebastian/exporter.json
[304] https://repo.packagist.org/p2/sebastian/global-state.json
[304] https://repo.packagist.org/p2/sebastian/object-enumerator.json
[304] https://repo.packagist.org/p2/sebastian/resource-operations.json
[304] https://repo.packagist.org/p2/sebastian/type.json
[304] https://repo.packagist.org/p2/sebastian/version.json
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpspec~prophecy-phpunit.json from cache
Downloading https://repo.packagist.org/p2/phpspec/prophecy-phpunit.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phar-io~version.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpdocumentor~reflection-docblock.json from cache
Downloading https://repo.packagist.org/p2/phpdocumentor/reflection-docblock.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~recursion-context.json from cache
Downloading https://repo.packagist.org/p2/sebastian/recursion-context.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~comparator.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-doctrine~instantiator.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-nikic~php-parser.json from cache
Downloading https://repo.packagist.org/p2/nikic/php-parser.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~code-unit-reverse-lookup.json from cache
Downloading https://repo.packagist.org/p2/sebastian/code-unit-reverse-lookup.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~complexity.json from cache
Downloading https://repo.packagist.org/p2/sebastian/complexity.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~lines-of-code.json from cache
Downloading https://repo.packagist.org/p2/sebastian/lines-of-code.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-theseer~tokenizer.json from cache
Downloading https://repo.packagist.org/p2/theseer/tokenizer.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpunit~php-token-stream.json from cache
Downloading https://repo.packagist.org/p2/phpunit/php-token-stream.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~object-reflector.json from cache
Downloading https://repo.packagist.org/p2/sebastian/object-reflector.json if modified
[304] https://repo.packagist.org/p2/phpspec/prophecy-phpunit.json
[304] https://repo.packagist.org/p2/phpdocumentor/reflection-docblock.json
[304] https://repo.packagist.org/p2/sebastian/recursion-context.json
[304] https://repo.packagist.org/p2/nikic/php-parser.json
[304] https://repo.packagist.org/p2/sebastian/code-unit-reverse-lookup.json
[304] https://repo.packagist.org/p2/sebastian/complexity.json
[304] https://repo.packagist.org/p2/sebastian/lines-of-code.json
[304] https://repo.packagist.org/p2/theseer/tokenizer.json
[304] https://repo.packagist.org/p2/phpunit/php-token-stream.json
[304] https://repo.packagist.org/p2/sebastian/object-reflector.json
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~diff.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-sebastian~exporter.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpspec~prophecy.json from cache
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpdocumentor~type-resolver.json from cache
Downloading https://repo.packagist.org/p2/phpdocumentor/type-resolver.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-webmozart~assert.json from cache
Downloading https://repo.packagist.org/p2/webmozart/assert.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-phpdocumentor~reflection-common.json from cache
Downloading https://repo.packagist.org/p2/phpdocumentor/reflection-common.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-dflydev~markdown.json from cache
Downloading https://repo.packagist.org/p2/dflydev/markdown.json if modified
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-nikic~php-parser.json from cache
[304] https://repo.packagist.org/p2/phpdocumentor/type-resolver.json
[304] https://repo.packagist.org/p2/webmozart/assert.json
[304] https://repo.packagist.org/p2/phpdocumentor/reflection-common.json
[304] https://repo.packagist.org/p2/dflydev/markdown.json
Reading /home/vagrant/.cache/composer/repo/https---repo.packagist.org/provider-symfony~polyfill-ctype.json from cache
Downloading https://repo.packagist.org/p2/symfony/polyfill-ctype.json if modified
[304] https://repo.packagist.org/p2/symfony/polyfill-ctype.json
Updating dependencies
Generating rules
Resolving dependencies through SAT
Looking at all rules.
Something's changed, looking at all rules again (pass #2)
Dependency resolution completed in 0.009 seconds
Analyzed 648 packages to resolve dependencies
Analyzed 3620 rules to resolve dependencies
Generating rules
Resolving dependencies through SAT
Looking at all rules.

Dependency resolution completed in 0.000 seconds
Lock file operations: 54 installs, 0 updates, 0 removals
Installs: phpstan/phpstan:0.12.88, phpstan/extension-installer:1.1.0, jangregor/phpstan-prophecy:0.8.1, psr/log:1.1.4, monolog/monolog:2.2.0, opis/closure:3.6.2, php-di/phpdoc-reader:2.2.1, psr/container:1.1.1, php-di/invoker:2.3.0, php-di/php-di:6.3.3, phpdocumentor/reflection-common:2.2.0, symfony/polyfill-ctype:v1.22.1, webmozart/assert:1.10.0, phpdocumentor/type-resolver:1.4.0, phpdocumentor/reflection-docblock:5.2.2, sebastian/version:3.0.2, sebastian/type:2.3.1, sebastian/resource-operations:3.0.3, sebastian/recursion-context:4.0.4, sebastian/object-reflector:2.0.4, sebastian/object-enumerator:4.0.4, sebastian/global-state:5.0.2, sebastian/exporter:4.0.3, sebastian/environment:5.1.3, sebastian/diff:4.0.4, sebastian/comparator:4.0.6, sebastian/code-unit:1.0.8, sebastian/cli-parser:1.0.1, phpunit/php-timer:5.0.3, phpunit/php-text-template:2.0.4, phpunit/php-invoker:3.1.1, phpunit/php-file-iterator:3.0.5, theseer/tokenizer:1.2.0, nikic/php-parser:v4.10.5, sebastian/lines-of-code:1.0.3, sebastian/complexity:2.0.2, sebastian/code-unit-reverse-lookup:2.0.3, phpunit/php-code-coverage:9.2.6, doctrine/instantiator:1.4.0, phpspec/prophecy:1.13.0, phar-io/version:3.1.0, phar-io/manifest:2.0.1, myclabs/deep-copy:1.10.2, phpunit/phpunit:9.5.4, symfony/polyfill-php80:v1.22.1, ralouphie/getallheaders:3.0.3, psr/http-message:1.0.1, psr/http-factory:1.0.1, fig/http-message-util:1.1.5, slim/psr7:1.4, psr/http-server-handler:1.0.1, psr/http-server-middleware:1.0.1, nikic/fast-route:v1.3.0, slim/slim:4.7.1
  - Locking doctrine/instantiator (1.4.0)
  - Locking fig/http-message-util (1.1.5)
  - Locking jangregor/phpstan-prophecy (0.8.1)
  - Locking monolog/monolog (2.2.0)
  - Locking myclabs/deep-copy (1.10.2)
  - Locking nikic/fast-route (v1.3.0)
  - Locking nikic/php-parser (v4.10.5)
  - Locking opis/closure (3.6.2)
  - Locking phar-io/manifest (2.0.1)
  - Locking phar-io/version (3.1.0)
  - Locking php-di/invoker (2.3.0)
  - Locking php-di/php-di (6.3.3)
  - Locking php-di/phpdoc-reader (2.2.1)
  - Locking phpdocumentor/reflection-common (2.2.0)
  - Locking phpdocumentor/reflection-docblock (5.2.2)
  - Locking phpdocumentor/type-resolver (1.4.0)
  - Locking phpspec/prophecy (1.13.0)
  - Locking phpstan/extension-installer (1.1.0)
  - Locking phpstan/phpstan (0.12.88)
  - Locking phpunit/php-code-coverage (9.2.6)
  - Locking phpunit/php-file-iterator (3.0.5)
  - Locking phpunit/php-invoker (3.1.1)
  - Locking phpunit/php-text-template (2.0.4)
  - Locking phpunit/php-timer (5.0.3)
  - Locking phpunit/phpunit (9.5.4)
  - Locking psr/container (1.1.1)
  - Locking psr/http-factory (1.0.1)
  - Locking psr/http-message (1.0.1)
  - Locking psr/http-server-handler (1.0.1)
  - Locking psr/http-server-middleware (1.0.1)
  - Locking psr/log (1.1.4)
  - Locking ralouphie/getallheaders (3.0.3)
  - Locking sebastian/cli-parser (1.0.1)
  - Locking sebastian/code-unit (1.0.8)
  - Locking sebastian/code-unit-reverse-lookup (2.0.3)
  - Locking sebastian/comparator (4.0.6)
  - Locking sebastian/complexity (2.0.2)
  - Locking sebastian/diff (4.0.4)
  - Locking sebastian/environment (5.1.3)
  - Locking sebastian/exporter (4.0.3)
  - Locking sebastian/global-state (5.0.2)
  - Locking sebastian/lines-of-code (1.0.3)
  - Locking sebastian/object-enumerator (4.0.4)
  - Locking sebastian/object-reflector (2.0.4)
  - Locking sebastian/recursion-context (4.0.4)
  - Locking sebastian/resource-operations (3.0.3)
  - Locking sebastian/type (2.3.1)
  - Locking sebastian/version (3.0.2)
  - Locking slim/psr7 (1.4)
  - Locking slim/slim (4.7.1)
  - Locking symfony/polyfill-ctype (v1.22.1)
  - Locking symfony/polyfill-php80 (v1.22.1)
  - Locking theseer/tokenizer (1.2.0)
  - Locking webmozart/assert (1.10.0)
Writing lock file
Installing dependencies from lock file (including require-dev)
Reading ./composer.lock (/vagrant/code/repos/test/composer.lock)
Package operations: 54 installs, 0 updates, 0 removals
Installs: phpstan/phpstan:0.12.88, phpstan/extension-installer:1.1.0, jangregor/phpstan-prophecy:0.8.1, psr/log:1.1.4, monolog/monolog:2.2.0, psr/container:1.1.1, php-di/phpdoc-reader:2.2.1, php-di/invoker:2.3.0, opis/closure:3.6.2, php-di/php-di:6.3.3, symfony/polyfill-ctype:v1.22.1, webmozart/assert:1.10.0, phpdocumentor/reflection-common:2.2.0, phpdocumentor/type-resolver:1.4.0, phpdocumentor/reflection-docblock:5.2.2, sebastian/version:3.0.2, sebastian/type:2.3.1, sebastian/resource-operations:3.0.3, sebastian/recursion-context:4.0.4, sebastian/object-reflector:2.0.4, sebastian/object-enumerator:4.0.4, sebastian/global-state:5.0.2, sebastian/exporter:4.0.3, sebastian/environment:5.1.3, sebastian/diff:4.0.4, sebastian/comparator:4.0.6, sebastian/code-unit:1.0.8, sebastian/cli-parser:1.0.1, phpunit/php-timer:5.0.3, phpunit/php-text-template:2.0.4, phpunit/php-invoker:3.1.1, phpunit/php-file-iterator:3.0.5, theseer/tokenizer:1.2.0, nikic/php-parser:v4.10.5, sebastian/lines-of-code:1.0.3, sebastian/complexity:2.0.2, sebastian/code-unit-reverse-lookup:2.0.3, phpunit/php-code-coverage:9.2.6, doctrine/instantiator:1.4.0, phpspec/prophecy:1.13.0, phar-io/version:3.1.0, phar-io/manifest:2.0.1, myclabs/deep-copy:1.10.2, phpunit/phpunit:9.5.4, symfony/polyfill-php80:v1.22.1, ralouphie/getallheaders:3.0.3, psr/http-message:1.0.1, psr/http-factory:1.0.1, fig/http-message-util:1.1.5, slim/psr7:1.4, psr/http-server-handler:1.0.1, psr/http-server-middleware:1.0.1, nikic/fast-route:v1.3.0, slim/slim:4.7.1
Reading /home/vagrant/.cache/composer/files/phpstan/phpstan/d9badb9a9b8a73c56cba221c8dbd1d7b778b2c12.zip from cache
  - Loading phpstan/phpstan (0.12.88) from cache
Reading /home/vagrant/.cache/composer/files/phpstan/extension-installer/39a488c9ee5d5395324d871eea68bea1b1b37b71.zip from cache
  - Loading phpstan/extension-installer (1.1.0) from cache
Reading /home/vagrant/.cache/composer/files/jangregor/phpstan-prophecy/ed81b2757f797ee3050e28b7f3a9ffd3a7c8ec89.zip from cache
  - Loading jangregor/phpstan-prophecy (0.8.1) from cache
Reading /home/vagrant/.cache/composer/files/psr/log/73bdffd901b564d0a2f7244baecb66a2572fcfc4.zip from cache
  - Loading psr/log (1.1.4) from cache
Reading /home/vagrant/.cache/composer/files/monolog/monolog/1ea03bfb7b8a89de2fcecb0cc0b1204ac14411e0.zip from cache
  - Loading monolog/monolog (2.2.0) from cache
Reading /home/vagrant/.cache/composer/files/psr/container/e4c7bcf51ae3971f12405fe5a14d36d5b2ddff27.zip from cache
  - Loading psr/container (1.1.1) from cache
Reading /home/vagrant/.cache/composer/files/php-di/phpdoc-reader/ee8bf33615b2fc89835465a11e329b3c1e160bbb.zip from cache
  - Loading php-di/phpdoc-reader (2.2.1) from cache
Reading /home/vagrant/.cache/composer/files/php-di/invoker/c6f4af9857af9712605aa3ef6b431b0d1579aee8.zip from cache
  - Loading php-di/invoker (2.3.0) from cache
Reading /home/vagrant/.cache/composer/files/opis/closure/a8e35780c98327b4b2900ad5d12e23e8c1575322.zip from cache
  - Loading opis/closure (3.6.2) from cache
Reading /home/vagrant/.cache/composer/files/php-di/php-di/0e3f727481cc1c9281ccb32c8dd61e46a8e06a06.zip from cache
  - Loading php-di/php-di (6.3.3) from cache
Reading /home/vagrant/.cache/composer/files/symfony/polyfill-ctype/4d6de184d3f1ce9c17b33653cb12171481930c51.zip from cache
  - Loading symfony/polyfill-ctype (v1.22.1) from cache
Reading /home/vagrant/.cache/composer/files/webmozart/assert/9badd292a512316673890927d579f69ae6c75984.zip from cache
  - Loading webmozart/assert (1.10.0) from cache
Reading /home/vagrant/.cache/composer/files/phpdocumentor/reflection-common/6243ab17e2330fb7ce63d34391d53104cc913dc0.zip from cache
  - Loading phpdocumentor/reflection-common (2.2.0) from cache
Reading /home/vagrant/.cache/composer/files/phpdocumentor/type-resolver/752161aedc0d6ed781ada8f3aa9db4973e187d1f.zip from cache
  - Loading phpdocumentor/type-resolver (1.4.0) from cache
Reading /home/vagrant/.cache/composer/files/phpdocumentor/reflection-docblock/8dff474b657832a5f4f52148225055696fe8e20f.zip from cache
  - Loading phpdocumentor/reflection-docblock (5.2.2) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/version/85e202da271e8389420827021d6c4f00bdd90951.zip from cache
  - Loading sebastian/version (3.0.2) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/type/55c6357ffce815362f0bbfc7d84b3a57d2ac3e4f.zip from cache
  - Loading sebastian/type (2.3.1) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/resource-operations/c70bff160e611fd40d5d68d1f06d580b9496fb3a.zip from cache
  - Loading sebastian/resource-operations (3.0.3) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/recursion-context/6458bc6eb2e2dab0f0e7550c596001dd26243950.zip from cache
  - Loading sebastian/recursion-context (4.0.4) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/object-reflector/89595d8936651649889c35a91221207e12331fda.zip from cache
  - Loading sebastian/object-reflector (2.0.4) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/object-enumerator/da625947c9c4e28182677035866359692138e8aa.zip from cache
  - Loading sebastian/object-enumerator (4.0.4) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/global-state/0e5ddb0d4b52354939573cb0bb88e1649abb6092.zip from cache
  - Loading sebastian/global-state (5.0.2) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/exporter/3059ffbb2cf2e94d0557e67083a0226f56cb5fd3.zip from cache
  - Loading sebastian/exporter (4.0.3) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/environment/5b02ed0c6fa1b48da50aa7ca582f6d377a29becb.zip from cache
  - Loading sebastian/environment (5.1.3) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/diff/527dd851ed7cdbd6b86e440441567b594e489fde.zip from cache
  - Loading sebastian/diff (4.0.4) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/comparator/a3f1223b57dac9c414046a660ab1a23f1f344f6e.zip from cache
  - Loading sebastian/comparator (4.0.6) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/code-unit/2175508c3a7c4f57c236668e95692cb4f230ef7e.zip from cache
  - Loading sebastian/code-unit (1.0.8) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/cli-parser/f4b297cc8d9ba3ba47f6d1c84b9d69bac882a7b1.zip from cache
  - Loading sebastian/cli-parser (1.0.1) from cache
Reading /home/vagrant/.cache/composer/files/phpunit/php-timer/b71ded866a460bbdb922b5eb818f4ed163f38f0c.zip from cache
  - Loading phpunit/php-timer (5.0.3) from cache
Reading /home/vagrant/.cache/composer/files/phpunit/php-text-template/b8d58f7d3789d6fd84cb6a82ebcb5776ab609787.zip from cache
  - Loading phpunit/php-text-template (2.0.4) from cache
Reading /home/vagrant/.cache/composer/files/phpunit/php-invoker/18d90380b8ff6f566265ca070b4bcfe4c4bbd34c.zip from cache
  - Loading phpunit/php-invoker (3.1.1) from cache
Reading /home/vagrant/.cache/composer/files/phpunit/php-file-iterator/5bd203e65744f1e8bcc7820585ce391634da9941.zip from cache
  - Loading phpunit/php-file-iterator (3.0.5) from cache
Reading /home/vagrant/.cache/composer/files/theseer/tokenizer/fe55275cb80f4ed8a2e3061ab3cd552e5d0a2677.zip from cache
  - Loading theseer/tokenizer (1.2.0) from cache
Reading /home/vagrant/.cache/composer/files/nikic/php-parser/1d0bf98e90cc41dc9068d1d15d0227b11aeed1a2.zip from cache
  - Loading nikic/php-parser (v4.10.5) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/lines-of-code/c83c674fbb96cf1b9525472250a2ec5c8e7784d6.zip from cache
  - Loading sebastian/lines-of-code (1.0.3) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/complexity/76ac0bc95bb26576a1588ac4917fe13f3107573f.zip from cache
  - Loading sebastian/complexity (2.0.2) from cache
Reading /home/vagrant/.cache/composer/files/sebastian/code-unit-reverse-lookup/68fb878dfd88a53caa52899dcad6f00ede9925b2.zip from cache
  - Loading sebastian/code-unit-reverse-lookup (2.0.3) from cache
Reading /home/vagrant/.cache/composer/files/phpunit/php-code-coverage/c12c915529923a21a38e683af26a0fae1873878d.zip from cache
  - Loading phpunit/php-code-coverage (9.2.6) from cache
Reading /home/vagrant/.cache/composer/files/doctrine/instantiator/1bd58de5714a9e86c1658357a6b9b2d18677b65b.zip from cache
  - Loading doctrine/instantiator (1.4.0) from cache
Reading /home/vagrant/.cache/composer/files/phpspec/prophecy/e820319a99d3b1c27e2f79dd4c6ce1f76f0463db.zip from cache
  - Loading phpspec/prophecy (1.13.0) from cache
Reading /home/vagrant/.cache/composer/files/phar-io/version/b33eb1f8e09407605e037d4efa300642a6b6228a.zip from cache
  - Loading phar-io/version (3.1.0) from cache
Reading /home/vagrant/.cache/composer/files/phar-io/manifest/9e9c1f9de1a020a5b076e3bc8b108524880a86e3.zip from cache
  - Loading phar-io/manifest (2.0.1) from cache
Reading /home/vagrant/.cache/composer/files/myclabs/deep-copy/6cd2033a8224fe330c425e4a15202a6d42643dfc.zip from cache
  - Loading myclabs/deep-copy (1.10.2) from cache
Reading /home/vagrant/.cache/composer/files/phpunit/phpunit/11dd52c02e21da3385acb77e22b7298c9106a7dd.zip from cache
  - Loading phpunit/phpunit (9.5.4) from cache
Reading /home/vagrant/.cache/composer/files/symfony/polyfill-php80/0ffa6133554e0bfbd5515a040b34c27f04612884.zip from cache
  - Loading symfony/polyfill-php80 (v1.22.1) from cache
Reading /home/vagrant/.cache/composer/files/ralouphie/getallheaders/ddc5f4c7ab3d868f5060717336a0d93475d53175.zip from cache
  - Loading ralouphie/getallheaders (3.0.3) from cache
Reading /home/vagrant/.cache/composer/files/psr/http-message/cc1d4e9ee13f2053b80c08976256789bf3be5256.zip from cache
  - Loading psr/http-message (1.0.1) from cache
Reading /home/vagrant/.cache/composer/files/psr/http-factory/554dafa2f4680a78fa693cedcbe62bc6873809db.zip from cache
  - Loading psr/http-factory (1.0.1) from cache
Reading /home/vagrant/.cache/composer/files/fig/http-message-util/69466af17bb895e9c0ccc43c6828ba40608a4f07.zip from cache
  - Loading fig/http-message-util (1.1.5) from cache
Reading /home/vagrant/.cache/composer/files/slim/psr7/13f048c6d386055b62a0e7e4be180a19f518ce8f.zip from cache
  - Loading slim/psr7 (1.4) from cache
Reading /home/vagrant/.cache/composer/files/psr/http-server-handler/3e4398b37dd092bb1f62653d8810cab13c6028a2.zip from cache
  - Loading psr/http-server-handler (1.0.1) from cache
Reading /home/vagrant/.cache/composer/files/psr/http-server-middleware/191b7f9e08d6b4893ea296f41c5385246a7fe3c5.zip from cache
  - Loading psr/http-server-middleware (1.0.1) from cache
Reading /home/vagrant/.cache/composer/files/nikic/fast-route/9fc18cb64621a29fa485259432d1c2676733e347.zip from cache
  - Loading nikic/fast-route (v1.3.0) from cache
Reading /home/vagrant/.cache/composer/files/slim/slim/808fb7395122dc559235cbc69c57b101abe6d638.zip from cache
  - Loading slim/slim (4.7.1) from cache
  - Installing phpstan/phpstan (0.12.88): Extracting archive
Executing async command (CWD): unzip -qq  '/vagrant/code/repos/test/vendor/composer/tmp-7ab24c34477f823a7e675802200d6d6a' -d '/vagrant/code/repos/test/vendor/composer/42fbfa47'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phpstan/phpstan'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/composer/42fbfa47'
    Install of phpstan/phpstan failed
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phpstan/extension-installer'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/jangregor/phpstan-prophecy'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/psr/log'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/monolog/monolog'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/psr/container'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/php-di/phpdoc-reader'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/php-di/invoker'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/opis/closure'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/php-di/php-di'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/symfony/polyfill-ctype'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/webmozart/assert'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phpdocumentor/reflection-common'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phpdocumentor/type-resolver'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phpdocumentor/reflection-docblock'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/version'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/type'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/resource-operations'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/recursion-context'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/object-reflector'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/object-enumerator'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/global-state'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/exporter'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/environment'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/diff'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/comparator'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/code-unit'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/cli-parser'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phpunit/php-timer'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phpunit/php-text-template'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phpunit/php-invoker'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phpunit/php-file-iterator'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/theseer/tokenizer'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/nikic/php-parser'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/lines-of-code'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/complexity'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/sebastian/code-unit-reverse-lookup'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phpunit/php-code-coverage'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/doctrine/instantiator'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phpspec/prophecy'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phar-io/version'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phar-io/manifest'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/myclabs/deep-copy'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/phpunit/phpunit'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/symfony/polyfill-php80'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/ralouphie/getallheaders'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/psr/http-message'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/psr/http-factory'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/fig/http-message-util'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/slim/psr7'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/psr/http-server-handler'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/psr/http-server-middleware'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/nikic/fast-route'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/composer/'
Executing command (CWD): rm -rf '/vagrant/code/repos/test/vendor/slim/slim'
Downloading https://packagist.org/downloads/
[201] https://packagist.org/downloads/
Reading ./composer.json (/vagrant/code/repos/test/composer.json)
Loading config file /home/vagrant/.config/composer/config.json
Loading config file /home/vagrant/.config/composer/auth.json
Loading config file ./composer.json (/vagrant/code/repos/test/composer.json)
Reading /home/vagrant/.config/composer/composer.json
Loading config file /home/vagrant/.config/composer/config.json
Loading config file /home/vagrant/.config/composer/auth.json
Loading config file /home/vagrant/.config/composer/composer.json (/home/vagrant/.config/composer/composer.json)
Loading config file /home/vagrant/.config/composer/auth.json
Reading /home/vagrant/.config/composer/auth.json


  [ErrorException]
  file_get_contents(/vagrant/code/repos/test/vendor/phpstan/phpstan/phpstan.phar): Failed to open stream: No such fil
  e or directory


Exception trace:
 () at phar:///usr/local/bin/composer/src/Composer/Installer/BinaryInstaller.php:194
 Composer\Util\ErrorHandler::handle() at n/a:n/a
 file_get_contents() at phar:///usr/local/bin/composer/src/Composer/Installer/BinaryInstaller.php:194
 Composer\Installer\BinaryInstaller->generateUnixyProxyCode() at phar:///usr/local/bin/composer/src/Composer/Installer/BinaryInstaller.php:167
 Composer\Installer\BinaryInstaller->installUnixyProxyBinaries() at phar:///usr/local/bin/composer/src/Composer/Installer/BinaryInstaller.php:161
 Composer\Installer\BinaryInstaller->installSymlinkBinaries() at phar:///usr/local/bin/composer/src/Composer/Installer/BinaryInstaller.php:88
 Composer\Installer\BinaryInstaller->installBinaries() at phar:///usr/local/bin/composer/src/Composer/Installer/LibraryInstaller.php:144
 Composer\Installer\LibraryInstaller->Composer\Installer\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/FulfilledPromise.php:20
 React\Promise\FulfilledPromise->then() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:74
 React\Promise\Deferred->React\Promise\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:166
 React\Promise\Deferred->processQueue() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:95
 React\Promise\Deferred->resolve() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/FulfilledPromise.php:20
 React\Promise\FulfilledPromise->then() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:76
 React\Promise\Deferred->React\Promise\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:166
 React\Promise\Deferred->processQueue() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:95
 React\Promise\Deferred->resolve() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/FulfilledPromise.php:20
 React\Promise\FulfilledPromise->then() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:76
 React\Promise\Deferred->React\Promise\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:166
 React\Promise\Deferred->processQueue() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:95
 React\Promise\Deferred->resolve() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/FulfilledPromise.php:20
 React\Promise\FulfilledPromise->then() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:76
 React\Promise\Deferred->React\Promise\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:166
 React\Promise\Deferred->processQueue() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Deferred.php:95
 React\Promise\Deferred->resolve() at phar:///usr/local/bin/composer/vendor/react/promise/src/React/Promise/Promise.php:42
 React\Promise\Promise->React\Promise\{closure}() at n/a:n/a
 call_user_func() at phar:///usr/local/bin/composer/src/Composer/Util/ProcessExecutor.php:295
 Composer\Util\ProcessExecutor->countActiveJobs() at phar:///usr/local/bin/composer/src/Composer/Util/Loop.php:96
 Composer\Util\Loop->wait() at phar:///usr/local/bin/composer/src/Composer/Installer/InstallationManager.php:457
 Composer\Installer\InstallationManager->waitOnPromises() at phar:///usr/local/bin/composer/src/Composer/Installer/InstallationManager.php:441
 Composer\Installer\InstallationManager->executeBatch() at phar:///usr/local/bin/composer/src/Composer/Installer/InstallationManager.php:368
 Composer\Installer\InstallationManager->downloadAndExecuteBatch() at phar:///usr/local/bin/composer/src/Composer/Installer/InstallationManager.php:267
 Composer\Installer\InstallationManager->execute() at phar:///usr/local/bin/composer/src/Composer/Installer.php:707
 Composer\Installer->doInstall() at phar:///usr/local/bin/composer/src/Composer/Installer.php:544
 Composer\Installer->doUpdate() at phar:///usr/local/bin/composer/src/Composer/Installer.php:247
 Composer\Installer->run() at phar:///usr/local/bin/composer/src/Composer/Command/CreateProjectCommand.php:241
 Composer\Command\CreateProjectCommand->installProject() at phar:///usr/local/bin/composer/src/Composer/Command/CreateProjectCommand.php:156
 Composer\Command\CreateProjectCommand->execute() at phar:///usr/local/bin/composer/vendor/symfony/console/Command/Command.php:245
 Symfony\Component\Console\Command\Command->run() at phar:///usr/local/bin/composer/vendor/symfony/console/Application.php:835
 Symfony\Component\Console\Application->doRunCommand() at phar:///usr/local/bin/composer/vendor/symfony/console/Application.php:185
 Symfony\Component\Console\Application->doRun() at phar:///usr/local/bin/composer/src/Composer/Console/Application.php:310
 Composer\Console\Application->doRun() at phar:///usr/local/bin/composer/vendor/symfony/console/Application.php:117
 Symfony\Component\Console\Application->run() at phar:///usr/local/bin/composer/src/Composer/Console/Application.php:122
 Composer\Console\Application->run() at phar:///usr/local/bin/composer/bin/composer:63
 require() at /usr/local/bin/composer:24

create-project [-s|--stability STABILITY] [--prefer-source] [--prefer-dist] [--repository REPOSITORY] [--repository-url REPOSITORY-URL] [--add-repository] [--dev] [--no-dev] [--no-custom-installers] [--no-scripts] [--no-progress] [--no-secure-http] [--keep-vcs] [--remove-vcs] [--no-install] [--ignore-platform-req IGNORE-PLATFORM-REQ] [--ignore-platform-reqs] [--ask] [--] [<package>] [<directory>] [<version>]

The file_get_contents messages indicates to me that (again) composer is trying to locate something which isn't there yet, so probably the file system again?

But I'm no expert here, maybe you can point me in the right direction if that's a Composer issue or something else?

@Seldaek
Copy link
Member

Seldaek commented May 20, 2021

@hochleitner 8427b6c hopefully fixes it for the binaries too. Can you check with composer self-update --snapshot?

@hochleitner
Copy link

@Seldaek: I updated to 6f255d1 and the slim-skeleton installs fine with all the dev dependencies (most importantly phpstan). Thanks for the quick fix!

@luispabon
Copy link

luispabon commented Sep 4, 2021

This issue is about to get more prevalent for business mac users as docker desktop is becoming a paid product and potentially users start using docker via vagrant again. I'm finding this problem right now in such a setup. The fix above doesn't work because composer is being run within a container and I imagine composer cannot detect we're in a VM this way.

@rpkamp
Copy link

rpkamp commented Oct 10, 2021

@luispabon have you tried setting the env variable COMPOSER_RUNTIME_ENV to virtualbox ?

@netsushi
Copy link

Use this command for creating new symfony projects or using composer in general:

COMPOSER_RUNTIME_ENV=virtualbox composer create-project symfony/skeleton new-project --no-interaction

main thing is to set COMPOSER_RUNTIME_ENV to virtualbox

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests