-
Notifications
You must be signed in to change notification settings - Fork 300
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
Cannot start powershell because of missing file on mac #3768
Comments
I cannot run the script because powershell will not even start. |
I there some directory I can remove / reset to resolve this? I removed /usr/local/share/poweshell too, and reinstalled and it's still the same error. |
If you are able to get a working prompt, you can run Have you tried searching for the file @daxian-dbw is this the known mutex issue on Mac? I can't figure out how to reproduce this. |
I have managed to run the command suggested. I have tried to find the file PSReadLineHistoryFile_2044101305 and cannot find it anywhere on the file system. Still the same error. |
Here is some of the output.
|
Since the reinstall all I have in ~/.local/share/powershell is an empty modules directory. Windows 1995 was easier than this. Powershell is still kind of working, but I get the missing file message every time I hit return. Having used various methods I am pretty sure that PSReadLineHistoryFile_2044101305.* does not exist. |
Is there a README or something online somewhere were I can try and remove every history or saved variable from powershell from everywhere and try install again from scratch. Very frustrating. |
Ah I found previous issues folks had with the same problem, check out #1464 (comment) and see if this works for you |
I really thought you had it there.
I deleted the powerlog folder in /tmp and that did not help either. |
Ok did the permissions changes on /private/tmp, and now it's working, many thanks after so many searches.
|
Prerequisites
Exception report
Screenshot
Oops, something went wrong.
Please report this bug with ALL the details below, including both the 'Environment' and 'Exception' sections.
Please report on GitHub: https://github.com/PowerShell/PSReadLine/issues/new?template=Bug_Report.yaml
Thank you!
Environment
PSReadLine: 2.2.6
PowerShell: 7.3.6
OS: Darwin 22.6.0 Darwin Kernel Version 22.6.0: Wed Jul 5 22:21:56 PDT 2023; root:xnu-8796.141.3~6/RELEASE_X86_64
BufferWidth: 80
BufferHeight: 24
Last 0 Keys:
Exception
System.IO.IOException: The system cannot open the device or file specified. : 'PSReadLineHistoryFile_2044101305'
at System.Threading.Mutex.CreateMutexCore(Boolean initiallyOwned, String name, Boolean& createdNew)
at System.Threading.Mutex..ctor(Boolean initiallyOwned, String name)
at Microsoft.PowerShell.PSConsoleReadLine.DelayedOneTimeInitialize()
at Microsoft.PowerShell.PSConsoleReadLine.Initialize(Runspace runspace, EngineIntrinsics engineIntrinsics)
at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics, CancellationToken cancellationToken, Nullable`1 lastRunStatus)
Environment data
PS Version 7.3.6
Steps to reproduce
Open powershell
Expected behavior
Powershell opens correctly.
Actual behavior
powershell fails with the above message.
The text was updated successfully, but these errors were encountered: