Composer TransportException translation file could not be written - laravel

I am installing laravel 4 and running "composer install" command. It was able to install 13 packages successfully, but when it came time to install symfony/translation, it downloaded it 100% and then threw an error:
[Composer\Downloader\TransportException] The "https://api.github.com/repos/symfony/Translation/zipball/6bc4b753c1ae5640c0eacdbe27c04a69cde3d10d" appears broken, and returned an empty 200 response
Could it be because the original is 0 bytes? Is there a work around to installing this package?

Dropping in to confim that I'm seeing this too so I guess I can stop panicking now as it seems to be an error somewhere between Packagist and Github (still a problem to my boss but something to be said for it not being your fault!)
edit: I'm having this issue with kriswallsmith / assetic running Symfony 2.1.9
update: Received an email from Github support indicating this is an issue that they are aware of and are actively looking into it.
I've just added the '--prefer-source' flag until the issue is resolved on their end.

I had this problem for twitter bootstrap:
[Composer\Downloaded\TransportException]
The "https://api.github.com/repos/twitter/bootstrap/zipball/v2.3.1" file could not be written to /my/path/Symfony/vendor/twitter/bootstrap/e01f28f3c03a11c104bae8d4a1b59d21.1:
Doing "composer self-update" changed it to:
[Composer\Downloader\TransportException]
"https://api.github.com/repos/twitter/bootstrap/zipball/v2.3.1" appears broken, and returned an empty 200 response
Using "composer update --prefer-source" seems to have installed it properly.
So it looks like github zip file download is broken.

Related

Composer - RuntimeException in RootPackageLoader after laminas-migration

I have a strange issue with composer. Having installed as per website docs, and has been working perfectly for days. Updating a zf2 project to laminas. All seemed to be ok after a successful use of laminas-migrate. Updated the new laminas dependencies and was asked to inject Laminas\ComposerAutoloading into my modules.config.php - all ok. After that, i've been getting the following message when i run composer update:
RootPackageLoader.php line 162:
[RuntimeException]
require.laminas/laminas-di is invalid, it should have a vendor name, a forward slash, and a package name. The vendor and package name can be words separated by -, . or _. The complete name should match "^a-z0-9/a-z0-9$".
This even happens if i am in my project dir and run composer -V.
Strangely, if i cd / then run composer -V, i get the correct output (composer version without the RootPackageLoader exception).
I have deleted composer from /usr/local/bin and reinstalled, issue persists.
After a few evenings of going round in circles, i ended up deleting the whole project and starting afresh. This time, there were none of the above issues with laminas-migrate. The only thing i did differently was to run laminas-migrate on the project straight out of the repo, instead of trying to update all the packages to as-close-to-zf3 before migrating to laminas. Seemed to work fine.

How to fix npm Error "timed out" after npm update

We have a React app, based on the Hydrogen theme for Shopify (which uses vite). It was all working ok until I had to add a package and update. It then started giving the following message: Error timed out. That is it, no other error message, I looked in the logs and there was nothing remarkable in there.
I tried removing the package, and all references to it in the code. But it looks like the issue may well have been the update command. But being rather new to React and npm on Windows, I have no idea how to fix it. Things that I did try were clearing the cache using:
npm cache clean --force
Doing another update. Removing the lock file.
Does anyone have a suggestion as to a method to debug that one-line error code, or could point me in the right direction? I am running on localhost, via Windows 10.
npm error timed out image
My problem must have been a broken dependency. After a day or so of trying updates, it eventually just started working again. The update that actually worked had some vulnerabilities, so I ran an:
npm audit fix
After the npm audit fix, the code started running correctly again.

Why can't SnowSQL 1.2.2 find a version to download?

First thing I do after unpacking the SnowSQL Linux client is try to upgrade it. This has worked very well through at least v1.1.84. Today I downloaded v1.2.2, installed it, and got an error:
$ ~/bin/snowsql -Uv
No snowsql is available for download: url=https://sfc-repo.snowflakecomputing.com/snowsql, version=1.2
The error comes from this download. Has something changed? I get the same error even when I just try to use it with no options at all, or trying to connect by passing my account code and username.
The curl above was missing https and hence gave the wrong impression of 403 forbidden.
Some times due to a caching issue with the downloads it will not autoupgrade. There are two main components, one being bootstrap and the other one being the main snowsql component. The one you see the issue with is the main component (it is auto-downloaded when you run snowsql).
You can force new version download using snowsql -v 1.2.2 as an exmaple.
You can delete/move the .snowsql directory (~/.snowsql or ~/bin/.snowsql) to ensure a new main component version is downloaded by the new bootstrap.
You may also try using the newer versions for which the rpm is available at
https://sfc-repo.snowflakecomputing.com/snowsql/bootstrap/1.2/linux_x86_64/index.html
I noticed Snowflake has some weird firewall configs and similar errors can either happen consistently or intermittently.
The only option I'm aware of that can help if it happens consistently is to use --noup flag with your commands. This will not check for snowsql updates of course, but you can always manually download a newer version via your browser(with VPN is needed).

Update joomla 3.4.5 to 3.7.5 and get error 500

I have tried to update from 3.4.5 to 3.7.5 but only get error 500 when I press the button. I have tried to import the update as a zip file, but then I got errormessage 403 access denied. When I tried to update whit the tar.bz2 file I got errormessage:
COM_INSTALLER_MSG_INSTALL_WARNINSTALLUPLOADERROR
I using PHP version 5.4.45 and MySQL version 5.1.73.
How do I update my Joomlapage?
These are possible causes:
Check your options on Admin Tools or any other security/firewall extensions you have. Since this is a one time install, you might just try disabling the entire component/plugin for a minute to run upgrade.
Check your .htaccess file. Again, you can just temporarily remove and try to run upgrade.
Your PHP version might contribute as well since Joomla 3.7 recommends PHP 5.6+: https://downloads.joomla.org/us/technical-requirements-us

Class 'Stripe\Stripe' not found error in PHP

I installed laravel and composer and created my first project in laravel. I want to integrate stripe using PHP. When I try to execute my first project in localhost I take this message:
Fatal error: Class 'Stripe\Stripe' not found in C:\xampp\htdocs\laravel\stripe\public\elda.php on line 21
To include the stripe libraries, I inserted inside the composer.json file the code from the API library for PHP. Here is an image of my composer.json file:
I run composer install in cmd and this is the output:
You may be getting outdated dependencies. Run update to update them.
I run composer update and the output is the error in the image below:
Can someone help me to solve this error?
Well, sorry did not make a comment of your post, but I have not enough points to do so. But you need to run composer install in the terminal after that includes a new package.
I had the same issue, but when I ran this command my issue is resolved.
composer require stripe/stripe-php
I hope this may help you, after you update your composer.

Resources