diff --git a/README.md b/README.md index 8e0d53a..8ec6671 100644 --- a/README.md +++ b/README.md @@ -3,22 +3,42 @@ This is Exercism's automated analyzer for the Python track exercises. It is based on and uses [PyLint][pylint-github]. -It is run from a docker container using `./bin/run-in-docker.sh $EXERCISM $PATH_TO_FILES $PATH_FOR_OUTPUT` and will read the source code from `$PATH_TO_FILES` and write a text file with an analysis to `$PATH_FOR_OUTPUT`. +It is run from a docker container using `./bin/run-in-docker.sh `. +It will read the source code from `` and write a `.json` file with an analysis to ``. +Please note `` & `` need to be **_relative_** to the location of this repo in your environment. -For example: +For example, from the `python-analyzer/` (project root) directory: ```bash ./bin/run-in-docker.sh two_fer ~/solution-238382y7sds7fsadfasj23j/ ~/solution-238382y7sds7fsadfasj23j/output/ ``` -Unit tests also require [docker][docker] and can be run locally or from within GitHub via [codespaces][codespaces]: +Or if you also have the Python content repo cloned alongside this repo and have a solution saved in the stub file. +From the `python-analyzer/` (project root) directory you can run: ```bash - -#run from the python-analyzer (project root) directory. -./bin/run-tests-in-docker.sh +./bin/run-in-docker.sh two_fer ../python/exercises/practice/two-fer/ ../python/exercises/practice/two-fer/ ``` + +## Running the Tests for the Analyzer + +Unit tests require [docker][docker] and can be run locally or from within GitHub via [codespaces][codespaces]: + +1. Build the analyzer image from the Dockerfile +2. Open a terminal in the root of your copy/local copy of this project. +3. From the `python-analyzer/` (project root) directory run: + ```bash + ./bin/run-tests-in-docker.sh + ``` + + +> [!NOTE] +> The PyLint portion of the Analyzer will respect the `# pylint: disable=`, `# pylint: disable-next=`, and `# pylint: disable=all` directives from within code files, but it is recommended that you use them sparingly. +> +> For more details, see [PyLint message control](https://pylint.pycqa.org/en/latest/user_guide/messages/message_control.html#block-disables). + + [pylint-github]: https://github.com/pylint-dev/pylint [docker]: https://www.docker.com/ [codespaces]: https://github.com/features/codespaces diff --git a/lib/common/pylint_data/messages/disallowed-name/bad.py b/lib/common/pylint_data/messages/disallowed-name/bad.py index 272c7cb..109ee81 100644 --- a/lib/common/pylint_data/messages/disallowed-name/bad.py +++ b/lib/common/pylint_data/messages/disallowed-name/bad.py @@ -3,4 +3,4 @@ def foo(): # [disallowed-name] x = 15 # [disallowed-name] y = 12 # [disallowed-name] -result = x + y \ No newline at end of file +result = x + y