Where communities thrive

  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
    Richard Lopes
    hey guys how do I prevent lint for showing errors on a node_modules file?
    Tomasz Trębski
    hey, can someone help me out. Do I need such code while working inside of virtualenv?
    Mainly I prefer yapf but some projects have black, just wonder if explicit setting of fixers is needed or not:
    Dan Aloni
    I wrote an ALE checker for git rebase -i: https://github.com/da-x/depree
    Hi. I am currently updating my neovim config and have found the g:ale_sign_highlight_linenrs option. I really like it and now want to disable display of errors in the sign column only. Is this possible?
    Hi, any idea how to let ale detect node global modules?
    ✖ fs.writeFileSync(resolve(__dirname, '../src/mock/users.json'), JSON.stringify(users, null, 2));   Cannot find name '__dirname'.
    it says Cannot find name '__dirname'.
    same for module.exports
    I gete this
    ⚠ module.exports = {  File ignored by default. Use a negated ignore pattern (like "--ignore-pattern '!<relative/path/to/filename>'") to over

    and today I started to get this


    i'm trying to get vim / ale to correctly recognize a pygame installed through pip in the current venv.
    the linting of the python code is correct. but pygame is not recognized.
    any idea?
    here is the output of : :ALEInfo: https://paste.opensuse.org/view/raw/95106447
    John Meow
    How do I make ale show a small split with errors under my code?
    Abid K
    Is it possible to use clang-format with ALE and show format issues in the C++ code?
    John Meow
    I get this if I have "clangtidy" in my g:ale_fixers.cpp
    How to fix it?
    why do I get this error
    ale#fix#ApplyFixes: line 18: The file was changed before fixing finished
    Konstantin Baierer
    Hi, is it possible to restrict linting warning level to show only real errors? I have a large codebase with lots of stylistic issues and I'm only interested in errors like missing imports, undefined variables etc.
    Konstantin Baierer
    I just realized ALENext, ALEPrevious etc. accept a -error argument that does just what I want.
    Kevin Clark
    @w0rp @neersighted @RyanSquared Hi folks - just wanted to give a heads up on dense-analysis/ale#3471 In particular, I thought what to do about the linters that have been failing name checks silently needed discussion. Please let me know if more information is needed or if there's anything I can do to help move the change along.
    I see a lot of stale and long lived PRs without review - if help is needed triaging any of that, i'm happy to chip in where I can.
    Laurent G
    Hi all
    I have a beginner question. I want to add some option to a linter command (ansible-lint). How can I do that?
    Playing with g:ale_ansible_ansible_lint_executable is the right way to do ?
    Laurent G
    hum, … let g:ale_ansible_ansible_lint_executable = 'ansible-lint -R -r ./my_rules' doesn't seem to work
    Laurent G
    Ok I tried putting my custom rules into the .ansible-lint config file. It's well taken into account if I run ansible-lint my_playbook.yml but not in vim with ALE. :-/
    Maybe something in my python rules that was ok with ansible-lint but not with ALE?
    Laurent G
    I think my issue is that my path to my custom lint rules is relative. I don't know from where is launch the linters by ALE
    but I assume it's not from my $PATH
    Laurent G
    If any one has any clue, I'm ready to hear!
    @xenlo ALE typically launches linters in a place called the "project root", which is normally identified by either a litner-specific file such as an eslintrc, or a VCS identifier such as a .git directory.
    ... however, I don't think ansible-lint has a project root option, so it would run in the PWD of the spawning process, I believe.
    (in this case, spawning process would be vim)
    Leonhard Saam
    Hello everyone,
    I am trying to switch from VSCode to Vim and was confused about the role of ALE in linting. If I understand everything correctly, ALE has a basic C++ linter. I'm not sure now what ALE actually does. Does it act as a middleman between the linter and Vim or what does it do?
    @The-personified-devil yes - ALE is a layer that takes the output from linters that typically run on the command line (or act as a language server!) and gives you editor functionality based on that.
    ALE itself is not a linter, ALE is the tool that uses linters.
    Kevin Watters
    I have my compiler sending errors to a file local to my project, like .compiler_errors
    what would be the easiest way to define an errorformat and read that file for errors? is there an existing linter i can look to that would have an example of reading from a file?
    @kevinw there's a pretty loosely defined format used by luacheck, teal, and other languages.
    test.tl:5:16: in local declaration: x: got string "hello", expected nil
    test.tl:7:6: argument 1: got <unknown type>, expected string
    So it's like, <filename>:<line>:<column>: <error message>
    Jeremy Zagorski
    Does anyone have experience using Docker Desktop + Rust with Ale? I was reading the ale-lint-other-machines help documentation to create a similar setup on a windows machine, but could not get it to work using the rust:latest image. The executable check fails. I'd be happy to provide my setup if anyone has a similar setup working (not necessarily rust)
    Alessandro Re

    Hello! I started using ALE with rust and python, and I like the experience so far! I have a problem with rust, though that I don't understand: when I create a library project, e.g. using cargo new --lib something, I will get an annoying warning for the code saying that the main is missing: 'main' function not found in crate 'something': consider adding a 'main' function at the crate level.

    How can I investigate/fix this?

    @akiross can you provide me with the output of :ALEInfo ? In general, I want to make sure that it's not rustc, as I don't think rustc actually cares whether it's a library or not.
    Alessandro Re
    Oh I didn't know about :ALEInfo, I'll take a look