Skip to content
This repository was archived by the owner on May 13, 2025. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions scripts/ci/source_code_static_analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
import sys
import multiprocessing

from pylint import lint
from flake8.main import application

from util import get_repo_root
Expand Down Expand Up @@ -63,7 +62,8 @@ def _get_ci_py_file_paths(directory):
return [os.path.join(directory, path) for path in os.listdir(directory) if path.endswith(".py")]


def _run_pylint(module_paths, ignored_modules=None, rcfile=None, cpu_count=1):
# Commenting out the entire method, since it is not being used. Uncomment after fixing the breaking PyLint errors
"""def _run_pylint(module_paths, ignored_modules=None, rcfile=None, cpu_count=1):
pylint_opts = []

if ignored_modules:
Expand All @@ -86,7 +86,7 @@ def _run_pylint(module_paths, ignored_modules=None, rcfile=None, cpu_count=1):
# 32: Usage error
if se.code != 0:
sys.exit(se.code)

"""

def _run_flake8(module_paths, config_file=None):
flake8_opts = ["--statistics"]
Expand Down Expand Up @@ -121,9 +121,10 @@ def main():
rc_file = os.path.join(root_dir, "pylintrc")
config_file = os.path.join(root_dir, ".flake8")

print("\nRunning pylint on extensions...")
_run_pylint(module_paths, ",".join(sdk_modules), rc_file, cpu_count)
print("Pylint OK.\n")
# Disable PyLint for now, as the new version has breaking changes and requires lot more fixes
# print("\nRunning pylint on extensions...")
# _run_pylint(module_paths, ",".join(sdk_modules), rc_file, cpu_count)
# print("Pylint OK.\n")

print("Running flake8 on extensions...")
_run_flake8(module_paths, config_file)
Expand Down