ApplicationInsights-Python icon indicating copy to clipboard operation
ApplicationInsights-Python copied to clipboard

Find recursive pylint solution

Open jeremydvoss opened this issue 3 years ago • 1 comments

Pylint only runs on individual files or module folders with init.py. We need to run pylin recursively. Resources: https://stackoverflow.com/questions/36873096/run-pylint-for-all-python-files-in-a-directory-and-all-subdirectories https://askubuntu.com/questions/266179/how-to-exclude-ignore-hidden-files-and-directories-in-a-wildcard-embedded-find https://stackoverflow.com/questions/47642747/tox-warningtest-command-found-but-not-installed-in-testenv

jeremydvoss avatar Aug 16 '22 23:08 jeremydvoss

I've tried the following: find {toxinidir}/ -type f -name ".py" | xargs pylint find {toxinidir}/ -not -path '/.' -type f -name ".py" | xargs pylint pylint $(git ls-files '*.py')

None have worked yet. I think the find options could work. However, find seems to not be working correctly in the tox env.

jeremydvoss avatar Aug 16 '22 23:08 jeremydvoss

No longer needed after migrating to azure sdk

jeremydvoss avatar Oct 13 '23 20:10 jeremydvoss

Pylint managed by azure sdk: https://github.com/Azure/azure-sdk-for-python/blob/main/sdk/monitor/azure-monitor-opentelemetry/pyproject.toml#L6

jeremydvoss avatar Oct 16 '23 22:10 jeremydvoss