Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
Following #3154665: Disable spell checking within Drupal\filter\Plugin\migrate\process\FilterID::getSourceFilterType() I regenerated the dictionary and noticed two words were removed:
- emtity
- linktitle
"emtity" is a spelling error - one of the module names is misspelled.
"linktitle" is a correctly spelled module name that can be removed from the dictionary.
Proposed resolution
Fix the spelling error and remove both words from the dictionary.
Remaining tasks
User interface changes
API changes
Data model changes
Release notes snippet
Comment | File | Size | Author |
---|---|---|---|
#5 | 3155463-5.patch | 2.15 KB | quietone |
#2 | 3155463.patch | 1 KB | longwave |
Comments
Comment #2
longwaveComment #3
quietone CreditAttribution: quietone as a volunteer commentedWhy is this removed here?
Comment #4
longwaveBecause "linktitle" only exists in the ignored section of code in FilterID.php, so it can be removed from the dictionary.
In #3154669-9: Fix or ignore 33 words only used in the PostgreSQL driver I tried an alternative approach of ignoring words, I am starting to think that explicitly listing the words to be ignored for an individual file is cleaner and perhaps something we should do here as well?
Comment #5
quietone CreditAttribution: quietone as a volunteer commented@longwave, I read the comments in the issue referred to. It seems to me that if you are going to add spellchecking then you would want to maximize the coverage. So, having ~100 lines ignored by the spell checker seems like a step backwards to me. So, I made a patch to see what it would look like. It does add some visual clutter but that doesn't outweigh the benefit. Just my 2c.
Comment #6
longwaveThanks for adding your opinion and uploading the patch.
Really not sure which is the best approach here, so going to mark this as RTBC and let core committers decide which route to go down.
Comment #7
jungleQuoting my comments on #3154669: Fix or ignore 33 words only used in the PostgreSQL driver -1 to #5
Comment #8
jungleWays to bypass cspell checking
ignorePaths
in.cspell.json
cSpell:ignore
, applicable to wordscSpell:disable/cSpell:enable
, applicable words spanning multiple linescSpell:disable-next-line
applicable to the line nextMy suggestion is to use them where applicable the most. all 4 ways are encouraged to use. but do not encourage using
cspell:ignore
as the following way. Instead, we should usecSpell:disable/cSpell:enable
,cSpell:disable-next-line
andcSpell:ignore
.Comment #9
alexpottI think #5 is good because then you get more spell checking. With #2 we could remove emtity from the dictionary and we would not find the spelling mistake - because cspell has been disabled. Therefore #5 is better.
Committed 5f504df and pushed to 9.1.x. Thanks!
Backported the actual speeling fix because it makes migrations better.
Committed and pushed 297f6a87df to 9.0.x and 21f227387b to 8.9.x. Thanks!