I'm attempting to login to Laravel Vapor CLI in order to get started, but it fails without messages.
According to documentation, I should run the command vapor login
but when running this command, the script aborts without giving any error messages and also no way of typing Email Address or Password.
I'm on Windows 10, using Laravel 6.3, vapor-cli 1.4, vapor-core 2.2, PHP 7.4.
I have already followed this SO question and answer, but without success. I tried the similar approach installing OpenSSL using Chocolatey - although it's not the actual authentication that fails, because in my case, it never gives me the chance to enter credentials.
I eventually found the solution, and I hope this will help others.
This error is caused by a problem in the release of PHP 7.4 and is relevant for Windows users only.
The solution, which solved it for me, was to install a newer dev-version of PHP 7.4, where the problem has been identified and solved.
The links used to find the solution are:
https://github.com/symfony/symfony/issues/34754 [Aborted] at \vendor\symfony\console\Helper\QuestionHelper.php:137 https://github.com/symfony/symfony/issues/34702 Interactive console aborted on: Windows PHP 7.4.0 (only) https://github.com/php/php-src/pull/4952 Fix #78883: fgets(STDIN) fails on Windows https://bugs.php.net/bug.php?id=78883 Bug #78883fgets(STDIN) fails on Windows
The PHP build where the problem is solved is found here:
https://windows.php.net/downloads/snaps/php-7.4/r996f217/
After setting up this PHP build, I ran the 'vapor login' command again. This threw a cURL SSL Certificate error, which I solved using the following solution:
https://github.com/guzzle/guzzle/issues/1935 provided by pan-christensen.
The authentication was now successful.