Skip to content

SCANPY-235 Fix documentation and behavior of --toml-path#300

Open
marc-jasper-sonarsource wants to merge 1 commit intomasterfrom
MJ/SCANPY-235
Open

SCANPY-235 Fix documentation and behavior of --toml-path#300
marc-jasper-sonarsource wants to merge 1 commit intomasterfrom
MJ/SCANPY-235

Conversation

@marc-jasper-sonarsource
Copy link
Contributor

No description provided.

@sonar-review-alpha
Copy link

sonar-review-alpha bot commented Mar 16, 2026

Summary

Summary

This PR enhances the --toml-path CLI argument to accept either:

  • A full path to the pyproject.toml file directly, OR
  • A path to the folder containing it (the previous behavior)

The changes include:

  • Updated documentation (CLI help text, README, and CLI args documentation) to clarify both usage patterns
  • Modified TomlConfigurationLoader.load() to detect whether the provided path is a file or directory and handle both cases
  • Variable rename (toml_dirtoml_path) to better reflect the dual-mode functionality
  • New unit tests covering the direct file path scenario

This improves usability by allowing more flexible path specifications without breaking existing code that passes directory paths.

What reviewers should know

This PR comment is ready to post at the top of PR #300. It provides reviewers with a quick 30-second overview of the changes: what the feature does, which files were touched, and why it matters (improved usability). The comment complements the lack of an author description by explaining both the documentation updates and the behavioral change in the code.


  • Generate Walkthrough
  • Generate Diagram

🗣️ Give feedback

@hashicorp-vault-sonar-prod
Copy link

hashicorp-vault-sonar-prod bot commented Mar 16, 2026

SCANPY-235

@sonarqube-next
Copy link

Copy link
Contributor

@thomas-serre-sonarsource thomas-serre-sonarsource left a comment

Choose a reason for hiding this comment

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

LGTM !

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