Load asset async from dlc pak file failed

I use Projectlauncher make a release version and make a dlc pak file based on this release version.
in the game i mount dlc pak file and use RequestAsyncLoad method of FStreamableManager to load asset in dlc,but it notice the file contains unrecognizable data, check that it is of the expected type.

I tried both WindowsNoEditor and Android_ASTC platfroms and both failed for the same reason.
My Unreal version is 4.11.2

log file:
[link text][1]

Projectlauncher config for release:

Projectlauncher config for dlc:

Hey ,

Can you please provide me with exact step by step reproduction steps to recreate this in a new project? I just tested the steps provided above and my package was successful. If you are not able to recreate this in a new project, please try to delete your Intermediate, Config and Saved files from your project folder and try again.

Looking forward to hearing back from you, thanks!

Hi :
Thank you for your reply.I have uploaded my project in attachment.
My Operation System is Windows7 64bit and Unreal Engine version is 4.11.2.
My project:[link text][1]

This is a c++ project.The load asset method will be invoked when you click MyImportPakFile Actor in Game.I guess the problem might be in the c++ code.
Then I will show you how to reproduce these steps:

1) make a release package by the release config of project launcher.

now the release package be located in “LoadTest\Saved\StagedBuilds\WindowsNoEditor”.

2) create a new asset(could be any type of asset, such as material, particlesystem and so on) in content browser and make a dlc package by the dlc config of project launcher.

now the dlc pak file is located in “LoadTest\Plugins\dlc100\Saved\StagedBuilds\WindowsNoEditor\LoadTest\Content\Paks”.

3) launch LoadTest.exe at "LoadTest\Saved\StagedBuilds\WindowsNoEditor"

4) rename the dlc pak file as "dlc.pak" and move it into "LoadTest\Saved\StagedBuilds\WindowsNoEditor\LoadTest\Content\Paks".

5) click MyImportPakFile Actor (it is a cube mesh on the floor) in Game to trigger the load asset method be invoked.

6) close LoadTest.exe and see the log file in "LoadTest\Saved\StagedBuilds\WindowsNoEditor\LoadTest\Saved\Logs".Now you will see “LogLinker:Warning: The file contains unrecognizable data, check that it is of the expected type” in the log file.

Hello,

When I attempt to open the project you provided, I am prompted to rebuild. Upon building the project in Visual Studio, I am seeing error messages appear. Are you able to build the project successfully in Visual Studio on your end?

Hi,
I use compile button of unreal editor to compile my code and never appear any errors.
Visual Studio is only as for edit code. I try compile my
project by Visual Studio and there’s really some wrong message. But you don’t need to build the project by this way. It works very well by using compile button of unreal editor.

The problem is that in order to open the project, I need to rebuild the project, which is failing in Visual Studio. As a result, I am unable to get the project to open. Go ahead and try to build it in Visual Studio, fix up the compiler errors that you are getting, and then send that version of the project so that we are able to take a look at it and help you solve your issue.

Thank you

[link text][1]
Hi,this version project file can build success. My OS version is win7 64bit. Visual Studio version is community 2015. Unreal Editor version is 4.11.2. You can build the project successfully by the follow steps.
First step: unzip the project zip file.
Second step: right mouse click ‘LoadTest.uproject’ and choose ‘generate visual studio project files’.
Third step: Open ‘LoadTest.sln’ by Visual Studio.
Fourth step: Click Build => Build Solution.

90843-loadtest.zip (436 KB)

Hey -

After some compile issues I was able to get the project to build. Following the steps provided, I too received the “unrecognizable data” warning. This has been reported, UE-31250 , for further investigation.

Cheers

Hi ,

This was caused by a bug in the automation tool related to how asset paths are mapped in DLC pak files. It has been fixed and will be in a future release.

If you have a code version of the engine and would like to apply the change yourself, just replace this line in CopyBuildToStagingDirectory.Automation.cs:

SC.StageFiles(StagedFileType.UFS, SubDir, "*", true, ExcludeWildCards, "", true, !Params.UsePak(SC.StageTargetPlatform));

with this:

SC.StageFiles(StagedFileType.UFS, SubDir, "*", true, ExcludeWildCards, SC.RelativeProjectRootForStage, true, !Params.UsePak(SC.StageTargetPlatform));

Then rebuild the AutomationTool scripts and repackage your DLC.

It also shouldn’t be necessary to manually mount the pak file yourself in AssetStreamer.cpp, since that is done automatically at startup for any pak files located in Content\Paks.

Mahoney

Hi Mahoney,
Which version will fix this bug, is in 4.12.3?

This should be in 4.13.