Skip to content

[Windows] Fix FlexLayoutCycleException test failure on candidate branch#34756

Merged
kubaflo merged 1 commit intodotnet:inflight/candidatefrom
Vignesh-SF3580:fix-32243Failure
Mar 31, 2026
Merged

[Windows] Fix FlexLayoutCycleException test failure on candidate branch#34756
kubaflo merged 1 commit intodotnet:inflight/candidatefrom
Vignesh-SF3580:fix-32243Failure

Conversation

@Vignesh-SF3580
Copy link
Copy Markdown
Contributor

Note

Are you waiting for the changes in this PR to be merged?
It would be very helpful if you could test the resulting artifacts from this PR and let us know in a comment if this change resolves your issue. Thank you!

Root Cause

PR #24867 deferred the OnItemsVectorChanged logic into an async DispatcherQueue.TryEnqueue lambda. Later, PR #34534 introduced DisconnectHandlers() in CleanUpCollectionViewSource, which sets base.VirtualView to null before the queued lambda executes.

Test name: FlexLayoutCycleException

Description of Change

This PR resolves the FlexLayoutCycleException test failure on the candidate branch. In ItemsViewHandler.Windows.cs, the guards inside the OnItemsVectorChanged lambda were updated from: if (VirtualView is null) return; to: if (((IViewHandler)this).VirtualView is null) return; No other changes were made.

Cause PR: #34534

Test result

Before Issue Fix After Issue Fix

@dotnet-policy-service dotnet-policy-service bot added the partner/syncfusion Issues / PR's with Syncfusion collaboration label Mar 31, 2026
@Vignesh-SF3580 Vignesh-SF3580 added the community ✨ Community Contribution label Mar 31, 2026
@sheiksyedm sheiksyedm marked this pull request as ready for review March 31, 2026 12:45
@sheiksyedm sheiksyedm added the area-testing Unit tests, device tests label Mar 31, 2026
@sheiksyedm sheiksyedm requested a review from kubaflo March 31, 2026 12:45
@kubaflo kubaflo merged commit fa0492c into dotnet:inflight/candidate Mar 31, 2026
2 of 11 checks passed
sheiksyedm pushed a commit that referenced this pull request Apr 4, 2026
…ch (#34756)

> [!NOTE]
> Are you waiting for the changes in this PR to be merged?
> It would be very helpful if you could [test the resulting
artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from
this PR and let us know in a comment if this change resolves your issue.
Thank you!

### Root Cause
PR #24867 deferred the OnItemsVectorChanged logic into an async
DispatcherQueue.TryEnqueue lambda. Later, PR #34534 introduced
DisconnectHandlers() in CleanUpCollectionViewSource, which sets
base.VirtualView to null before the queued lambda executes.

**Test name:** FlexLayoutCycleException

### Description of Change
This PR resolves the `FlexLayoutCycleException` test failure on the
candidate branch. In ItemsViewHandler.Windows.cs, the guards inside the
OnItemsVectorChanged lambda were updated from: if (VirtualView is null)
return; to: if (((IViewHandler)this).VirtualView is null) return; No
other changes were made.

**Cause PR:** #34534

### Test result
| Before Issue Fix | After Issue Fix |
|----------|----------|
| <img width="300" height="600"
src="https://github.com/user-attachments/assets/ac0d8e92-8c20-4647-8334-b3dcbaa96a64">
| <img width="300" height="600"
src="https://github.com/user-attachments/assets/77010f17-8db3-4ffe-9a51-ba19e4b5079c">
|
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-testing Unit tests, device tests community ✨ Community Contribution partner/syncfusion Issues / PR's with Syncfusion collaboration

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants