This tutorial How to enable and disable spell check in the code editor for comment string

Pycharm enable and disable Spelling

  • By default, Code editor shows jagged lines for a comment text for spelling mistakes

pycharm settings

  • First, go to Settings Item under File Menu

  • Open File Menu, Select Settings Menu Item

pycharm settings

  • Select the Editor Tab on the left side
  • Select Proofreading that shows below three options checks
    • Grammar: Grammar mistakes
    • Natural language Detection: Grammar and spelling mistakes
    • Typo: Typos for a given word

check or uncheck the Typo checkbox to enable/disable comment string spell check

You can suppress the jagged lines by adding comments with a line contains # noinspection SpellCheckingInspection

Here is an example

class calculator:
    def add(m,n):
        # noinspection SpellCheckingInspection
        """
        add two numbers, return the result
        :param n:
        :return:
        """
        return m+n;