Skip to content

chore: integrate SAST and OpenEnv validation to CI workflow#93

Draft
NITISH-R-G wants to merge 1 commit into
mainfrom
fix/ci-sast-openenv-jscpd-16353208196965208200
Draft

chore: integrate SAST and OpenEnv validation to CI workflow#93
NITISH-R-G wants to merge 1 commit into
mainfrom
fix/ci-sast-openenv-jscpd-16353208196965208200

Conversation

@NITISH-R-G

@NITISH-R-G NITISH-R-G commented Jun 29, 2026

Copy link
Copy Markdown
Owner

Included Bandit SAST and OpenEnv Validate to Server CI. Pinned jscpd version and fixed false positives. Created CYCLE 8 Report.


PR created automatically by Jules for task 16353208196965208200 started by @NITISH-R-G

Summary by Sourcery

Integrate additional security and environment validation checks into the CI code-quality workflow and stabilize duplicate code detection.

Enhancements:

  • Extend the Python code-quality job to install and run Bandit SAST scanning and OpenEnv environment validation.
  • Pin the jscpd Node tool to version 4.0.0 and update its ignore patterns to exclude build artifacts from duplicate code detection.

Documentation:

  • Add CYCLE_8_REPORT.md documenting current CI gaps, planned improvements, and their expected impact on reliability and security.

This commit bridges the gap between local validation (`validate-submission.sh`)
and the GitHub Actions CI pipeline by adding `bandit` and `openenv validate`
checks to the python quality job. This ensures a strict quality and security
gate on all future commits and PRs.

It also stabilizes the `jscpd` duplicate code step by pinning it to version
4.0.0 (preventing v5 platform incompatibilities) and explicitly ignoring
build artifacts (`**/dist/**` and `**/build/**`) to prevent false positives.

A new CYCLE_8_REPORT.md was created to document these improvements.

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
@google-labs-jules

Copy link
Copy Markdown
Contributor

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

NITISH-R-G has reached the 50-credit limit for trial accounts. To continue receiving code reviews, upgrade your plan.

@sourcery-ai

sourcery-ai Bot commented Jun 29, 2026

Copy link
Copy Markdown

Reviewer's Guide

Integrates Bandit SAST and OpenEnv validation into the Python CI job, stabilizes duplicate-code detection by pinning jscpd and ignoring build artifacts, and documents the changes and rationale in a new Cycle 8 report.

Flow diagram for updated CI code-quality checks

flowchart TD
  A[Push or PR to repository] --> B[GitHub Actions code-quality workflow]
  B --> C[python-quality job]
  C --> D[Install ruff mypy pydantic vulture radon bandit openenv-core]
  D --> E[Run bandit SAST]
  E --> F[Run openenv validate]
  F --> G[Run ruff lint]
  G --> H[Run mypy type-check]
  H --> I[Run tests]
  B --> J[duplicate-code job]
  J --> K[Install jscpd@4.0.0]
  K --> L[Run jscpd ignoring dist and build artifacts]
Loading

File-Level Changes

Change Details Files
Extend Python code-quality CI job to run Bandit SAST and OpenEnv validation.
  • Add bandit and openenv-core to the Python dependencies installed in the CI workflow.
  • Introduce a Bandit SAST step that runs security scanning using the project’s pyproject configuration.
  • Introduce an OpenEnv validation step that runs openenv validate . in CI.
.github/workflows/code-quality.yml
Stabilize jscpd duplicate code detection in CI and reduce false positives.
  • Pin jscpd to version 4.0.0 in the duplicate-code job.
  • Extend jscpd ignore patterns to exclude dist and build directories in addition to existing exclusions.
.github/workflows/code-quality.yml
Add a Cycle 8 report documenting CI health, gaps, and the improvement plan implemented by this PR.
  • Create CYCLE_8_REPORT.md summarizing current CI strengths, weaknesses, risks, and opportunities.
  • Document competitor analysis and priority improvements focused on SAST, environment validation, and duplicate-code detection.
  • Outline sprint plan, technical improvements, and expected metrics impacted by the CI changes.
CYCLE_8_REPORT.md

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@github-actions

Copy link
Copy Markdown

Failed to generate code suggestions for PR

@coderabbitai

coderabbitai Bot commented Jun 29, 2026

Copy link
Copy Markdown

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: dadb39ec-c721-4d64-805a-3ebdcc68f7e1

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/ci-sast-openenv-jscpd-16353208196965208200

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

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.

1 participant