Skip to content

Refactor path functions to getPath[s]#1214

Open
Affie wants to merge 3 commits intodevelopfrom
refac/path
Open

Refactor path functions to getPath[s]#1214
Affie wants to merge 3 commits intodevelopfrom
refac/path

Conversation

@Affie
Copy link
Member

@Affie Affie commented Mar 24, 2026

No description provided.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR introduces new path-finding APIs (getPath / getPaths) for navigating factor graphs, refactors older path-related helpers toward those APIs, and adds test coverage for common pathfinding scenarios and filter combinations.

Changes:

  • Add getPaths / getPath to the AbstractDFG API surface (as declared services) and implement them using Graphs.jl algorithms in the GraphsDFG backend.
  • Deprecate/redirect legacy path utilities (findShortestPathDijkstra, findFactorsBetweenNaive) toward the new APIs.
  • Add a dedicated “Path Finding” testset covering shortest path, k-shortest paths, and filtering behavior (labels/solvable/tags).

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
src/services/AbstractDFG.jl Declares getPaths / getPath services; adjusts subgraph convenience wrapper naming.
src/GraphsDFG/services/GraphsDFG.jl Implements getPaths (A*, Yen) and getPath, plus subgraph restriction support.
src/GraphsDFG/GraphsDFG.jl Imports the new path APIs for extension within the GraphsDFG module.
src/DistributedFactorGraphs.jl Marks getPath / getPaths as unstable API functions.
src/Deprecated.jl Refactors legacy path utilities to deprecate/redirect to getPath[s].
test/testBlocks.jl Adds PathFindingTests covering multiple graph/path/filter scenarios.
test/interfaceTests.jl Adds a "Path Finding" testset invoking PathFindingTests.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@codecov
Copy link

codecov bot commented Mar 24, 2026

Codecov Report

❌ Patch coverage is 62.74510% with 19 lines in your changes missing coverage. Please review.
✅ Project coverage is 79.96%. Comparing base (5f896ed) to head (c871442).

Files with missing lines Patch % Lines
src/Deprecated.jl 0.00% 16 Missing ⚠️
src/GraphsDFG/services/GraphsDFG.jl 90.90% 3 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1214      +/-   ##
===========================================
+ Coverage    79.16%   79.96%   +0.79%     
===========================================
  Files           37       37              
  Lines         2506     2520      +14     
===========================================
+ Hits          1984     2015      +31     
+ Misses         522      505      -17     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 8 out of 8 changed files in this pull request and generated 4 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants