Skip to content

incremental_files_only appears to be ignored #2325

Open

Description

@tpeterson-metropolis

I'm seeing a pair of issues:

  1. Typos from a PR are not caught until the code is merged
  2. Said typos are then picked up in unrelated changes despite those files not being touched in those changes

Details from action run:

Run streetsidesoftware/cspell-action@eb29b6a67d122d2e6af385ff16bdb200d93b2e54
  with:
    check_dot_files: true
    config: ./.github/spelling/cspell.json
    suggestions: true
    incremental_files_only: true
    inline: warning
    treat_flagged_words_as_errors: false
    strict: true
    verbose: false
    use_cspell_files: false

Activity

  1. Jason3S commented on May 28, 2025

    @Jason3S
    Contributor

    @tpeterson-metropolis,

    Thank you. I'll see if I can reproduce it.

  2. Jason3S commented on May 28, 2025

    @Jason3S
    Contributor

    @tpeterson-metropolis,

    I'm not able to reproduce the issue you are seeing.

    It causes an error for me: streetsidesoftware/cspell-action-example#2

    Do you have an example repo that shows the issue?

  3. Kingdutch commented on Aug 6, 2025

    @Kingdutch

    We were running into the same issue with the following output:

    Run streetsidesoftware/cspell-action@v7
      with:
        incremental_files_only: true
        inline: warning
        treat_flagged_words_as_errors: false
        strict: true
        suggestions: false
        verbose: false
        check_dot_files: explicit
        use_cspell_files: false
        report: all
      env:
        BRANCH_NAME: internal/spellcheck
      
    cspell-action
    Pull Request
    Files checked: 0, Issues found: 0 in 0 files.
    Done.
    

    The job for this is

      spellcheck:
        name: Spell Check
        runs-on: [self-hosted, normal]
        steps:
          - uses: actions/checkout@v4
          - uses: streetsidesoftware/cspell-action@v7
    

    While trying to provide a small cspell.json that could reproduce this I found that it was specifically caused by a files entry in the configuration which looked like the following:

    {
      "files": [
        ".github",
        "applications/application_a/docker",
        "applications/application_a/html/modules/concepts",
        "applications/application_a/html/modules/extensions",
        "applications/application_a/html/modules/projects",
        "applications/application_a/html/profiles/profile",
        "applications/application_a/scripts",
        "applications/application_a/tests",
        "applications/application_a/tools",
        "applications/application_b"
      ]
    }
    

    Removing that files entry would cause the GitHub action to work as expected. Locally this files configuration already works as expected.

    My hypothesis is that this could be a difference between how the GitHub action interprets this vs how CSpell itself does so. Or it's a platform difference (Mac locally; Linux in the CI).

    Re-reading the documentation, I suspect that our configuration might be invalid (it's not actually a glob?) but it's not exactly clear to me whether that's true or why it would then still work on our local development machines.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions