5.3 unable to load plugin in debug

I update engine from 5.2.0 to 5.3.2. Multiplayer project.
On 5.3.2 engine when i run compile UnrealEditor - no errors.
I package server and client.
Launching the assembled server - no errors.
But I run server configuration in Rider for debug i get error: unable to load plugin …

I check source codes 5.2.0 and 5.3.2 engine versions and found difference in IPlatformFileSandboxWrapper.cpp file in functions IterateDirectory and IterateDirectoryRecursively.

if (SandboxDir != Directory) - 5.2.0
versus
if (Result && (SandboxDir != Directory)) - 5.3.2

because of these changes, the engine plugins were not loaded.

Maybe there should be: if (!Result && (SandboxDir != Directory)) - 5.3.2

*linux ubuntu
*Rider 2023.3

I found another even smaller fix that solves this issue on Linux for 5.3+

diff --git a/Engine/Source/Runtime/Core/Private/Unix/UnixPlatformFile.cpp b/Engine/Source/Runtime/Core/Private/Unix/UnixPlatformFile.cpp
index f04bc9ea3242..00c0cffd78f2 100644
--- a/Engine/Source/Runtime/Core/Private/Unix/UnixPlatformFile.cpp
+++ b/Engine/Source/Runtime/Core/Private/Unix/UnixPlatformFile.cpp
@@ -1326,7 +1326,7 @@ bool FUnixPlatformFile::IterateDirectoryStat(const TCHAR* Directory, FDirectoryS
 
 bool FUnixPlatformFile::IterateDirectoryCommon(const TCHAR* Directory, const TFunctionRef<bool(struct dirent*)>& Visitor)
 {
-       bool Result = false;
+       bool Result = true;
 
        FString NormalizedDirectory = NormalizeFilename(Directory, false);
        DIR* Handle = opendir(TCHAR_TO_UTF8(*NormalizedDirectory));

This makes the directory traversal continue within “FPluginManager::FindPluginsInDirectory” and it finds all the required plugins. Without this it only looks through the very top level of the engine plugins, and never goes into the subdirectories.

I’m still looking for the true root cause of this, and if I find it I’ll push a PR.

1 Like

I had this issue with 5.4.1 (binary release) and can confirm that 5.4.1-release (git tag) plus above fixes/work-arounds do indeed fix the issue.

As a UE-Dev I’m only a few days old, so too young for a MR, but some adult please follow up.

In version 5.4.4, your changes also work.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.