Skip to content
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

Github Actions : Added Mypy and Python Bandit Security automation #1284

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

hardiksharma11
Copy link
Contributor

Proposed changes

Brief description of what is fixed or changed

Mypy Check : Validate and enforce type annotations and static typing.
Bandit Security Test : Scan for security vulnerabilities and potential security risks.

Types of changes

Put an x in the boxes that apply

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Other (please describe):

Checklist

Put an x in the boxes that apply

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have created new branch for this pull request
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • My changes does not break the current system and it passes all the current test cases.

Screenshots

Please attach the screenshots of the changes made in case of change in user interface

Other information

Any other information that is important to this pull request

@FusionIIIT-Bot
Copy link
Collaborator

Congratulations for making your first Pull Request at Fusion!! 🎉 Someone from our team will review it soon.

Copy link

@Shivkant-Chauhan Shivkant-Chauhan left a comment

Choose a reason for hiding this comment

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

Thanks for the PR @hardiksharma11. I have left few changes. Also remove the irrelevant comments since not required

uses: ioggstream/[email protected] # Using Bandit for security checks
with:
project_path: . # Path to the project to scan
ignore_failure: true # Continue the workflow even if Bandit reports issues

Choose a reason for hiding this comment

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

we obviously dont want to ignore errors and failures. we want the checks to fail on encountering such errors


jobs:
build:
runs-on: ubuntu-latest # Executes the job on the latest version of Ubuntu

Choose a reason for hiding this comment

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

point to a ubuntu version (preferably 22.04), not pinning a version might introduce regression in future

@@ -0,0 +1,27 @@
name: Security check - Bandit # Name of the GitHub Actions workflow

on: [push, pull_request] # Trigger the workflow

Choose a reason for hiding this comment

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

why are you thinking we should run the actions on both the time we "push" changes and open "pull requests".

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