From jiongjiongai at outlook.com Sat Aug 11 01:46:56 2018 From: jiongjiongai at outlook.com (Jiongjiong Li) Date: Sat, 11 Aug 2018 05:46:56 +0000 Subject: [code-quality] pylint: How to ignore max line length limit for long import statements Message-ID: Is there any convenient way to ignore max line length limit for import statements, such as by setting rc file? pylint always report: C0301:Line too long (108/100). But according to Google Style Guide, it's fine to not limit line length for long import statements. Thanks! JIongjiong Li -------------- next part -------------- An HTML attachment was scrubbed... URL: From me at the-compiler.org Sat Aug 11 06:29:16 2018 From: me at the-compiler.org (Florian Bruhin) Date: Sat, 11 Aug 2018 12:29:16 +0200 Subject: [code-quality] pylint: How to ignore max line length limit for long import statements In-Reply-To: References: Message-ID: <20180811102916.42yvvazuqpkhxu7m@hooch.localdomain> Hey, On Sat, Aug 11, 2018 at 05:46:56AM +0000, Jiongjiong Li wrote: > Is there any convenient way to ignore max line length limit for import > statements, such as by setting rc file? > > pylint always report:?C0301:Line too long (108/100). > > But according to?[1]Google Style Guide, it's fine to not limit line length > for long import statements. There's a --ignore-long-lines (under [format] if in .pylintrc) option which allows you to define a regex for that. Something like ignore-long-lines=^import should probably help. Florian -- https://www.qutebrowser.org | me at the-compiler.org (Mail/XMPP) GPG: 916E B0C8 FD55 A072 | https://the-compiler.org/pubkey.asc I love long mails! | https://email.is-not-s.ms/ -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 833 bytes Desc: not available URL: From ccarrara at redhat.com Tue Aug 14 17:27:10 2018 From: ccarrara at redhat.com (Caio Carrara) Date: Tue, 14 Aug 2018 18:27:10 -0300 Subject: [code-quality] Possible bug with utils.is_subclass_of() Message-ID: <58711b05-700c-3295-a0d1-1f48e9488068@redhat.com> Hello everyone. I'm getting an error using pylint. Currently in my execution the function `checkers.utils.is_subclass_of()`[1] is raising a `NoneType object has no attribute name` exception. Debugging the issue I could check one of the arguments (nodes) used by this function is `None`. I think the expected behavior would be the function return False when one of the nodes is None. But the problem is in this `if` statement[2]. The check is done using `if not any()` but probably the correct way would be check it using `if not all()` to ensure all nodes is subclass of `astroid.ClassDef`. Could anyone double check it with me? If a patch is necessary I can tackle it. My environment details: pylint 2.1.1 astroid 2.0.3 Python 3.7.0 (default, Aug 8 2018, 09:38:40) [GCC 4.8.5 20150623 (Red Hat 4.8.5-28)] [1] - https://github.com/PyCQA/pylint/blob/master/pylint/checkers/utils.py#L1001 [2] - https://github.com/PyCQA/pylint/blob/master/pylint/checkers/utils.py#L1011 Thanks, -- Caio Carrara Software Engineer, Virtualization Team Red Hat ccarrara at redhat.com From ccarrara at redhat.com Thu Aug 16 12:28:39 2018 From: ccarrara at redhat.com (Caio Carrara) Date: Thu, 16 Aug 2018 13:28:39 -0300 Subject: [code-quality] Possible bug with checkers.utils.is_subclass_of() Message-ID: <59ca7104-8cce-91a5-0b1f-984afb28cd96@redhat.com> Hello everyone. I'm getting an error using pylint. Currently in my execution the function `checkers.utils.is_subclass_of()`[1] is raising a `NoneType object has no attribute name` exception. Debugging the issue I could check one of the arguments (nodes) used by this function is `None`. I think the expected behavior would be the function return False when one of the nodes is None. But the problem is in this `if` statement[2]. The check is done using `if not any()` but probably the correct way would be check it using `if not all()` to ensure all nodes is subclass of `astroid.ClassDef`. Could anyone double check it with me? If a patch is necessary I can tackle it. My environment details: pylint 2.1.1 astroid 2.0.3 Python 3.7.0 (default, Aug 8 2018, 09:38:40) [GCC 4.8.5 20150623 (Red Hat 4.8.5-28)] [1] - https://github.com/PyCQA/pylint/blob/master/pylint/checkers/utils.py#L1001 [2] - https://github.com/PyCQA/pylint/blob/master/pylint/checkers/utils.py#L1011 Thanks, -- Caio Carrara Software Engineer, Virt Team Red Hat ccarrara at redhat.com From pcmanticore at gmail.com Tue Aug 21 03:50:02 2018 From: pcmanticore at gmail.com (Claudiu Popa) Date: Tue, 21 Aug 2018 09:50:02 +0200 Subject: [code-quality] Possible bug with checkers.utils.is_subclass_of() In-Reply-To: <59ca7104-8cce-91a5-0b1f-984afb28cd96@redhat.com> References: <59ca7104-8cce-91a5-0b1f-984afb28cd96@redhat.com> Message-ID: Hi Caio, You are right, that should have been `if not all()` instead. If you can provide a patch for this bug, that would be amazing! Thank you, Claudiu On 16 August 2018 at 18:28, Caio Carrara wrote: > Hello everyone. > > I'm getting an error using pylint. > > Currently in my execution the function > `checkers.utils.is_subclass_of()`[1] is raising a `NoneType object has > no attribute name` exception. Debugging the issue I could check one of > the arguments (nodes) used by this function is `None`. > > I think the expected behavior would be the function return False when > one of the nodes is None. But the problem is in this `if` statement[2]. > The check is done using `if not any()` but probably the correct way > would be check it using `if not all()` to ensure all nodes is subclass > of `astroid.ClassDef`. > > Could anyone double check it with me? If a patch is necessary I can > tackle it. > > My environment details: > pylint 2.1.1 > astroid 2.0.3 > Python 3.7.0 (default, Aug 8 2018, 09:38:40) > [GCC 4.8.5 20150623 (Red Hat 4.8.5-28)] > > > [1] - > https://github.com/PyCQA/pylint/blob/master/pylint/checkers/utils.py#L1001 > [2] - > https://github.com/PyCQA/pylint/blob/master/pylint/checkers/utils.py#L1011 > > Thanks, > -- > Caio Carrara > Software Engineer, Virt Team > Red Hat > ccarrara at redhat.com > _______________________________________________ > code-quality mailing list > code-quality at python.org > https://mail.python.org/mailman/listinfo/code-quality From Miles.Hannah at SunTrust.com Tue Aug 21 13:59:27 2018 From: Miles.Hannah at SunTrust.com (Hannah.Miles) Date: Tue, 21 Aug 2018 17:59:27 +0000 Subject: [code-quality] Installing Pylint for Python 3.4 on Visual Studio Code | System: Windows 10 Message-ID: Hello, My name is Miles. I've been having a difficult time installing pylint for python 3.4 on visual studio code Windows 10 system. I went to Powershell and used the "pip install pylint" command and it keeps stating "Fatal error in launcher: unable to create process using '"" C:\Program Files\Python34\python.exe...'"" I'm also new to Windows OS. Do you all know a better way to go about installing pylint on my system? Thanks, Miles Hannah Systems Engineer Data Lake Architecture SunTrust Bank LEGAL DISCLAIMER The information transmitted is intended solely for the individual or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of or taking action in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you have received this email in error please contact the sender and delete the material from any computer. By replying to this e-mail, you consent to SunTrust's monitoring activities of all communication that occurs on SunTrust's systems. SunTrust is a federally registered service mark of SunTrust Banks, Inc. [ST:XCL] -------------- next part -------------- An HTML attachment was scrubbed... URL: From brett at python.org Wed Aug 22 12:55:22 2018 From: brett at python.org (Brett Cannon) Date: Wed, 22 Aug 2018 09:55:22 -0700 Subject: [code-quality] Installing Pylint for Python 3.4 on Visual Studio Code | System: Windows 10 In-Reply-To: References: Message-ID: It sounds like your Python install is such that you can't actually run Python. Make sure you can actually run C:\Program Files\Python34\python.exe . (IOW I don't think this has anything to do with Pylint or pip and so you might want to ask for help on the python-tutor mailing list.) On Wed, 22 Aug 2018 at 06:52 Hannah.Miles wrote: > Hello, > > > > My name is Miles. I?ve been having a difficult time installing pylint for > python 3.4 on visual studio code Windows 10 system. I went to Powershell > and used the ?pip install pylint? command and it keeps stating ?Fatal error > in launcher: unable to create process using > > ??? C:\Program Files\Python34\python.exe???? I?m also new to Windows OS. > Do you all know a better way to go about installing pylint on my system? > > > > Thanks, > > Miles Hannah > > Systems Engineer > > Data Lake Architecture > > SunTrust Bank > > > LEGAL DISCLAIMER > The information transmitted is intended solely for the individual or > entity to which it is addressed and may contain confidential and/or > privileged material. Any review, retransmission, dissemination or other use > of or taking action in reliance upon this information by persons or > entities other than the intended recipient is prohibited. If you have > received this email in error please contact the sender and delete the > material from any computer. > By replying to this e-mail, you consent to SunTrust's monitoring > activities of all communication that occurs on SunTrust's systems. > SunTrust is a federally registered service mark of SunTrust Banks, Inc. > [ST:XCL] > _______________________________________________ > code-quality mailing list > code-quality at python.org > https://mail.python.org/mailman/listinfo/code-quality > -------------- next part -------------- An HTML attachment was scrubbed... URL: