Skip to content

feat: add -S flag to skip *.pth evaluation during environment analysis#1032

Merged
jkowalleck merged 13 commits intomainfrom
feat/env-dont-import-site
Mar 30, 2026
Merged

feat: add -S flag to skip *.pth evaluation during environment analysis#1032
jkowalleck merged 13 commits intomainfrom
feat/env-dont-import-site

Conversation

@jkowalleck
Copy link
Copy Markdown
Member

@jkowalleck jkowalleck commented Mar 30, 2026

Description

Add an option cyclonex environment -S to prevent evaluation of pth files.

-S    Do not implicitly import site during Python path detection.
      Prevents evaluation of `*.pth` files, but may lead to incomplete component detection.

fixes #1031

AI Tool Disclosure

  • My contribution does not include any AI-generated content
  • My contribution includes AI-generated content, as disclosed below:
    • AI Tools: [e.g. GitHub CoPilot, ChatGPT, JetBrains Junie etc.]
    • LLMs and versions: [e.g. GPT-4.1, Claude Haiku 4.5, Gemini 2.5 Pro etc.]
    • Prompts: [Summarize the key prompts or instructions given to the AI tools]

Affirmation

Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
@jkowalleck jkowalleck requested a review from a team as a code owner March 30, 2026 11:46
@jkowalleck jkowalleck added the enhancement New feature or request label Mar 30, 2026
Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
@codacy-production
Copy link
Copy Markdown

codacy-production bot commented Mar 30, 2026

Coverage summary from Codacy

See diff coverage on Codacy

Coverage variation Diff coverage
-0.06% (target: -1.00%) 92.86% (target: 80.00%)
Coverage variation details
Coverable lines Covered lines Coverage
Common ancestor commit (ecf8768) 1143 1109 97.03%
Head commit (71e08d6) 1152 (+9) 1117 (+8) 96.96% (-0.06%)

Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: <coverage of head commit> - <coverage of common ancestor commit>

Diff coverage details
Coverable lines Covered lines Diff coverage
Pull request (#1032) 14 13 92.86%

Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: <covered lines added or modified>/<coverable lines added or modified> * 100%

See your quality gate settings    Change summary preferences

Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
@read-the-docs-community
Copy link
Copy Markdown

Documentation build overview

📚 CycloneDX Python SBOM Tool | 🛠️ Build #32036130 | 📁 Comparing 71e08d6 against latest (ecf8768)


🔍 Preview build

Show files changed (1 files in total): 📝 1 modified | ➕ 0 added | ➖ 0 deleted
File Status
usage.html 📝 modified

@jkowalleck jkowalleck changed the title feat: add option to not evaluate pth files on environment analysis feat: add -S flag to prevent implicit *.pth imports in environment scan Mar 30, 2026
@jkowalleck jkowalleck changed the title feat: add -S flag to prevent implicit *.pth imports in environment scan feat: add -S flag to skip *.pth evaluation during environment analysis Mar 30, 2026
@jkowalleck jkowalleck merged commit 55c15d7 into main Mar 30, 2026
36 checks passed
@jkowalleck jkowalleck deleted the feat/env-dont-import-site branch March 30, 2026 12:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: add option to not evaluate pth files on environment analysis

1 participant