{"id":9240,"library":"pyspelling","title":"PySpelling","description":"PySpelling is a powerful spell checker for various text formats, including Markdown, reStructuredText, HTML, and Python source code. It acts as a wrapper for external spell checkers like Aspell or Hunspell, providing a unified configuration and reporting interface. Currently at version 2.12.1, it typically releases new versions every few months, often incorporating new Python version support, minor features, and bug fixes.","status":"active","version":"2.12.1","language":"en","source_language":"en","source_url":"https://github.com/facelessuser/pyspelling","tags":["spell checker","linter","documentation quality","code quality","ci/cd"],"install":[{"cmd":"pip install pyspelling","lang":"bash","label":"Install PySpelling"}],"dependencies":[],"imports":[{"note":"While PySpelling can be used programmatically, its primary use case is via the command-line interface with a configuration file.","symbol":"Pyspelling","correct":"from pyspelling import Pyspelling"}],"quickstart":{"code":"echo \"sources:\\n  - './*.md'\\naspell:\\n  lang: en\\n  d: en_US\\ndictionary:\\n  wordlists:\\n    - .pyspelling_wordlist.txt\\n  encoding: utf-8\\n\" > .pyspelling.yml\n\necho \"# My Document\\n\\nThis is a test with a mispelled word: misstake.\" > test.md\n\n# Run spell check\npyspelling\n\n# Expected output (simplified, actual output depends on Aspell/Hunspell installation):\n# test.md:2: misstake","lang":"bash","description":"Create a `.pyspelling.yml` configuration file and then run `pyspelling` from your terminal. This example checks Markdown files using Aspell and a custom wordlist. Ensure you have Aspell or Hunspell installed on your system."},"warnings":[{"fix":"Upgrade your Python environment to 3.9+ (e.g., Python 3.9, 3.10, 3.11, 3.12, 3.13, 3.14).","message":"Python 3.6, 3.7, and 3.8 are no longer supported. Ensure your environment uses Python 3.9 or newer.","severity":"breaking","affected_versions":"2.8, 2.9, 2.11"},{"fix":"Install Aspell (e.g., `sudo apt-get install aspell aspell-en` on Debian/Ubuntu, `brew install aspell` on macOS) or Hunspell on your operating system.","message":"PySpelling requires an external spell checker like Aspell or Hunspell to be installed on your system. It does not provide its own spell checking engine.","severity":"gotcha","affected_versions":"All versions"},{"fix":"Carefully review your `.pyspelling.yml` file for YAML syntax errors. Use a YAML linter if unsure.","message":"The configuration file (`.pyspelling.yml`) must be valid YAML. Incorrect indentation or syntax can lead to parsing errors.","severity":"gotcha","affected_versions":"All versions"},{"fix":"Use `pyspelling --skip-dict-compile` to speed up subsequent runs when custom dictionaries are stable. Note that changes to a custom dictionary will be ignored with this option.","message":"Dictionary compilation can be slow for large custom dictionaries. Starting with 2.11, `--skip-dict-compile` can be used to skip recompilation if the dictionary exists and hasn't changed.","severity":"gotcha","affected_versions":">=2.11"}],"env_vars":null,"last_verified":"2026-04-16T00:00:00.000Z","next_check":"2026-07-15T00:00:00.000Z","problems":[{"fix":"Install Aspell on your operating system. For Debian/Ubuntu: `sudo apt-get install aspell aspell-en`. For macOS: `brew install aspell`.","cause":"The Aspell spell checker is not installed or not in your system's PATH.","error":"sh: aspell: command not found"},{"fix":"Install Hunspell on your operating system. For Debian/Ubuntu: `sudo apt-get install hunspell hunspell-en-us`. For macOS: `brew install hunspell`.","cause":"The Hunspell spell checker is not installed or not in your system's PATH.","error":"sh: hunspell: command not found"},{"fix":"Create a `.pyspelling.yml` file in your current working directory, or specify its path using `pyspelling -c /path/to/config.yml`.","cause":"PySpelling could not find its configuration file (`.pyspelling.yml`).","error":"Error: No configuration file found. Please provide one with -c or place .pyspelling.yml in the current directory."},{"fix":"Review and correct the YAML syntax in your `.pyspelling.yml` file. Tools like online YAML validators can help.","cause":"Your `.pyspelling.yml` file contains YAML syntax errors (e.g., incorrect indentation, missing colons).","error":"Error loading config file: ... (e.g., YAMLError: while parsing a block mapping)"},{"fix":"Install the package using pip: `pip install pyspelling`.","cause":"The pyspelling Python package is not installed in your current Python environment.","error":"ModuleNotFoundError: No module named 'pyspelling'"}]}