1. Anuncie Aqui ! Entre em contato fdantas@4each.com.br

[Flutter] Unable to build app for iOS, "unable to write module session file...

Discussão em 'Mobile' iniciado por Stack, Outubro 30, 2024 às 20:22.

  1. Stack

    Stack Membro Participativo

    yesterday I was working fine with Flutter, now i'm facing this issue and I already search everywhere for a solution but no success.

    When I run:

    flutter run


    The build process starts and when its about to finish the error below is shown:

    Launching lib/main.dart on iPhone 11 Pro Max in debug mode...
    Xcode build done. 12.3s
    Failed to build iOS app
    Error output from Xcode build:

    ** BUILD FAILED **
    Xcode's output:

    error: unable to write module session file at '/Users/hencke/Library/Developer/Xcode/DerivedData/ModuleCache.noindex/Session.modulevalidation': fopen(/Users/hencke/Library/Developer/Xcode/DerivedData/ModuleCache.noindex/Session.modulevalidation, wb): No such file or directory (2)
    note: Using new build system
    note: Planning build
    note: Constructing build description
    Could not build the application for the simulator.
    Error launching application on iPhone 11 Pro Max.
    Exited (sigterm)


    Looks like the process is trying to open this file Session.modulevalidation for writing, but this file really does not exist in that folder. And I don't know what to do.

    Things that I already tried:

    1. Reinstalling xcode
    2. flutter clean
    3. Clone my project again in another folder and try to build, but same error
    4. Created a new flutter dummy project and tried to build, still same error
    5. Rebooting machine several times
    6. Give permissions to Staff to the DerivedData and ModuleCache.noindex folders
    7. Deleted the DerivedData within hope that xcode build will recreate all the files needed, but, it created everything again but not that particular file.

    So that's it, If any blessed human know how to 'recreate', or reset, clear some cache, I would be very thankful.

    Continue reading...

Compartilhe esta Página