Skip to content

[Regression] App Fails To Read FileSystem.AppDataDirectory On Startup #27785

@Eddie-Hartman

Description

@Eddie-Hartman

Description

Reading FileSystem.AppDataDirectory during CreateMauiApp causes the app to crash.

Steps to Reproduce

Run reproduction project code.

In short, add FileSystem.AppDataDirectory into the app's startup code in MauiProgram.cs and it fails.

Link to public reproduction project repository

https://github.com/Eddie-Hartman/MAUIFileLockingIssue

Version with bug

9.0.40 SR4

Is this a regression from previous behavior?

Yes, this used to work in .NET MAUI

Last version that worked well

9.0.30 SR3

Affected platforms

Windows

Affected platform versions

No response

Did you find any workaround?

No response

Relevant log output

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-essentialsEssentials: Device, Display, Connectivity, Secure Storage, Sensors, App Infoplatform/windowss/triagedIssue has been revieweds/verifiedVerified / Reproducible Issue ready for Engineering Triaget/bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    Status

    Todo

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions