Community
    • Login

    Python PEP8 syntax warnings

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    7 Posts 3 Posters 8.4k Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Magnus HåkanssonM Offline
      Magnus Håkansson
      last edited by

      Hi all,

      When editing Python files, I would like a WARNING when my Python source code does not conform to the PEP8 code standard.

      For example, when there is whitespace at the end of a line, or when lines are not indented in the right way.

      I would NOT like the source code to be modified automatically, I want to do that myself.

      Does someone know a way to achieve this?

      Regards, Magnus

      1 Reply Last reply Reply Quote 0
      • Scott SumnerS Offline
        Scott Sumner
        last edited by

        Since it is extremely likely that you are a Python expert, you could write a Notepad++ Pythonscript to check for this conformity. :)

        Magnus HåkanssonM 1 Reply Last reply Reply Quote 0
        • Magnus HåkanssonM Offline
          Magnus Håkansson
          last edited by

          This post is deleted!
          1 Reply Last reply Reply Quote 0
          • Magnus HåkanssonM Offline
            Magnus Håkansson @Scott Sumner
            last edited by

            @Scott-Sumner

            Nope, I am not an expert…

            I would like to have all warnings displayed to me rather than look for them one by one.

            I would also prefer using someones work rather than doing it on my own :-)

            1 Reply Last reply Reply Quote 0
            • Scott SumnerS Offline
              Scott Sumner
              last edited by

              @Magnus-Håkansson said:

              I would also prefer using someones work rather than doing it on my own :-)

              Often desirable, not always achievable!

              1 Reply Last reply Reply Quote 2
              • dailD Offline
                dail
                last edited by

                There are PEP8 checkers available (for example). Nothing is currently built in but using something like the PythonScript plugin, NppExec, etc should be possible. With a bit more work you could even highlight the exact locations of each error, etc.

                1 Reply Last reply Reply Quote 1
                • Scott SumnerS Offline
                  Scott Sumner
                  last edited by

                  For the record, when I read something like the OP’s question, I presume that they have done their due diligence and have explored external options and have a good reason for wanting to do what they are asking about, inside Notepad++. Not always a good presumption, I guess, but this is a N++ forum, after all. :)

                  1 Reply Last reply Reply Quote 0

                  Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                  Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                  With your input, this post could be even better 💗

                  Register Login
                  • First post
                    Last post
                  The Community of users of the Notepad++ text editor.
                  Powered by NodeBB | Contributors