Failed to open descriptor file (android)

Whenever i upload my game to Google Play using Android App Bundles, i check the test results it gives me an error saying Failed to open descriptor file.

Why does this happen?

305166-failed.png

2 Likes

WILL ANYONE HELP? AM I THE ONLY DEVELOPER WHO WANTS TO UPLOAD THEIR GAME WITH ANDROID APP BUNDLE?

3 Likes

Same here, though i noticed it only happens when i launch it with ASTC

1 Like

I have the same problem but only with Arm64 :confused: Arm7 worksā€¦ but ā€¦ I need arm64 to work also. Sometimes neither works. I assume it has something to do with moving files and copying projects?

1 Like

so anyone ? no one ? no one want to answer, or we are the only ones that got this Error ? Please Help XD

1 Like

I tried to upload my .apk and .obb but play store only downloads and installs .apkā€¦ Should I try the app bundle system? I know this isnā€™t helping but there is very little support for android hereā€¦ I am considering UDN just to publish my game alreadyā€¦

In my case I had a project under source control, which instead of branching via Perforce Iā€™ve created a copy directly in Explorer. The copied and renamed project always produced the ā€œFailed to open descriptor fileā€¦ā€ when built via the launch button in the engine. I was able to create packaged builds but these immediately crashed when I tried to launch the app (also tried to manually add the .obb file).

Then I thought okay back to start and this time I branched the project with Perforce and the project launched perfectly fine. So I think it could possibly be something with copying files and so forth like mentioned by @Erock2018.1. Maybe also with read/write rights on the files.

2 Likes

@thoeme No idea what I done but it works now :smiley: I must have switched something off without knowingā€¦ now my next problem is a giant native library that I am trying to reduce from 89mb :confused: No idea

1 Like

In my case one of the following two solutions worked:

Solution 1

  1. Launch project onto device, receive descriptor error
  2. Create a packaged build (I was using Multi)
  3. Use the .bat files to remove the app from the device
  4. Use the .bat file to install the app to the device
  5. Launch onto device works again without descriptor file error

Solution 2

  1. Add android:requestLegacyExternalStorage=ā€œtrueā€ to Project Settings - Android - Extra Tags for application node by hitting ā€œ+ā€ icon

For both you should make sure that you have removed the Binaries, Intermediate and Saved folders before repackaging / rebuilding your project. Also I was using 4.25.3 and it worked with target SDK set to 29 (which has to be installed - can be easily done with Android Studio)

4 Likes

Hey i had the same problem, what worked for me was setting the min sdk version to 9, just keep in mind google play requires 29. Hope i helped someone.

Hi, I encounter the same problem. But now I can bypass this problem by adjusting the packing configuration, so Iā€™m not going to spend more time on this issue. However, maybe the following notes can help further investigations:

  1. This problem only occurs to me when the targeting platform is set [API 30] and then click ā€œLaunch (on Android)ā€ in the editor. I donā€™t know why this can happen because my mobile phone supports API 30.

  2. Among other attempts, I pack the game (developer/shipping) for Android API 30, and then launch that APK with Android Studio(AS), thereā€™s no error message this time. I also change the targeting API version to 28, thereā€™s no error either launching with UE or AS.

  3. With AS, I debugged the APK with ā€œProfile or debug APKā€. Several APKā€™s exist in my disk: the packed APK locates in the specified folder, without much doubt; whereas another APK is generated in the UE project folder as the result of ā€œLaunchā€ in the UE editor, it is placed at ā€œxxx/Binaries/Android/xxx.apkā€. When I debug this APK, which is generated by ā€œLaunchā€ in UE with API 30, the error occurs. (So the APK is problematic?)

  4. Through debug, the problem arises when opening the .uproject file (obvious), at

  • LaunchEngineLoop.cpp Line 2012
    if (!IProjectManager::Get().LoadProjectFile(FPaths::GetProjectFilePath()))

  • FileHelper.cpp Line 192
    TUniquePtr Reader(IFileManager::Get().CreateFileReader(Filename, ReadFlags));

The reader object is null, hence the error.

In debug sessions of both working and problematic APKā€™s, the ā€œFileNameā€ to open is ā€œā€¦/ā€¦/ā€¦/FpsDemo.uprojectā€, one just opens and reads whereas the other fails. I donā€™t see the reason, so I leave the problem here.

  1. I suspect this may either be an access permission problem, or the UE launch for Android API 30 fails to transmit components to the device. I didnā€™t repeat the test on other mobile phones, so this can also be caused by my deviceā€¦

Hope this helps!

2 Likes

Iā€™ve usually seen this happen when the Executable doesnā€™t match the Pak file (only one got updated and we forgot to update the other), or if the Pak file is missing completely.

This response saved me, thank you. Not sure how changing texture format has to do anything with app not being able to access its project file.

Update: changed texture format might have been unrelated to the solution, since selecting it didnā€™t fix the issue for another project. Instead setting the ā€œPackage game data inside .apk?ā€ option to true seemed to yield reliably positive results.

How do you remove the binaries, intermediate, and saved folders from your phone? I did it a while back though the command prompt but I forgot how I did it.

Hi there. I wrote a little .bat file to delete the app from a device. This covers both cases for apps created with Unreal Engine 4 & 5 (since the path on the device changed slightly). You can either use the bat file or you should be able to select the lines relevant to you. Basically the .bat file tells you what you have to enter, since my knowledge of CMD wasnā€™t enough to fully automate the process. Hope that helps!


@anonymous_user_add01a93 on

set AndroidSDKToolsPath = ā€œC:\YOURPATH\Android\Sdk\platform-toolsā€

@anonymous_user_add01a93 off
echo Please enter the name of the app (name of UE Project - i.e. MyUnrealGame)
set /p AppName=ā€œā€

:choice
@anonymous_user_add01a93 off
echo Was the app created with Unreal Engine 4 or 5 ? (4/5)
set /P c=ā€œā€
if /I ā€œ%c%ā€ EQU ā€œ4ā€ goto :UnrealEngine4
if /I ā€œ%c%ā€ EQU ā€œ5ā€ goto :UnrealEngine5
goto :choice

:UnrealEngine4
@anonymous_user_add01a93 on
cd /d %AndroidSDKToolsPath%
@anonymous_user_add01a93 off
echo ā€œEnter: cd sdcard/UE4Gameā€
echo ā€œEnter: rm -r %AppName%ā€
adb shell
echo finished

:UnrealEngine5
@anonymous_user_add01a93 on
cd /d %AndroidSDKToolsPath%
@anonymous_user_add01a93 off
echo ā€œEnter: cd sdcard/UnrealGameā€
echo ā€œEnter: rm -r %AppName%ā€
adb shell
echo finished

rem In case you have a permission denied error, try to use the ā€˜adb rootā€™ command

rem cd /d %AndroidSDKToolsPath%
rem adb root

I donā€™t know if this will help someone but, in my case, after upload the shipping version of the game to Google Play, starts appear the error of descriptor file when I tried to test the game with Launch Button and with package too, so my solution was disabling Generate bundle (AAB) and works fine for me.
image

Have same issue, but I guess its because of:

LogPlayLevel: UAT: Attempting to connect to file server [USB]
LogPlayLevel: UAT: Not connected, attempting to start file server
LogPlayLevel: UAT: Did not find a bind listener
LogPlayLevel: UAT: Trying again
LogPlayLevel: UAT: Did not find a bind listener
LogPlayLevel: Warning: UAT: WARNING: Failed to start Android file server for com.YourCompany.jaka, skipping deploy for BV9100EEA00036317

In what mode I need to connect the phone?

USB debug mode is on.

With 5.0+, the fix Iā€™ve found is to not use Andriod File Server mode but directly using adb.exe for deployment. Hopefully, this helps.

1 Like

so how can i use adb.exe with 4.0+ to fix this problem? thanks

@Erock2018.1 and @Thoeme are right. Took me a lot of tinkering, trial and error, but the main issue is duplicating the project. Whether it be through unreal or in windows explorer, if you change the names of the file, existing blueprints, meshes, textures etc. in the new duplicated project itā€™ll cause this issue.

The best solution is sticking with the naming used in the file, blueprints, textures, meshes etc. But if it is necessary to change the name make sure you do the following:

  • As @Thoeme mentioned, delete the entire ā€˜Binariesā€™, ā€˜Intermediateā€™ and ā€˜Savedā€™ (except the ā€˜Configā€™ file in ā€˜Savedā€™) folders in windows explorer (wherever you have saved your project)

  • Go through every remaining folder and edit the necessary .ini (configuration files) via notepad and make sure the referenced blueprints, file name, texture, mesh files etc. (whatever has been changed) matches

  • Once everything is changed/updated, reopen the project file in unreal and under ā€˜Project Settingsā€™ - ā€˜Androidā€™, youā€™ll have to reclick ā€˜Configure Nowā€™ for the ā€˜APK Packagingā€™ and ā€˜Google Play Servicesā€™

  • Save and try quick launch to mobile again. The error should disappear

Hope this helps

*Edit: This worked for me in UE5.1.1. I havenā€™t tried this in prior versions

1 Like