Chained Pull Requests via Directed Graph Segmentation

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing version control systems face challenges in automatically creating chained pull requests, requiring manual effort and in-depth understanding from developers, which can lead to errors and dependency issues due to the high cognitive burden of reviewing large numbers of code changes across multiple files.

Innovation Solution

A method that indexes changes in a feature branch, determines relationships between files, generates a directed graph, segments it into trees, and automatically creates a chain of pull requests based on these trees, allowing related changes to be reviewed and merged simultaneously, thereby reducing the complexity for developers.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If manual creation of chained pull requests is performed, then developers can review and merge code changes, but the cognitive burden increases and errors occur due to the complexity of managing multiple files and dependencies

Engineering Contradiction:
Improveaccuracy of pull request creationVSAvoidcomplexity of pull request management
Core Design Contradiction:
ReliabilityVSDevice complexity

Solution Approach 1:

The system automatically segments a large set of code changes into multiple smaller, organized pull requests based on file relationships and dependencies. This segmentation reduces the cognitive burden on developers by breaking down complex change sets into manageable units that can be reviewed independently, while maintaining proper ordering through dependency analysis.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The system performs self-service by automatically analyzing code changes, determining file relationships, and generating the optimal chain of pull requests without requiring manual intervention. This eliminates the cognitive burden of manually managing multiple pull requests while ensuring proper dependency ordering and reducing errors through automated dependency resolution.

Inventive Principle:
Principle #25Self-service

2Productivity

If developers manually manage multiple pull requests for code changes, then code review can be performed, but time is lost due to the high cognitive burden and manual effort required

Engineering Contradiction:
Improveefficiency of code review processVSAvoidtime spent on pull request management
Core Design Contradiction:
ProductivityVSLoss of time

Solution Approach 1:

The system performs preliminary action by automatically analyzing code changes and pre-organizing them into a chained sequence of pull requests before the developer needs to review them. This preliminary organization based on file relationships and dependencies eliminates the time-consuming manual task of figuring out the correct review order, allowing developers to immediately begin reviewing pre-organized, manageable change sets.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The system automates the entire process of analyzing, organizing, and sequencing pull requests through self-service mechanisms, freeing developers from manual management tasks. This automation significantly improves productivity by eliminating the time spent on cognitive decision-making about pull request ordering and dependency management.

Inventive Principle:
Principle #25Self-service

3Reliability

If large numbers of code changes are reviewed manually, then comprehensive review can be achieved, but errors and dependency issues arise due to the cognitive burden on developers

Engineering Contradiction:
Improvecorrectness of code mergingVSAvoidease of reviewing code changes
Core Design Contradiction:
ReliabilityVSEase of operation

Solution Approach 1:

The system segments large numbers of code changes into smaller, logically grouped pull requests based on file relationships and dependencies. This segmentation maintains comprehensive review coverage while improving ease of operation by presenting developers with manageable change sets that are easier to understand and review accurately, reducing the likelihood of errors and dependency issues.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The system acts as an intermediary between the code changes and the developer reviewer by automatically analyzing file relationships, determining dependencies, and generating an optimized review sequence. This intermediary processing ensures comprehensive review of all changes while shielding developers from the complexity of managing large numbers of files, thereby improving both reliability and ease of operation.

Inventive Principle:
Principle #24Intermediary (Mediator)

Data Source

PatentUS20240111523A1Chained pull requests in a source code management system
Publication Date: 2024.04.04 ATLASSIAN PTY LTD
  • US20240111523A1 patent drawing
  • US20240111523A1 patent drawing
  • US20240111523A1 patent drawing

AI summary

Methods and computer readable medium for automatically creating chained pull requests are disclosed. The method includes: indexing one or more changes made to a plurality of files in a feature branch of a source code repository. Each indexed change represented by a key and value. The method further includes determining one or more relationships between the plurality of changed files based on the indexed changes, generating a directed graph including one or more parent nodes and one or more children nodes based on the determined one or more relationships between the plurality of changed files, and segmenting the directed graph into a plurality of trees. Each tree includes a single parent node. The method further includes creating a chain of pull requests based on the plurality of trees. Each pull request in the chain of pull requests is based on a tree of the plurality of trees.