Hello!
Use case:
- I have a reference field of taxonomy term with hierarchy.
- I discovered Taxonomy Container module to create optgroups in entityreference select lists via hierarchy. This is perfect! Except...
- That module's widget works on a content type form display correctly but in YAML Form, it displays with missing parents
I don't know if this is a simple bug to fix, if there is a deeper issue or if this should be fixed in taxonomy_container itself. I will spend more time investigating the code but I was wondering if you would know right away.
Here is a screenshot illustrating the issue.

| Comment | File | Size | Author |
|---|---|---|---|
| #16 | integration_for-2808301-15.patch | 6.1 KB | jrockowitz |
| #13 | integration_for-2808301-13.patch | 6.15 KB | jrockowitz |
| #10 | integration_for-2808301-10.patch | 4.75 KB | jrockowitz |
| #8 | errors.png | 89.38 KB | ptsimard |
| #8 | errors.png | 89.38 KB | ptsimard |
Comments
Comment #2
jrockowitz commentedThis issue is in the YAML Form module because I am flattening the options here.
I will fix it and post a patch ASAP.
Comment #3
jrockowitz commentedComment #4
ptsimard commentedWow that was a fast turnaround!
So I applied the patch. It did change the data but not as expected.
See screenshot:
Comment #5
ptsimard commentedComment #6
jrockowitz commentedPlease try this patch.
Comment #7
ptsimard commentedSeems to be working well now! Good work =)
Comment #8
ptsimard commentedActually there seem to be a few issues.
I'm getting:
on that dataset field when it has selected elements and I try to go to a next wizard page.
Recent log messages have many of these type of errors:
If I leave dataset selection empty and go to Next wizard page and click previous I get this:
Comment #10
jrockowitz commentedI replicated the issue locally and the attached patch should handle the error.
Comment #13
jrockowitz commentedComment #16
jrockowitz commentedComment #17
jrockowitz commentedWOOT! @ptsimard Please test the patch and I will commit it ASAP.
Comment #18
ptsimard commentedI tested patch 15 and it seems to work fine!
As for the other error
it is unrelated to this so I will create a new issue with more information.
Thank a lot! I've never seen this fast a turnaround time on D.o!
Comment #20
jrockowitz commented