Nodes: revert the inline (pass-through) socket feature
Inlined sockets in the same vertical space are no longer supported. This removes `input_output` socket declarations, the inlining feature in node drawing, and the `Both` option for node group interface sockets. Versioning code splits existing node group sockets into individual sockets again. Unfortunately some links may get lost in versioning files using the feature, because of an unnoticed bug: Socket identifiers have to be unique in the node group items list but inlined input/output sockets have the same identifier. This still works for most situations because uniqueness is only required within input/output lists. Creating proper unique identifiers will discard any link from the previous output socket. This cannot easily be fixed without `after_linking` versioning code, which should be avoided. Pull Request: https://projects.blender.org/blender/blender/pulls/112560
This commit is contained in:
@@ -132,18 +132,13 @@ class NodeGroupInterfaceTests:
|
||||
out1 = tree.interface.new_socket("Output 1", socket_type=socket_type, in_out='OUTPUT')
|
||||
self.assertIsNotNone(out1, f"Could not create socket of type {socket_type}")
|
||||
|
||||
inout0 = tree.interface.new_socket("Input/Output 0", socket_type=socket_type, in_out='BOTH')
|
||||
self.assertIsNotNone(inout0, f"Could not create socket of type {socket_type}")
|
||||
|
||||
self.assertSequenceEqual([(s.name, s.bl_idname) for s in group_node.inputs], [
|
||||
("Input 0", socket_type),
|
||||
("Input 1", socket_type),
|
||||
("Input/Output 0", socket_type),
|
||||
])
|
||||
self.assertSequenceEqual([(s.name, s.bl_idname) for s in group_node.outputs], [
|
||||
("Output 0", socket_type),
|
||||
("Output 1", socket_type),
|
||||
("Input/Output 0", socket_type),
|
||||
])
|
||||
|
||||
def do_test_user_count(self, value, expected_users):
|
||||
|
||||
Reference in New Issue
Block a user