flatbuffers icon indicating copy to clipboard operation
flatbuffers copied to clipboard

Revival of GH-7371: Added vector union support for Python

Open jtdavis777 opened this issue 4 months ago • 2 comments

I wanted to revisit GH-7371 (fixes #4530) to add Advanced Unions support to python.

All credit for the base work goes to @surculus12 (and I cherry picked their commits over to preserve authorship) - I'm only coming in to get it up to date with the current repo and hopefully get it across the finish line.

I will address the last PR comments left on the original PR as and if they still apply.

jtdavis777 avatar Aug 21 '25 01:08 jtdavis777

~~One thing I either don't understand or want to fix, is how to get a member of a vector of union back to its 1st class type. right now the function returns a Table type with no obvious way to get back to the union type. May just be my inexperience with the generated python code.~~ looking at the python examples in the documentation, this is normal.

jtdavis777 avatar Aug 25 '25 00:08 jtdavis777

@fliiiix would you be up for helping me polish this PR up? I just rebased the original commits onto (a more recent) master, but enough things changed I would appreciate a second set of eyes to point out what still needs work.

jtdavis777 avatar Nov 17 '25 23:11 jtdavis777