Skip to content

Add Maximum Depth Setting for Dependency Tree Traversal #186

Description

@MyunghoBae

The current function recursively traverses the dependency tree to find all dependencies. However, when the dependency graph is very deep and complex, traversing the entire graph can lead to performance issues. To address this, we propose adding a maxDepth option to allow users to set the maximum depth for traversal.

Proposal:
Add a maxDepth option to the traverseDependencies function. This option will accept an integer value specifying the maximum depth to traverse. For example, setting maxDepth to 3 will limit the function to traversing dependencies up to 3 levels deep, ignoring any dependencies beyond that depth.

Expected Behavior:
Users should be able to set the maxDepth option when calling the traverseDependencies function to control the depth of traversal.

Expected Benefits:
Performance Improvement: By limiting the traversal to a specific depth, performance can be enhanced when dealing with large dependency graphs.
Flexibility: Users can adjust the traversal depth according to their needs.
Resource Optimization: Extracting only the necessary information minimizes resource usage.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions