Open chrisdent-de opened 10 months ago
Thanks for the report. Are you still experiencing this? If so, we'd appreciate a PR.
I hope it's the last one for this mysterious behavior, but we might need this for all read operations in TestRegistry.ps1 as it's a known issue in .NET Framework (fixed in .NET/Core)
Sorry, just been a bit busy. I'm planning to PR a more extensive retry op around this. In the meantime I've disabled TestRegistry drive so the pressure to fix went off a bit.
Checklist
What is the issue?
When Pester 5 is running in parallel the
Test-Path
invocation inNew-RandomTempRegistry
will occasionally throwNo more data is available
.This error is already handled with a retry for
New-Item
, but not theTest-Path
command.Expected Behavior
The TestRegistry drive should successfully create.
Steps To Reproduce
Cannot trivially reproduce this transient error.
Stack trace is shown below:
Describe your environment
A CI executor which runs multiple instances of Pester in parallel in PowerShell 5.1.
The error does not occur in PowerShell 7.3 and above.
Possible Solution?
Are you happy to accept a PR which modifies the retried operation in
New-RandomTempRegistry
?