Skip to content

actions_python_radon

Actions
Github action for running code complexity analysis with radon
v1.0.0
Latest
Star (0)

actions_python_radon

A Github action for running code complexity analysis with radon. This action uses the cc command from radon to compute the Cyclomatic Complexity of Python source files.


How to use

In your .github/workflows directory, create a yaml file (such as main.yaml). Add a job for each desired workflow with the uses keyword. Use the with keyword to pass any desired variables.

Examples:

on: [push]

jobs:
  radon:
    runs-on: ubuntu-latest
    name: "radon"
    steps:
      - uses: actions/checkout@v3
      - uses: davidslusser/actions_python_radon@v1.0.0

on: [push]

jobs:
  radon:
    runs-on: ubuntu-latest
    name: "radon"
    steps:
      - uses: actions/checkout@v3
      - uses: davidslusser/actions_python_radon@v1.0.0
        with:
          src: "src"
          min: "A"
          grade: "B"

Inputs

  • src: source file or directory used for analysis (defaults to ".")
  • grade: letter grade (rank) to use for pass/fail; average complexity must be equal or greater than this value to pass (defaults to "B")
  • min: minimum complexity rank to display (defaults to "A")

References

actions_python_radon is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.

About

Github action for running code complexity analysis with radon
v1.0.0
Latest

actions_python_radon is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.