MCPcopy Create free account
hub / github.com/bhowiebkr/PyFlowGraph / merge_with

Method merge_with

src/commands/node/basic_operations.py:661–672  ·  view source on GitHub ↗

Merge with another move command.

(self, other: CommandBase)

Source from the content-addressed store, hash-verified

659 abs(other.timestamp - self.timestamp) < 1.0) # Within 1 second
660
661 def merge_with(self, other: CommandBase) -> Optional[CommandBase]:
662 """Merge with another move command."""
663 if not self.can_merge_with(other):
664 return None
665
666 # Create merged command using original start position and latest end position
667 return MoveNodeCommand(
668 self.node_graph,
669 self.node,
670 self.old_position,
671 other.new_position
672 )

Callers 1

Calls 2

can_merge_withMethod · 0.95
MoveNodeCommandClass · 0.85

Tested by 1