BUG #18820: Issue with Installation Due to Space in User Profile Path

From: PG Bug reporting form <noreply(at)postgresql(dot)org>
To: pgsql-bugs(at)lists(dot)postgresql(dot)org
Cc: janrusselgorembalem4(at)gmail(dot)com
Subject: BUG #18820: Issue with Installation Due to Space in User Profile Path
Date: 2025-02-20 06:24:02
Message-ID: 18820-db99c7bd05fd92aa@postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

The following bug has been logged on the website:

Bug reference: 18820
Logged by: Jan Russel Gorembalem
Email address: janrusselgorembalem4(at)gmail(dot)com
PostgreSQL version: 17.3
Operating system: WINDOWS 10 (Windows x86-64)
Description:

Hello,

Good day! I am reaching out to report an issue I am encountering during the
installation process of PostgreSQL on my Windows machine.

While attempting to install, the process fails to proceed due to an error
related to the path of my user profile, specifically because my computer's
name contains a space. Here’s the error message I receive:

---
Error running C:\Windows\System32\Windows PowerShell\v1.0\powershell.exe
-Execution Policy Bypass-Command
"[System.Globalization.CultureInfo]::GetCultures([System.Globalization.CultureTypes]::AllCultures)
| Where-Object {S_.LCID-ne 127} | Sort-Object English Name | ForEach-Object
{S_.Name + '=' + S_.EnglishName} | Out-File -FilePath "C:\Users\this
pc\AppData\Local\Temp/postgresql_installer_d40df35311/locales.txt" -Encoding
UTF8": Out-File: A positional parameter
cannot be found that accepts argument
'pc\AppData\Local\Temp/postgresql_installer_d40df35311/locales.txt'.
At line: 1 char:215
+... ishName | Out-File-FilePath C:\Users\this pc\AppData\Local\Temp/po
+ CategoryInfo : InvalidArgument: (:) [Out-File],
ParameterBindingException
+ FullyQualified Errorld:
Positional ParameterNotFound, Microsoft.PowerShell.Commands.
OutFileCommand

"Out-File: A positional parameter cannot be found that accepts argument
'pc\AppData\Local\Temp/postgresql_installer_d40df35311/locales.txt'. "
---

As shown, the installer attempts to save the file to a path that contains a
space in the user name ("this pc"). The space seems to split the path into
two, causing the error.

Additionally, I have found a similar issue reported by another user, where
the user name includes a space, and the error message follows a very similar
pattern:

---
C:/WINDOWS/System32/WindowsPowerShell/v1.0/Powershell.exe -
ExecutionPolicyBypass -Command
"[System.Globalization.CultureInfo]::GetCultures([System.Globalization.CultureTypes]::AllCultures)
| Where-Object {$_.EnglisName} | Out-File-FilePath "C:/Users/Diego del
rio/AppData/Local/Temp/postgresql_installer_feece05004/locales.txt"
-Encoding UTF8": Out-File : A positional parameter cannot be found that
accepts argument 'del' . At line : 1 char 215 +....ishName } | Out-File
-FilePath C:/User/ Diego del Rio/AppData/Local/T... +~~~~~~~~~~
+CategoryInfo : InvalidArgument: (:) [Out-File], ParameterBidingException
+FullyQualifiedErrorId : PositionalParameterNotFound,
Microsoft.PowerShell.Commands.OutFileCommand

"Out-File : A positional parameter cannot be found that accepts argument
'del' "
---

As you can see, the issue seems to arise when the file path contains spaces
in the user or machine name.

Would you be able to provide guidance on how to resolve this issue? I
believe it may be related to how paths with spaces are being parsed by the
installer. Any help or workaround would be greatly appreciated.

Thank you for your time and support.

Best regards,
Jan Russel Gorembalem.

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Manika Singhal 2025-02-20 10:12:22 Re: BUG #18820: Issue with Installation Due to Space in User Profile Path
Previous Message Tom Lane 2025-02-19 21:55:52 Re: BUG #18815: Logical replication worker Segmentation fault