-
-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
Invalid cache directory when user name contains an umlaut #10434
Comments
You can do a fresh install with instructions from https://getcomposer.org/download/
Please check if 2.1.14 works, and ideally if you can check versions in between (2.2.0, 2.2.1, ..) to identify which one exactly broke this that would be great. Can you also check what It'd be good to get more details, what env you are in, what error you see, etc. |
I run the tests as mentioned. Version 2.1.14 works fine. The error comes with version 2.2.0. Message: echo $Env:LOCALAPPDATA still outputs C:\Users\Günter\AppData\Local My current php version is 8.0.7 |
OK could you check/share what It's the only clue I have as to what would have caused a change here in 2.2 right now |
The output is fine. array(1) { |
Uhh those first two make no sense to me.. can you put this in a test.php file and run it from CLI?
|
Now I'm surprised. C:\Daten\WebRoot\test>php test.php |
Ahh. OK so $_SERVER has the wrong info in it somehow, that makes sense as we started reading from $_SERVER as well as getenv in 2.2.. I wonder if that's a PHP bug then. |
Can you try/check if you have |
It's in uppercase. |
In powershell I get this:
cmd.exe too:
in bash/WSL it works fine though:
So it does appear to be a PHP-on-Windows bug. I filed a report on php/php-src#7896 - let's see if someone else has more of a clue. Otherwise I'll have to try and make a workaround in Composer. |
@gpoehl please try again after a |
@Seldaek , [ErrorException] Can I delete the globally installed version, then install version 2.1.14 and after this run the self-update --snapshot? |
Yes sure that'll work |
Sorry that I've come back with another question. |
See #10434 (comment) there's a |
I installed composer using the exe installer and replaced the composer.phar file within the 'programData\ComposerSetup\bin' directory. So I had a clean 2.1.14 version. The snapshot itself solved the problem. |
@Seldaek , C:>composer -V C:>composer self-update --rollback In SelfUpdateCommand.php line 405: Composer rollback failed: no installation to roll back to in "C:/Users/Gnter/AppData/Roaming/Composer" self-update [-r|--rollback] [--clean-backups] [--no-progress] [--update-keys] [--stable] [--preview] [--snapshot] [--1] [--2] [--set-channel-only] [--] [] C:>composer -V |
OK that I cannot make any sense of :s |
|
Oh god.. I still had some other version of the workaround in my test file so I did not notice that 🤯 But then the snapshot did not fix anything at all.. Anyway fixing again, better |
I can confirm that version 2.2.4 solved the problem. My previous assumtion, that your first fix alredy solved the problem, might have been wrong. It looks like that I run the tests in a powershell with administrator rights. The snapshot version created a new user in the user directory and run without providing an error message. |
After self-update to version 2.2.3 composer ignores existing umlaut in a user name.
EG: User name is Günter
Before the self update the directory
C:/Users/Günter/AppData/Local/Composer/files/
was used.
Now it is
C:/Users/Gnter/AppData/Local/Composer/files/
So it is not even posssible to rollback to the previous version.
The text was updated successfully, but these errors were encountered: