doomemacs / doomemacs/modules

Cannot add words to dictionaries

Open
#58 0 comments 0 reactions 0 assignees View on GitHub
:checkers spell
Dominant language
Emacs Lisp
Stars
61
Forks
37
Avg merge
11h 19m
Merged PRs (30d)
7

Description

### Describe your issue

Recently, adding words via `+spell/add-word` stopped working resulting in the following error:
```
ispell-get-decoded-string: No data for dictionary "nil" in ‘ispell-local-dictionary-alist’ or ‘ispell-dictionary-alist’
```
[spell.log](https://github.com/user-attachments/files/30962091/spell.log) (with debug enabled on spell-fu)
[spell.backtrace.log](https://github.com/user-attachments/files/30962109/spell.backtrace.log)

The error has a 100% repro-rate and only while debugging I've noticed that it doesn't happen for first couple of seconds after starting doom.

I believe this started happening after I did `doom upgrade` (was few weeks old at that time), since I didn't update my config in recent weeks and I add new words all the time. This also started happening on my work computer as well where I've updated doom as well.

I have tried clearing my whole config aside from the spell-checking block here (ref: https://github.com/ArtemSmaznov/dotfiles-doom-emacs/blob/master/README.org?plain=1#L1339-L1392) with no better results. I've also tried emptying all my personal dictionaries and the contents of `~/.config/emacs/.local/etc/spell-fu/*` - same story.

I've checked both `ispell-local-dictionary-alist` and `ispell-dictionary-alist` and can see that both are `nil` in the first few seconds while adding words work as well as after.

Any idea is something changed on Doom side to have caused this? Would appreciate any help troubleshooting this.

### Steps to reproduce

1. Open Emacs,
2. Quickly open any buffer and enable `spell-fu-mode` if it is not enabled by default
3. Put cursor on any word
4. Trigger `+spell/add-word` (can do via `zg` in evil mode)
5. If the dictionary selection popup shows up, escape it
6. Wait for a some seconds
7. Try `+spell/add-word`
8. After a small amount of time (5-20 sec in my case) you will start getting the error on every attempt until emacs is restarted

### System information

[doom.info.txt](https://github.com/user-attachments/files/30962332/doom.info.txt)

### Disclosures

- [ ] This issue was written with/by AI.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with +spell/add-word and spell-fu-mode, then inspect how ispell-local-dictionary-alist and ispell-dictionary-alist change after startup. Review the attached spell.log and spell.backtrace.log alongside the spell-checking configuration and ~/.config/emacs/.local/etc/spell-fu/. Done means adding a word works after startup without the nil-dictionary error.

Written by the indexing model from the issue text.

Assessment

Tech stack
emacs, emacs-lisp
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.