bugs
This commit is contained in:
Vendored
+5
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"python-envs.defaultEnvManager": "ms-python.python:conda",
|
||||
"python-envs.defaultPackageManager": "ms-python.python:conda",
|
||||
"python-envs.pythonProjects": []
|
||||
}
|
||||
+11
-3
@@ -35,7 +35,12 @@ export function input_changed(node, slot, connect, link_info) {
|
||||
if (connect) {
|
||||
const type = get_type(node, link_info)
|
||||
if (app.ui.settings.getSettingValue("Use Everywhere.Options.use_output_name") && link_info) {
|
||||
const out_slot = node.graph.getNodeById(link_info.origin_id)?.outputs[link_info.origin_slot]
|
||||
var out_slot
|
||||
if (link_info.origin_id==-10) {
|
||||
out_slot = node.graph.inputNode?.allSlots[link_info.origin_slot]
|
||||
} else {
|
||||
out_slot = node.graph.getNodeById(link_info.origin_id)?.outputs[link_info.origin_slot]
|
||||
}
|
||||
node.inputs[slot].label = out_slot?.label || out_slot?.localized_name || out_slot?.name || i18n(type);
|
||||
} else {
|
||||
node.inputs[slot].label = i18n(type);
|
||||
@@ -47,7 +52,7 @@ export function input_changed(node, slot, connect, link_info) {
|
||||
node.inputs[slot].color_on = undefined;
|
||||
node.inputs[slot].type = '*'
|
||||
}
|
||||
fix_inputs(node, "input_changed")
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -88,9 +93,12 @@ This is called in various places (node load, creation, link change) to ensure th
|
||||
var fix_call_message;
|
||||
|
||||
function fix_star_inputs(node) {
|
||||
node.inputs.filter((input)=>(!input.link)).forEach((input)=>{
|
||||
input.type = '*'
|
||||
})
|
||||
node.inputs.filter((input)=>(input.type=='*' && input.link)).forEach((input)=>{
|
||||
const llink = node.graph.links[input.link]
|
||||
if (llink.type) input.type = llink
|
||||
if (llink.type) input.type = llink.type
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
@@ -67,14 +67,12 @@ app.registerExtension({
|
||||
if (this.IS_UE && side==1) { // side 1 is input
|
||||
input_changed(this, slot, connect, link_info)
|
||||
|
||||
// I suspect this is no longer needed... in which case the whole Deferred can be dumped!
|
||||
if (!shared.graph_being_configured) {
|
||||
// do the fix at the end of graph change
|
||||
deferred_actions.push( { fn:fix_inputs, args:[this,"deferred",]} )
|
||||
deferred_actions.push( { fn:fix_inputs, args:[this,"deferred onConnectionsChange",]} )
|
||||
// disconnecting doesn't trigger graphChange call?
|
||||
setTimeout(deferred_actions.execute.bind(deferred_actions), 100)
|
||||
}
|
||||
// ...to here
|
||||
}
|
||||
linkRenderController?.mark_link_list_outdated();
|
||||
onConnectionsChange?.apply(this, arguments);
|
||||
|
||||
@@ -84,6 +84,7 @@ class GraphAnalyser extends Pausable {
|
||||
if (node && !node.properties.rejects_ue_links) {
|
||||
//if (!real_node._widget_name_map) real_node._widget_name_map = real_node.widgets?.map(w => w.name) || [];
|
||||
node.inputs?.forEach((input,index) => {
|
||||
if (!input) return; // NoteNode has input = [undefined,] !
|
||||
if (is_connected(input, treat_bypassed_as_live, node_graph(node))) return;
|
||||
if (node.reject_ue_connection && node.reject_ue_connection(input)) return;
|
||||
if (is_connectable(node, input.name)) connectable.push({node, input, index});
|
||||
|
||||
@@ -133,12 +133,16 @@ class GraphConverter {
|
||||
}
|
||||
}
|
||||
// fix the localized names
|
||||
node.inputs = node.inputs.map((input) => {
|
||||
node.inputs = node.inputs.forEach((input) => {
|
||||
if (input) {
|
||||
if (!input.localized_name || input.localized_name.startsWith(i18n('anything'))) input.localized_name = input.name
|
||||
return input;
|
||||
} else {
|
||||
let brteakpoint;
|
||||
}
|
||||
})
|
||||
|
||||
// set types to match
|
||||
if (node.inputs) {
|
||||
node.inputs.forEach((input) => {
|
||||
if (input.type=='*') {
|
||||
const graph = node_graph(node);
|
||||
@@ -157,6 +161,7 @@ class GraphConverter {
|
||||
|
||||
Logger.log_detail(`clean_ue_node ${node.id} (${node.type})`, node.inputs);
|
||||
}
|
||||
}
|
||||
|
||||
convert_if_pre_116(node) {
|
||||
if (!node) return;
|
||||
@@ -335,7 +340,7 @@ export function get_connection(node, i) {
|
||||
const in_link = node?.inputs[i]?.link;
|
||||
if (in_link) {
|
||||
var llink = graph.links[in_link]
|
||||
llink = handle_bypass(llink, llink.type)
|
||||
llink = handle_bypass(llink, llink.type, graph)
|
||||
if (!llink) {
|
||||
Logger.log_problem(`handle_bypass failing - subgraph issue?`)
|
||||
llink = graph.links[in_link]
|
||||
|
||||
Reference in New Issue
Block a user