Navigation view re-injected multiple times in navigation path when using DoubleColumnNavigationViewStyle

I have made a demo app reproducing the issue I am facing with the iPad when using the DoubleColumnNavigationViewStyle

My normal navigation path is:
List1 -> Form1 -> Form2 -> Picker1 -> (change the Teacher)

Somehow Form1s are injected and the path becomes:
List1 -> Form1 -> (Form1, etc...) -> Form1 -> Form2 -> Picker1 -> (change the Teacher)

I do not have NavigationLinks from From1 to Form1 anywhere in my code.

A new Form1 is inserted just by changing a value of a Picker

I believe this is a bug


More moments are in the code



Replies

You're going to get more answers if you dump the Core Data stuff and just add some data via constants.
Thanks @bartvk but I think CoreData is part of the issue.

I did make another demo that has less CoreData elements (No save, No Monitoring, No Relationships)
It uses a DatePicker and still creates the multiple Form1 navigation issue.

It also shows a second issue where the Date selection widow closes prematurely.
This second issue is present or not based only on the fact that a second DatePicker has it's value defined at the List view and passed along to the Form or if it's value is defined directly at the Form view level.

Very puzzling...


Again, more comments are in the code




Can anybody confirm they can reproduce the issue with Double Column styles of either of my example projects?

I filled a bug report linking this post on the feedback assistant but still had no confirmation from apple that this issue can be reproduced and being looked at.



Here is how to reproduce the issues:

Switch to DoubleColumn (1) tab
Click on any “To Form 1” row
Nore: The rest of the instructions for this step will refer to this line as GOTO1
Click on any “To form 2” row
Click on the CoreData picker
Change a value
Notice that the picker closed without notice. This should not be.
Notice that the displayed form is now Form1 instead of Form2. This should no be.
Notice that there is a back button going from Form1 back to Form1 again but nowhere in the code is a navigation link from form1 to form1. This should not be.
Execute the steps a 2nd time starting at GOTO1
Execute the steps a 3rd time starting at GOTO1
Click on the <Form1 back button to go back to Form1
Click on the <Form1 back button to go back to Form1
Click on the <Form1 back button to go back to Form1
Notice that we had to click on 3 back buttons with corresponds to the munger of loops to GOTO1. This should not be.
Click on <List1 back button to go back to List1

Notice that if you redo the steps but use the Binding DatePicker Instead of the CoreData DatePicker, there are none of the issues present.
Starting from Xcode Version 12.0.1 (12A7300), the picker now shows a calendar instead of the classic date picker.
The problem is no longer present using this new calendar.