summaryrefslogtreecommitdiff
path: root/doc/ale-python.txt
AgeCommit message (Collapse)Author
2021-03-18issue 3033 (#3620)Nathan Henrie
* Add ale_python_pyls_options * Add extra explanatory detail * Fix alignment * Fix test
2021-01-13Merge pull request #3398 from ecly/update-python-find-rootHoracio Sanson
Update `ale#python#FindProjectRootIni` with poetry.lock and pyproject.toml
2020-11-21Document ale_python_isort_auto_pipenv optionIvor Peles
2020-11-21Merge pull request #3409 from lyz-code/feat/add-autoimport-supportw0rp
feat: add autoimport fixer
2020-10-23feat: add autoimport fixerLyz
2020-10-15Update FindProjectRootIni with poetry.lock and pyproject.tomlecly
2020-10-02Fix typo in ale-python.txtrgossiaux
2020-08-30Run flake8 from project root by default.Konstantin Alekseev
Option `per-file-ignores` was introduced in flake8 version 3.7.0. It allows to ignore specific errors in specific files using glob syntax. For example `per-file-ignores = src/generated/*.py:F401` will ignore `F401` error in all python files in `src/generated`. Thus ale has to run flake8 from project root where .flake8 config is placed otherwise glob won't match linted file.
2020-08-07Close #2472 - Add support for pyrightw0rp
2020-01-02Fix #2704 - Show mypy notes; can be disabledw0rp
2019-06-08Add support for reorder-python-imports fixerJake Kaufman
isort is great, but I've come to prefer reorder-python-imports. The tool has a focus on smaller diffs than isort. reorder-python-imports is also a little smarter than isort which is nice.
2019-05-19Change Python project root dir detection for flake8 configurationEric N. Vander Weele
The official configuration files for `flake8` are `.flake8`, `tox.ini`, and `setup.cfg`. After investigation, it is safe to remove `flake8.cfg` as it appears to only exist as a typo in other tooling documentation (e.g., `python-language-server`). Even though no linters automatically read `.flake8rc`, it is kept in case projects may be using it for detecting the projects root directory.
2019-05-09Add option to show msg id when pylint is used (#2445)Katsuya Horiuchi
* Add python_pylint_use_msg_id to tweak output of pylint * Add test for ale_python_pylint_use_msg_id * Add doc on ale_python_pylint_use_msg_id
2019-02-20Merge pull request #2303 from kevinoid/bandit-use-configw0rp
python/bandit: Use .bandit configuration file
2019-02-17python/bandit: Use .bandit configuration fileKevin Locke
Bandit automatically [uses any .bandit file] within the directories on which it is invoked. Since ALE invokes bandit on stdin, it does not load a .bandit file automatically. Add support for automatically finding a .bandit file and passing it to bandit via the --ini option along with a variable to disable this behavior if desired. Note: This is useful for the skips and tests configuration options, but not exclude which would require invoking bandit using a file name, which may or may not be a good trade-off. [uses any .bandit file]: https://github.com/PyCQA/bandit/blob/1.5.1/bandit/cli/main.py#L70-L73 Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
2019-02-17python/pylint: Change directory to project rootKevin Locke
Pylint only [checks for pylintrc] (and .pylintrc) files in the packages aboves its current directory before falling back to user and global pylintrc. For projects with a src dir, running pylint from the directory containing the file will not use the project pylintrc. Adopt the convention used by many other Python linters of running from the project root, which solves this issue. Add pylintrc and .pylintrc to FindProjectRoot. Update docs. [checks for pylintrc]: https://github.com/PyCQA/pylint/blob/pylint-2.2.2/pylint/config.py#L106 Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
2019-02-10Document and test ale_python_vulture_optionsKevin Locke
The vulture linter already supports ale_python_vulture_options, but it is not documented or tested. Since vulture only supports configuration via options, it is an important use case. Add docs and test. Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
2019-02-08Support pylama for python (#2266)Kevin Locke
* Add pylama for python * Consolidate python traceback handling
2019-01-30Respect python black fixer configuration fileAiden Scandella
Similar to other linters/fixers, by default change to the directory of the file being fixed before invoking `black`, which allows the tool to read project-specific configuration (pyproject.toml) Fixes #2218
2019-01-26Add bandit linter for PythonMartino Pilia
2019-01-20Add support for pyls configuration optionsyut23
Resolves #1443. Heavily inspired by the analogous support added for elixir-ls.
2019-01-03Fix some formatting issuesw0rp
2018-12-21Add documentation for python_black_auto_pipenvMiklós Tusz
2018-12-06Add support for pydocstyle linter (#2085)pmacosta
The linter can correctly parse pydocstyle output with any of the following command-line options enabled: --explain, --source, --debug, and/or --verbose
2018-09-15Add `python_auto_pipenv` config var for all python linters.Eddie Lebow
This allows a user to set one variable instead of eight.
2018-09-15Add python_[linter]_auto_pipenv options for python linters (fixes #1656)Eddie Lebow
When set to true, and the buffer is currently inside a pipenv, GetExecutable will return "pipenv", which will trigger the existing functionality to append the correct pipenv arguments to run each linter. Defaults to false. I was going to implement ale#python#PipenvPresent by invoking `pipenv --venv` or `pipenv --where`, but it seemed to be abominably slow, even to the point where the test suite wasn't even finishing ("Tried to run tests 3 times"). The diff is: diff --git a/autoload/ale/python.vim b/autoload/ale/python.vim index 7baae079..8c100d41 100644 --- a/autoload/ale/python.vim +++ b/autoload/ale/python.vim @@ -106,5 +106,9 @@ endfunction " Detects whether a pipenv environment is present. function! ale#python#PipenvPresent(buffer) abort - return findfile('Pipfile.lock', expand('#' . a:buffer . ':p:h') . ';') isnot# '' + let l:cd_string = ale#path#BufferCdString(a:buffer) + let l:output = systemlist(l:cd_string . 'pipenv --where')[0] + " `pipenv --where` returns the path to the dir containing the Pipfile + " if in a pipenv, or some error text otherwise. + return strpart(l:output, 0, 18) !=# "No Pipfile present" endfunction Using vim's `findfile` is much faster, behaves correctly in the majority of situations, and also works reliably when the `pipenv` command doesn't exist.
2018-08-01python: add lookup path for flake8 configTravis Cline
2018-07-26Add support for 'vulture' for PythonYauhen Kirylau
2018-07-15Update the Python documentationw0rp
2018-07-05Fix the doctag alignmentw0rp
2018-07-04add options variable to isortDerek P Sifford
2018-07-01add pyre lsp linter to python lintersDerek P Sifford
2018-06-05Allow all Python linter executables to be set to `pipenv`.Eddie Lebow
It appends ` run {linter_name}`, analogously to the Ruby linters when the executable is set to `bundle`
2018-05-30Fix #1219 - Mention FindProjectRoot behavior for Python in the documentationw0rp
2018-05-28Fix #1566 - Add g:ale_python_flake8_change_directoryw0rp
2018-04-17Fix #1507 - Add an option for disabling switching directories for pylintw0rp
2018-04-09Close #542 - Add an option for disabling running locally installed ↵w0rp
executables by default
2018-04-06Added support for Python black fixer (#1451)Jack Evans
2018-01-11Allow syntax errors for mypy to be ignoredw0rp
2017-12-01Add prospector for checking Python code (#1183)Carlos Coêlho
2017-11-21Escape the pyls executable in the command, and support running virtualenv ↵w0rp
pyls executables
2017-11-08Add PyLS linter (#1097)Auri
* Support PyLS (python language server) * Replace pyls#GetProjectRoot and add more config types to ale#python#FindProjectRoot
2017-10-24example for 'rcfile' on ale_python_pylint_options Su Shangjun
Two hyphens instead of one will enable the option `rcfile`.
2017-08-25Add pycodestyle Python linter support (#872)Michael
Add a pycodestyle linter
2017-07-08Document the virtualenv directories variable in the main file insteadw0rp
2017-07-08Use equal signs for language documentation sectionsw0rp
2017-06-27Fix #680 - Use --shadow-file to check for problems with mypy while you typew0rp
2017-06-18#659 - Add options for Python fixers, and cut down on duplicated documentationw0rp
2017-06-07Put ve-py3 before ve, so Python 3 executables will be preferredw0rp
2017-05-20#563 Use a configurable list of directories for detecting virtualenv paths ↵w0rp
instead.