Skip to content

[iOS/Catalyst] Swipeviews with invoked properties crash the app in ReleaseΒ #18055

Description

@arnaudaug

Description

Hello MAUI Team,

I am encountering a problem with swipeviews containing invoked properties.
I would like to point out that these are crashes on generic pages when the application is compiled in release mode on iOS or MacCatalyst and that it works well in Debug.
It also works fine in Debug/Release on Android.

Regards

Steps to Reproduce

1./ Copy my repository
2./ Compile the application in release mode (provisioning profile needed and must be selected).
3./ Run the app with your iOS device.

capture witdh=200

First button : Generic listpage with one Invoked event = Crash after swipe + press "Delete" on an item.
Second button : Generic listpage with many Invoked events = Crash after pressing the button. We should display a page with two swipes on the left to move up and down an item and one swipe on the right to delete it.
Third button : Classic page with Invoked event : Works well.

I use BasePage for generics models.

In 8.0 RC2 : Crash according to the cases I identified
In 8.0 RC1 : Known bug, invokeds do not react.

If you need clarification, don't hesitate.
Thank

Link to public reproduction project repository

https://github.com/arnaudaug/CollectionReleaseiOS

Version with bug

8.0.0-rc.2.9373

Is this a regression from previous behavior?

Not sure, did not test other versions

Last version that worked well

Unknown/Other

Affected platforms

iOS, macOS

Affected platform versions

iOS 16.6.1 macOS 13.6

Did you find any workaround?

No, I tried to use commands instead but failed.

Relevant log output

No response

Activity

  1. added
    legacy-area-controlsLabel, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor
    on Oct 17, 2023
  2. arnaudaug commented on Nov 7, 2023

    @arnaudaug
    Author

    Hello @jsuarezruiz and @Eilon ,

    I updated the versions :
    MAUI : 8.0.0-rc.2.9511
    Xcode 15.0.1
    iOS 16.7.2 (I don't want to update to iOS 17 yet)
    macOS Ventura 13.6.1 (I don't want to update to Sonoma yet)

    I tested this morning and I still have the same problem on an iOS application in realize mode. :(

    Have you been able to make progress in identifying the problem (perhaps in the overly optimized compilation)?

    Thank you for helping me

  3. added
    s/verifiedVerified / Reproducible Issue ready for Engineering Triage
    s/triagedIssue has been reviewed
    on Dec 15, 2023
  4. XamlTest commented on Dec 15, 2023

    @XamlTest

    Verified this on Visual Studio Enterprise 17.9.0 Preview 1(8.0.3). Repro on iOS 17.0 with below Project:
    CollectionReleaseiOS.zip

  5. Strypper commented on Dec 27, 2023

    @Strypper

    I have the same issue, it seem like when using custom event handler it crash the application, on Android (Debug/Release) IOS (Debug), Windows are fine but IOS release crash

            <DataTemplate x:Key="HomeItemTemplate" x:DataType="app:AnnouncementsPageItemModel">
                <app:AnnouncementItemContentView AnnouncementTapped="AnnouncementItemContentView_AnnouncementTapped" ComponentData="{x:Binding}" />
            </DataTemplate>
    namespace LBA4;
    
    public partial class AnnouncementItemContentView : ContentView
    {
    
        #region [ Delegates ]
    
    
        public delegate void AnnouncementTappedEventHandler(string fileUrl);
        #endregion
    
        #region [ CTors ]
    
        public AnnouncementItemContentView()
        {
            InitializeComponent();
        }
        #endregion
    
        #region [ Properties ]
    
        public static readonly BindableProperty ComponentDataProperty = BindableProperty.Create(
                nameof(ComponentData),
                typeof(AnnouncementsPageItemModel),
                typeof(AnnouncementItemContentView),
                default(AnnouncementsPageItemModel)
         );
        public AnnouncementsPageItemModel ComponentData
        {
            get => (AnnouncementsPageItemModel)GetValue(ComponentDataProperty);
            set => SetValue(ComponentDataProperty, value);
        }
    
        #endregion
    
        #region [ Events ]
    
        public event AnnouncementTappedEventHandler AnnouncementTapped;
    
        private void ViewFile_Clicked(object sender, EventArgs e)
        {
            this.AnnouncementTapped?.Invoke(ComponentData.FileUrl);
        }
        #endregion
    
    }
  6. Strypper commented on Dec 27, 2023

    @Strypper

    Even with ICommand still not immune to this crash issue

  7. removed
    legacy-area-controlsLabel, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor
    on May 10, 2024
  8. added this to the Backlog milestone on Jun 5, 2024
  9. added a commit that references this issue on Jul 6, 2026
  10. locked and limited conversation to collaborators on Aug 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions