Skip to content

Add guardrail in case manifest file does not exist #93

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 30, 2025

Conversation

dacoburn
Copy link
Collaborator

Root Cause

Logic for only creating the license file if a diff scan was ran was incorrect

Fix

Changed logic for detection

Public Changelog

N/A

@dacoburn dacoburn requested a review from a team as a code owner June 30, 2025 14:15
@dacoburn dacoburn requested review from cenobitedk and philidem and removed request for a team June 30, 2025 14:15
Copy link

🚀 Preview package published!

Install with:

pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple socketsecurity==2.1.15.dev1

Docker image: socketdev/cli:pr-93

@dacoburn dacoburn merged commit c2183b5 into main Jun 30, 2025
6 checks passed
@dacoburn dacoburn deleted the doug/fix-skip-logic branch June 30, 2025 14:24
@dacoburn dacoburn restored the doug/fix-skip-logic branch June 30, 2025 14:25
for manifest_data in package.manifestFiles:
manifest_file = manifest_data.get("file")
manifests += f"{manifest_file};"
if hasattr(package, "manifestFiles"):
Copy link
Member

Choose a reason for hiding this comment

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

This could be simplified to else:, no?

@@ -260,7 +260,7 @@ def main_code():
output_handler.handle_output(diff)

# Handle license generation
if diff is not None and diff.id != "no_diff_id" and config.generate_license:
if should_skip_scan and diff.id != "no_diff_id" and config.generate_license:
Copy link
Member

Choose a reason for hiding this comment

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

Is this correct? Or did you mean to check for whether NOT should_skip_scan here?

dacoburn added a commit that referenced this pull request Jun 30, 2025
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.

3 participants