It's not in my composer.lock
file except as a dev dependency of other packages, i.e. it's not installed separately.
I've just tested this with 3.1.48 and PHP 8.2.4 and the problem persists.
Issue #210 test update (#211)
Initial ci update, determine if core images will work without refactoring source
github actions script update, move 8.1 from exp to supported; add 8.2 as exp
Fix coding standards and add 8.2 as supported.
Correct error
Coding standards
stds
Update CI config
Update config image
force file creation
adding command
undo prev changes
updating image
Move require statement
Fix coding stds error
coding stds
This is still an issue, please reopen.
I just got to me that PHPMailer no longer can connect to the smtp server.
2023-03-21 14:07:28 SMTP ERROR: Failed to connect to server: Connection refused (111) SMTP Error: Could not connect to SMTP host. Failed to connect to server Message could not be sent. Mailer Error: SMTP Error: Could not connect to SMTP host. Failed to connect to serverSMTP server error: Failed to connect to server SMTP code: 111 Additional SMTP info: Connection refused
I have websites on diffrent webhosts with diffrent mailservers and its the same problem on everyone. No change has been made in the PHP version or on the log in information for the mail accounts.
"Connection refused" means what it says – the mail server, or the network it's on, rejected your attempt at connecting to it. It suggests your hosting provider(s) have decided to block outbound SMTP, which is a very common thing to do, and has nothing to do with PHPMailer. What results did you get when you tried the tests in the troubleshooting guide?
Please could you tag a release for this? Otherwise we can't get at it through composer updates.
That's a big improvement, thanks, and it gets much further than before, but eventually fails in the same way in phpcs, line 608 of Runner.php, crc32 check failed in various bits of phpcs.
[10.x] Add replace_placeholders to log channels (#6139)
add replace_placeholders to log channels
Update logging.php
Co-authored-by: Taylor Otwell taylor@laravel.com
Merge branch 'laravel:10.x' into guzzle-bump
Thanks Jordi, I'll be your edge case! The upstream package concerned is about to release an updated version anyway, so I won't have to use my patched repo any more.
My comments in [].
Warning: require(/PHPMailer/src/Exception.php): Failed to open stream: No such file or directory in /Library/WebServer/Documents/sites/cognitorum/sendPHPMailer.php on line 7 — [in fact, there is one for Exeption.php]
Fatal error: Uncaught Error: Failed opening required '/PHPMailer/src/Exception.php' (include_path='.:/opt/homebrew/Cellar/php/8.2.3/share/php/pear') — [the path is correct, although in fact it starts from '/'] — in /Library/WebServer/Documents/sites/cognitorum/sendPHPMailer.php:7 Stack trace: #0 {main} thrown in /Library/WebServer/Documents/sites/cognitorum/sendPHPMailer.php on line 7
// Load PHPMailer
use PHPMailer\PHPMailer\PHPMailer; use PHPMailer\PHPMailer\Exception;
require '/PHPMailer/src/Exception.php'; require '/PHPMailer/src/PHPMailer.php'; require '/PHPMailer/src/SMTP.php';
You're using absolute paths when they should be relative. Try removing the leading / from them to start with. This would also be a good time to learn how to use composer.
The one linked from the readme, the error messages, the front page of this project, the wiki, the issue template you deleted, the first result on Google if you search for it. https://github.com/PHPMailer/PHPMailer/wiki/Troubleshooting
1.0.2 doesn't break on composer update
as 1.0.1 did, but running it crashes like this:
Linting using TLint
Lints for /Users/marcus/Sites/myall/database/migrations/2023_02_02_084149_add_daily_inbound.php
============
! Prefer `Namespace\...` over `\Namespace\...`.
31 : ` ->default(\App\Enums\LogisticsStatus::SCHEDULED->value);`
Lints for /Users/marcus/Sites/myapp/database/migrations/2020_03_09_073326_add_payment_fields.php
============
! Prefer `Namespace\...` over `\Namespace\...`.
18 : ` ->default(\App\Models\User::PAYMENT_STATUS_UNSET)`
! Prefer `Namespace\...` over `\Namespace\...`.
50 : ` ->default(\App\Models\User::PAYMENT_STATUS_NEW)`
Lints for /Users/marcus/Sites/myall/database/migrations/2021_11_04_113626_add_extra_fields_to_vouchers.php
============
! Prefer `Namespace\...` over `\Namespace\...`.
15 : ` ->default(\App\Enums\VoucherType::percentage());`
Linting using PHP_CodeSniffer
In Runner.php line 608:
Class "PHP_CodeSniffer\Exceptions\RuntimeException" not found
In Runner.php line 608:
include(phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/composer/../illuminate/view/Component.php): Failed to open stream: phar error: internal corrupt
ion of phar "/Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster" (crc32 mismatch on file "vendor/illuminate/view/Component.php") in phar:///Users/marcus/Sites/clubzero-
api/vendor/tightenco/duster/builds/duster/.box/vendor/composer/ClassLoader.php on line 571
In Runner.php line 608:
Class "PHP_CodeSniffer\Exceptions\RuntimeException" not found
In NullLogger.php line 13:
Class "Psr\Log\AbstractLogger" not found
In Runner.php line 608:
include(phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/squizlabs/php_codesniffer/src/Files/LocalFile.php): Failed to open stream: phar error: internal
corruption of phar "/Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster" (crc32 mismatch on file "vendor/squizlabs/php_codesniffer/src/Files/LocalFile.php") in phar:///
Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/squizlabs/php_codesniffer/autoload.php on line 169
In OpeningFunctionBraceBsdAllmanSniff.php line 143:
syntax error, unexpected token "<", expecting end of
That line 608 error is repeated many more times, interspersed with random snippets out of the phar. As you can see it's still reporting corruption of the phar.
my code
<?php
/**
* This example shows settings to use when sending via Google's Gmail servers.
* This uses traditional id & password authentication - look at the gmail_xoauth.phps
* example to see how to use XOAUTH2.
* The IMAP section shows how to save this message to the 'Sent Mail' folder using IMAP commands.
*/
//Import PHPMailer classes into the global namespace
use PHPMailer\PHPMailer\PHPMailer;
use PHPMailer\PHPMailer\SMTP;
require 'C:\Users\*******\vendor\autoload.php';
//Create a new PHPMailer instance
$mail = new PHPMailer();
//Tell PHPMailer to use SMTP
$mail->isSMTP();
//Enable SMTP debugging
//SMTP::DEBUG_OFF = off (for production use)
//SMTP::DEBUG_CLIENT = client messages
//SMTP::DEBUG_SERVER = client and server messages
$mail->SMTPDebug = SMTP::DEBUG_SERVER;
//Set the hostname of the mail server
$mail->Host = 'smtp.gmail.com';
//Use `$mail->Host = gethostbyname('smtp.gmail.com');`
//if your network does not support SMTP over IPv6,
//though this may cause issues with TLS
//Set the SMTP port number:
// - 465 for SMTP with implicit TLS, a.k.a. RFC8314 SMTPS or
// - 587 for SMTP+STARTTLS
$mail->Port = 587;
//Set the encryption mechanism to use:
// - SMTPS (implicit TLS on port 465) or
// - STARTTLS (explicit TLS on port 587)
$mail->SMTPSecure = PHPMailer::ENCRYPTION_SMTPS;
//Whether to use SMTP authentication
$mail->SMTPAuth = true;
//Username to use for SMTP authentication - use full email address for gmail
$mail->Username = ********@gmail.com';
//Password to use for SMTP authentication
$mail->Password = '********';
//Set who the message is to be sent from
//Note that with gmail you can only use your account address (same as `Username`)
//or predefined aliases that you have configured within your account.
//Do not use user-submitted addresses in here
$mail->setFrom('*********', 'First Last');
//Set an alternative reply-to address
//This is a good place to put user-submitted addresses
$mail->addReplyTo('replyto@example.com', 'First Last');
//Set who the message is to be sent to
$mail->addAddress('whoto@example.com', 'John Doe');
//Set the subject line
$mail->Subject = 'PHPMailer GMail SMTP test';
//Read an HTML message body from an external file, convert referenced images to embedded,
//convert HTML into a basic plain-text alternative body
$mail->msgHTML(file_get_contents('contents.html'), __DIR__);
//Replace the plain text body with one created manually
$mail->AltBody = 'This is a plain-text message body';
//Attach an image file
$mail->addAttachment('images/phpmailer_mini.png');
//send the message, check for errors
if (!$mail->send()) {
echo 'Mailer Error: ' . $mail->ErrorInfo;
} else {
echo 'Message sent!';
//Section 2: IMAP
//Uncomment these to save your message in the 'Sent Mail' folder.
#if (save_mail($mail)) {
# echo "Message saved!";
#}
}
//Section 2: IMAP
//IMAP commands requires the PHP IMAP Extension, found at: https://php.net/manual/en/imap.setup.php
//Function to call which uses the PHP imap_*() functions to save messages: https://php.net/manual/en/book.imap.php
//You can use imap_getmailboxes($imapStream, '/imap/ssl', '*' ) to get a list of available folders or labels, this can
//be useful if you are trying to get this working on a non-Gmail IMAP server.
function save_mail($mail)
{
//You can change 'Sent Mail' to any other folder or tag
$path = '{imap.gmail.com:993/imap/ssl}[Gmail]/Sent Mail';
//Tell your server to open an IMAP connection using the same username and password as you used for SMTP
$imapStream = imap_open($path, $mail->Username, $mail->Password);
$result = imap_append($imapStream, $path, $mail->getSentMIMEMessage());
imap_close($imapStream);
return $result;
}
Please read the troubleshooting guide you were pointed at.
Great news that you've merged that PR, thank you
Now I'm getting a different problem, also inside duster:
> Illuminate\Foundation\ComposerScripts::postAutoloadDump
Script Illuminate\Foundation\ComposerScripts::postAutoloadDump handling the post-autoload-dump event terminated with an exception
In autoload_real.php line 41:
require(/Users/marcus/Sites/myapp/vendor/composer/../tightenco/duster/vendor/squizlabs/php_codesniffer/autoload.php): Failed to open stream: No such file or directory
CKFinder bundles monolog 1.27.1; the latest version is 3.3.1. This is a problem because monolog 1.x is not compatible with the current spec of psr/log 3.0. This means it can't be used with PHP 8.2 as it leads to this fatal error:
Fatal error: Declaration of Monolog\Logger::emergency($message, array $context = []) must be compatible with Psr\Log\LoggerInterface::emergency(Stringable|string $message, array $context = []): void in public/ckfinder/core/connector/php/vendor/monolog/monolog/src/Monolog/Logger.php on line 780
Please update deps!
Yes, that runs fine.
I did have phpcs 3.7.2 installed already (but not the others), so I removed that, did a composer update
, but the problem remains. With -vvv
, I get more info. Just the first error here:
Box Requirements Checker
========================
> Using PHP 8.2.3
> PHP is using the following php.ini file:
/opt/homebrew/etc/php/8.2/php.ini
> Checking Box requirements:
✔ The application requires the version "^8.0" or greater.
✔ The application requires the extension "zlib".
[OK] Your system is ready to run the application.
Linting using TLint
Lints for /Users/marcus/Sites/myapp/database/migrations/2023_02_02_084149_add_daily_inbound.php
============
! Prefer `Namespace\...` over `\Namespace\...`.
31 : ` ->default(\App\Enums\LogisticsStatus::SCHEDULED->value);`
Lints for /Users/marcus/Sites/myapp/database/migrations/2020_03_09_073326_add_payment_fields.php
============
! Prefer `Namespace\...` over `\Namespace\...`.
18 : ` ->default(\App\Models\User::PAYMENT_STATUS_UNSET)`
! Prefer `Namespace\...` over `\Namespace\...`.
50 : ` ->default(\App\Models\User::PAYMENT_STATUS_NEW)`
Lints for /Users/marcus/Sites/myapp/database/migrations/2021_11_04_113626_add_extra_fields_to_vouchers.php
============
! Prefer `Namespace\...` over `\Namespace\...`.
15 : ` ->default(\App\Enums\VoucherType::percentage());`
In MailableMethodsInBuild.php line 29:
[ErrorException]
Undefined property: PhpParser\Node\Stmt\Nop::$expr
Exception trace:
at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/tightenco/tlint/src/Linters/MailableMethodsInBuild.php:29
Illuminate\Foundation\Bootstrap\HandleExceptions->handleError() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/laravel-zero/foundation/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php:266
Illuminate\Foundation\Bootstrap\HandleExceptions->Illuminate\Foundation\Bootstrap\{closure}() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/tightenco/tlint/src/Linters/MailableMethodsInBuild.php:29
Tighten\TLint\Linters\MailableMethodsInBuild->Tighten\TLint\Linters\{closure}() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/nikic/php-parser/lib/PhpParser/NodeVisitor/FindingVisitor.php:42
PhpParser\NodeVisitor\FindingVisitor->enterNode() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php:200
PhpParser\NodeTraverser->traverseArray() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php:114
PhpParser\NodeTraverser->traverseNode() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php:223
PhpParser\NodeTraverser->traverseArray() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php:114
PhpParser\NodeTraverser->traverseNode() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php:223
PhpParser\NodeTraverser->traverseArray() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php:91
PhpParser\NodeTraverser->traverse() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/tightenco/tlint/src/BaseLinter.php:37
Tighten\TLint\BaseLinter->visitUsing() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/tightenco/tlint/src/BaseLinter.php:44
Tighten\TLint\BaseLinter->traverseAutomatically() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/tightenco/tlint/src/BaseLinter.php:15
Tighten\TLint\BaseLinter->lint() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/tightenco/tlint/src/TLint.php:21
Tighten\TLint\TLint->lint() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/tightenco/tlint/src/Commands/LintCommand.php:120
Tighten\TLint\Commands\LintCommand->lintFile() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/tightenco/tlint/src/Commands/LintCommand.php:63
Tighten\TLint\Commands\LintCommand->execute() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/symfony/console/Command/Command.php:291
Symfony\Component\Console\Command\Command->run() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/symfony/console/Application.php:1014
Symfony\Component\Console\Application->doRunCommand() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/symfony/console/Application.php:301
Symfony\Component\Console\Application->doRun() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/symfony/console/Application.php:171
Symfony\Component\Console\Application->run() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/app/Support/TLint.php:40
App\Support\TLint->App\Support\{closure}() at n/a:n/a
array_map() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/illuminate/collections/Arr.php:560
Illuminate\Support\Arr::map() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/illuminate/collections/Collection.php:768
Illuminate\Support\Collection->map() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/app/Support/TLint.php:37
App\Support\TLint->process() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/app/Support/TLint.php:18
App\Support\TLint->lint() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/app/Actions/Clean.php:22
App\Actions\Clean->App\Actions\{closure}() at n/a:n/a
array_filter() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/illuminate/collections/Arr.php:830
Illuminate\Support\Arr::where() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/illuminate/collections/Collection.php:382
Illuminate\Support\Collection->filter() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/app/Actions/Clean.php:22
App\Actions\Clean->execute() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/app/Commands/LintCommand.php:22
App\Commands\LintCommand->handle() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/illuminate/container/BoundMethod.php:36
Illuminate\Container\BoundMethod::Illuminate\Container\{closure}() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/illuminate/container/Util.php:41
Illuminate\Container\Util::unwrapIfClosure() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/illuminate/container/BoundMethod.php:93
Illuminate\Container\BoundMethod::callBoundMethod() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/illuminate/container/BoundMethod.php:35
Illuminate\Container\BoundMethod::call() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/illuminate/container/Container.php:661
Illuminate\Container\Container->call() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/illuminate/console/Command.php:183
Illuminate\Console\Command->execute() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/symfony/console/Command/Command.php:291
Symfony\Component\Console\Command\Command->run() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/illuminate/console/Command.php:152
Illuminate\Console\Command->run() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/symfony/console/Application.php:1014
Symfony\Component\Console\Application->doRunCommand() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/symfony/console/Application.php:301
Symfony\Component\Console\Application->doRun() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/symfony/console/Application.php:171
Symfony\Component\Console\Application->run() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/illuminate/console/Application.php:102
Illuminate\Console\Application->run() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/laravel-zero/foundation/src/Illuminate/Foundation/Console/Kernel.php:155
Illuminate\Foundation\Console\Kernel->handle() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/laravel-zero/framework/src/Kernel.php:96
LaravelZero\Framework\Kernel->handle() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/app/DusterKernel.php:19
App\DusterKernel->handle() at phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/duster:34
require() at /Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster:14
include() at /Users/marcus/Sites/myapp/vendor/bin/duster:120
lint [--diff] [--json] [--only ONLY] [--] [<file or directory>]
Goodness. I'd forgotten about this, glad to see something being done about it!
I just installed Duster for the first time in a Laravel 9 + PHP 8.2 app that already has some phpcs rules enforced, so it's quite clean already. First of all phpcs run gets through some of the code, but then crashes:
In MailableMethodsInBuild.php line 89:
Undefined property: PhpParser\Node\Stmt\Nop::$expr
format [--diff] [--only ONLY] [--] [<file or directory>]
It then goes on to run PHP_CodeSniffer tasks, but immediately dies again showing many errors and spewing random source snippets. Too many errors to post here, but it starts like this:
Linting using PHP_CodeSniffer
&& $i === $this->tokens[$i]['parenthesis_opener']
) {
$i = $this->tokens[$i]['parenthesis_closer'];
} else if (
In Runner.php line 608:
include(phar:///Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/squizlabs/php_codesniffer/src/Files/File.php): Failed to open stream: phar error: internal corr
uption of phar "/Users/marcus/Sites/myapp/vendor/tightenco/duster/builds/duster" (crc32 mismatch on file "vendor/squizlabs/php_codesniffer/src/Files/File.php") in phar:///Users/marc
us/Sites/myapp/vendor/tightenco/duster/builds/duster/vendor/squizlabs/php_codesniffer/autoload.php on line 169
kens[$prev]['code'] === T_USE) {
return true;
}
}
}
While that crc mismatch suggests a corrupted file, these problems have persisted even after a composer reinstall '*'
. All this happens pretty much the same way with both lint
and fix
commands.
Any idea why this is breaking?
FWIW, I'm an open source maintainer, and I've been testing my packages on 8.3 development builds since December; libraries need to be ahead of PHP releases.
Something to tell your management if they need some incentive – we have had to temporarily disable our segment integration because of this issue.
I have a problem. I added the following lines to the config.php and config_extend file:
define('PHPMAILERHOST','smtp.nameserver.com:587'); define('PHPMAILER_SMTPUSER',''); define('PHPMAILER_SMTPPASS',''); define('PHPMAILERPORT', 587); define('PHPMAILER_SECURE', 'tls'); define('POP_BEFORE_SMTP', false);
**define('PHPMAILERTESTHOST','testsmtp.nameserver.com'); define('PHPMAILERBLASTHOST','nameserver.com'); define('PHPMAILERBLASTPORT',25);
define('SMTP_TIMEOUT',5); define('POPBEFORESMTP_DEBUG',false);**
But I still see SMTP errors in the event log. Can you please help me troubleshoot this issue? SMTP connect() failed when sending to [Please refer to https://github.com/PHPMailer/PHPMailer/wiki/Troubleshooting for assistance.
PHPMailer doesn't read global constants, so I have no idea what your code is doing. You also asked for troubleshooting advice while including a link that refers you to the troubleshooting guide which provides exactly that, so I suggest you go read that, and next time please read the issue template instead of just ignoring and deleting it.
That line contains:
$result[] = sprintf($message, $package, ' '.reset($versions));
The docs say that 3 args is ok, so I guess it may be because the format string refers to more than two params, and only two are given. The use of ' '.reset($versions)
seems odd – wouldn't it be clearer to cast to string explicitly?
I can't seem to add a var_dump()
in here to see what the values are because as soon as I edit the phar, it throws this error:
Fatal error: Uncaught PharException: manifest cannot be larger than 100 MB in phar "/opt/homebrew/Cellar/composer/2.5.4/bin/composer" in /opt/homebrew/Cellar/composer/2.5.4/bin/composer:28
Stack trace:
#0 /opt/homebrew/Cellar/composer/2.5.4/bin/composer(28): Phar::mapPhar('composer.phar')
#1 {main}
thrown in /opt/homebrew/Cellar/composer/2.5.4/bin/composer on line 28