For most data tables we accept and carry extra columns as long as they are prefixed with meta_. This is tested here and implemented on TableModelhere.
With the add API redesign the Node and Edge table no longer inherit this behavior, and thus don't support extra columns. However metadata is often most relevant for these two tables.
I expect these to work and write these columns to the database. If they are not prefixed with meta_ it should error. Right now for Node it silently ignores any unknown kwargs.
from ribasim import Model, Node
from shapely.geometry import Point
Node(1, Point(3, 1), meta_a = 1)
model.edge.add(
model.tabulated_rating_curve[1],
model.terminal[1],
meta_b = 2,
)
For most data tables we accept and carry extra columns as long as they are prefixed with
meta_
. This is tested here and implemented onTableModel
here.With the add API redesign the Node and Edge table no longer inherit this behavior, and thus don't support extra columns. However metadata is often most relevant for these two tables.
I expect these to work and write these columns to the database. If they are not prefixed with
meta_
it should error. Right now for Node it silently ignores any unknown kwargs.