Skip to content

Conversation

@Borda
Copy link
Member

@Borda Borda commented Jan 7, 2026

This pull request refactors the CLI interface and entrypoint logic for the heatmap and tracking script, making it more robust and flexible. The main function is renamed and documented, and the CLI argument parsing now supports both jsonargparse and a fallback to positional arguments if the package is unavailable. This improves usability and maintainability of the script.

CLI and Entrypoint Refactor:

  • Replaced argparse with a conditional import of jsonargparse for CLI parsing, with fallback to positional arguments if jsonargparse is unavailable. This makes the script more flexible for different environments. [1] [2]
  • Renamed the main function from heatmap_and_track to main and added a comprehensive docstring describing all parameters for better clarity and maintainability. [1] [2]
  • Updated the script's entrypoint to call main directly with parsed arguments, removing the previous manual mapping and improving code readability.

Part of #2090

Copilot AI review requested due to automatic review settings January 7, 2026 19:41
@Borda Borda requested a review from SkalskiP as a code owner January 7, 2026 19:41
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 refactors the CLI argument parsing for the heatmap and tracking script by replacing argparse with conditional jsonargparse support and a positional argument fallback. The main function is renamed from heatmap_and_track to main and includes comprehensive parameter documentation.

Key Changes:

  • Replaced argparse with jsonargparse (with fallback to positional arguments when unavailable)
  • Renamed main function to main and added detailed docstring
  • Simplified CLI entrypoint using ArgumentParser.add_function_arguments()

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

@Borda Borda force-pushed the example/heatmap_and_track branch 2 times, most recently from a4d4d3b to f2efcc3 Compare January 7, 2026 20:00
Borda and others added 4 commits January 7, 2026 21:00
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@codecov
Copy link

codecov bot commented Jan 12, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 52%. Comparing base (8df7aea) to head (1421b11).
⚠️ Report is 6 commits behind head on develop.

Additional details and impacted files
@@           Coverage Diff           @@
##           develop   #2055   +/-   ##
=======================================
  Coverage       52%     52%           
=======================================
  Files           61      61           
  Lines         7077    7076    -1     
=======================================
  Hits          3657    3657           
+ Misses        3420    3419    -1     
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Borda Borda changed the title refactor(heatmap_and_track): improve CLI argument parsing example(heatmap_and_track): improve CLI argument parsing Jan 12, 2026
@Borda Borda changed the title example(heatmap_and_track): improve CLI argument parsing examples/heatmap_and_track: improve CLI argument parsing Jan 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants