Support Forum
I'm trying to use composer to load a premium extension for the first time following these instructions https://docs.metabox.io/integration/#using-composer. Note in the below I have removed my actual license key for obvious reasons.
My composer.json file works if I only try for free extensions but when I run composer install or update I get this error:
curl error 23 while downloading https://packages.metabox.io/packages.php?key=<my-key>: Failed writing received data to disk/application
This is my composer.json file:
{
"repositories":[
{
"type": "composer",
"url": "https://wpackagist.org"
},
{
"type": "composer",
"url": "https://packages.metabox.io/<my-key>"
}
],
"require": {
"wpackagist-plugin/meta-box": "^5",
"wpackagist-plugin/mb-settings-page": "dev-master"
},
"extra": {
"installer-paths": {
"vendor/meta-box/{$name}": [
"vendor:wpackagist-plugin",
"vendor:meta-box"
]
}
},
"autoload": {
"files": [
"vendor/meta-box/meta-box/meta-box.php",
"vendor/meta-box/mb-settings-page/mb-settings-page.php"
]
},
"config": {
"allow-plugins": {
"composer/installers": true
}
}
Anyone know what could cause this?
Hello Jai,
I check the composer feature on my local site but don't see that issue. Please double-check the key on your account and ensure it is correct.
Thanks for your reply Peter.
The key definitely is fine as I have it working on multiple sites. But to make sure I generated a new one and tried that and got the same error.
Hello,
It could be a permission issue. Please get in touch with your hosting support and ask them for more information about the error "curl error 23" when downloading a premium plugin from the URL https://packages.metabox.io/
Also, please share a screen record of the steps you do on your end.
Thanks Peter.
This curl error is returned running composer in my local dev environment. There isn't hosting involved.
To clarify, I'm running the composer command from my local terminal and getting that error.
Hello,
Can you share a screen record of steps you do on the local site?
Hi, I managed to fix this and thought I'd put the answer here for anyone else that comes across it.
Short answer is found on this page https://github.com/composer/composer/issues/11913
Seems that something with the a curl version installed on my Mac. Updating curl fixed it. Doesn't seem to have been the fix for everyone.
In particular this problem only happened when trying to download and install the premium extensions.
Thanks for sharing the solution.