소스 검색

5.0 work around arror updating group node during startup

I recently broke the code that is responsible for setting the socket values during
node group update. It is supposed to keep object references around in e.g. curve picker sockets, but it can lose them during startup.
we just work around this by skipping these sockets during startup

anyhow this just updates the 5.0 compatibility because it re-introduces bad beahviour
Joseph Brandenburg 3 달 전
부모
커밋
4fd017ca30
1개의 변경된 파일1개의 추가작업 그리고 3개의 파일을 삭제
  1. 1 3
      utilities.py

+ 1 - 3
utilities.py

@@ -145,9 +145,7 @@ def get_socket_maps(node, force=False):
                     keep_sockets.append(other_socket)
                 map[sock.identifier]= keep_sockets
             elif hasattr(sock, "default_value"):
-                if getattr(sock, "default_value") is not None:
-                    val = getattr(sock, "default_value")
-                elif sock.bl_idname == "EnumCurveSocket" and sock.get("default_value") is None:
+                if sock.bl_idname == "EnumCurveSocket" and sock.get("default_value") is None:
                     # HACK I need to add this special case because during file-load,
                     #  this value is None and should not be altered until it is set once.
                     continue