Skip to content
This repository was archived by the owner on May 15, 2024. It is now read-only.
This repository was archived by the owner on May 15, 2024. It is now read-only.

[Bug][iOS] Email.ComposeAsync with modal #1134

Open
@Maxima078

Description

@Maxima078

Description

When using Email.ComposeAsync on iOS it sometimes hangs due to an access to a view that has been destroyed. A warning is displayed in output :
"Warning: Attempt to present <MFMailComposeViewController: 0x13eb0c000> on <Rg_Plugins_Popup_IOS_Renderers_PopupPageRenderer: 0x13f0f2980> whose view is not in the window hierarchy! ".

It's really easy to workaround, just close your modal after Email.ComposeAsync but this sounds weird to me to use the top level view component (which can disappear) in order to ask iOS to compose email. At least we could expect an exception to be thrown, what do you think?

Steps to Reproduce

  1. Use a button within a modal (such as a popup from Rg.Plugins.Popup) bound to a command calling Email.ComposeAsync
  2. When this click is handled close your modal (from xaml.cs for instance)

Expected Behavior

Email.ComposeAsync returns or throws an error

Actual Behavior

Email.ComposeAsync sometimes never returns and no exception is thrown. A warning is displayed saying the renderer is not in the window hierarchy anymore.

Basic Information

  • Version with issue: 1.3.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingiosThis issue impacts iOSneed-more-informationNeed more information to investigate a bug or proposal

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions