documentation for Source.set_ref is incomplete and incorrect
Summary
The documentation doesn't really tell what set_ref
is supposed to do with the node
parameter.
Applies the internal ref, however it is represented
[...]
node – The same dictionary which was previously passed to Plugin.configure()
This isn't helpful for someone trying to implement a source.
Moreover, it says that node
is a buildstream.node.MappingNode
, which isn't always true in my testing.
Possible fixes
There is a TODO at https://gitlab.com/BuildStream/buildstream/-/blob/master/src/buildstream/source.py#L1009 about it being "nicer" to use the Node API.