Skip to content

Commit

Permalink
Fix trailing whitespaces and trailing newlines
Browse files Browse the repository at this point in the history
  • Loading branch information
Pierre-Sassoulas committed May 3, 2020
1 parent 8403b89 commit 3fffdf0
Show file tree
Hide file tree
Showing 158 changed files with 167 additions and 190 deletions.
4 changes: 2 additions & 2 deletions .copyrite_aliases
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"afayolle.ml@free.fr",
"aurelien.campeas@logilab.fr",
"lmedioni@logilab.fr"

],
"authoritative_mail": "contact@logilab.fr",
"name": "LOGILAB S.A. (Paris, FRANCE)"
Expand All @@ -45,7 +45,7 @@
"balparda@google.com",
"dlindquist@google.com"
],
"name": "Google, Inc."
"name": "Google, Inc."
},
{
"mails": [
Expand Down
1 change: 0 additions & 1 deletion .github/ISSUE_TEMPLATE/1_Bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,3 @@ about: Report a bug in pylint


### pylint --version output

2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/2_Feature_request.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ A clear and concise description of what you want to happen.


### Additional context
Add any other context about the feature request here.
Add any other context about the feature request here.
4 changes: 2 additions & 2 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@ https://github.com/PyCQA/pylint/blob/master/doc/development_guide/contribute.rst

## Related Issue

<!--
<!--
If this PR fixes a particular issue, use the following to automatically close that issue
once this PR gets merged:
Closes #XXX
Closes #XXX
-->
10 changes: 5 additions & 5 deletions COPYING
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ patent must be licensed for everyone's free use or not licensed at all.

The precise terms and conditions for copying, distribution and
modification follow.

GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION

Expand Down Expand Up @@ -110,7 +110,7 @@ above, provided that you also meet all of these conditions:
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not required to print an announcement.)

These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
Expand Down Expand Up @@ -168,7 +168,7 @@ access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.

4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
Expand Down Expand Up @@ -225,7 +225,7 @@ impose that choice.

This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.

8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
Expand Down Expand Up @@ -278,7 +278,7 @@ PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.

END OF TERMS AND CONDITIONS

How to Apply These Terms to Your New Programs

If you develop a new program, and you want it to be of the greatest
Expand Down
1 change: 0 additions & 1 deletion debian/NEWS.Debian
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,3 @@ pylint (0.13.2-2) unstable; urgency=low
users may get it from /usr/share/doc/pylint/examples/pylint.el

-- Alexandre Fayolle <afayolle@debian.org> Wed, 04 Jul 2007 12:18:23 +0200

1 change: 0 additions & 1 deletion debian/changelog
Original file line number Diff line number Diff line change
Expand Up @@ -544,4 +544,3 @@ logilab-pylint (0.1.0-1) unstable; urgency=low
* Initial Release.

-- Sylvain Thénault <sylvain.thenault@logilab.fr> Wed, 23 Apr 2003 14:42:05 +0200

1 change: 0 additions & 1 deletion debian/copyright
Original file line number Diff line number Diff line change
Expand Up @@ -460,4 +460,3 @@ License: CC-BY-SA-4.0
licenses.
.
Creative Commons may be contacted at creativecommons.org.

2 changes: 1 addition & 1 deletion debian/pylint.emacsen-install
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ FLAGS="${SITEFLAG} -q -batch -l path.el -f batch-byte-compile"
ELDIR=/usr/share/emacs/site-lisp/${PACKAGE}
ELCDIR=/usr/share/${FLAVOR}/site-lisp/${PACKAGE}

# Install-info-altdir does not actually exist.
# Install-info-altdir does not actually exist.
# Maybe somebody will write it.
if test -x /usr/sbin/install-info-altdir; then
echo install/${PACKAGE}: install Info links for ${FLAVOR}
Expand Down
1 change: 0 additions & 1 deletion doc/backlinks.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,3 @@ Python code:
* SaltStack (https://github.com/saltstack)
* CodeFactor (https://github.com/codefactor-io)
* many more...

2 changes: 1 addition & 1 deletion doc/how_tos/transform_plugins.rst
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ Lets run Pylint with this plugin and see:
amitdev$

All the false positives associated with ``WarningMessage`` are now gone. This is just
an example, any code transformation can be done by plugins.
an example, any code transformation can be done by plugins.

See `astroid/brain`_ for real life examples of transform plugins.

Expand Down
2 changes: 1 addition & 1 deletion doc/tutorial.rst
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ in open source. Whatever the motivation, your good intentions may not have the
desired outcome if people find your code hard to use or understand. The Python
community has formalized some recommended programming styles to help everyone
write code in a common, agreed-upon style that makes the most sense for shared
code. This style is captured in `PEP 8`_, the "Style Guide for Python Code".
code. This style is captured in `PEP 8`_, the "Style Guide for Python Code".
Pylint can be a quick and easy way of
seeing if your code has captured the essence of `PEP 8`_ and is therefore
``friendly`` to other potential users.
Expand Down
2 changes: 1 addition & 1 deletion doc/user_guide/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ User Guide
output
message-control
options
ide-integration
ide-integration
6 changes: 3 additions & 3 deletions doc/whatsnew/1.6.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ New checkers
for key in dictionary.keys():
...
# Can be refactored to:
for key in dictionary:
...
Expand Down Expand Up @@ -80,7 +80,7 @@ New features


* We added a new option, ``redefining-builtins-modules``, which is used for
defining the modules which can redefine builtins.
defining the modules which can redefine builtins.
*pylint* will emit an error when a builtin is redefined, such as defining
a variable called ``next``. But in some cases, the builtins can be
redefined in the case they are imported from other places, different
Expand All @@ -102,7 +102,7 @@ Bug fixes
* Fixed a bug where the top name of a qualified import was detected as an unused variable.

* We don't warn about ``invalid-sequence-index`` if the indexed object has unknown
base classes, that Pylint cannot deduce.
base classes, that Pylint cannot deduce.



Expand Down
12 changes: 6 additions & 6 deletions doc/whatsnew/1.8.rst
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ New checkers
# Case1: a=0, b=2, args=(4,5)
foo(0,2,4,5) # 0 2 (4,5) ==> Observed values are same as expected values
# Case2: a=0, b=<default_value>, args=(4,5)
foo(0,4,5) # 0 4 (5,) ==> args list got modified as well as the observed value of b
Expand Down Expand Up @@ -253,7 +253,7 @@ New checkers
elif arg < 20:
return
According to PEP8_, if any return statement returns an expression,
According to PEP8_, if any return statement returns an expression,
any return statements where no value is returned should explicitly state this as return None,
and an explicit return statement should be present at the end of the function (if reachable).
Thus, the previous function should be written:
Expand Down Expand Up @@ -340,7 +340,7 @@ Other Changes

* ``missing-param-doc`` and ``missing-type-doc`` are no longer emitted when
``Args`` and ``Keyword Args`` are mixed in Google docstring.

* Fix of false positive ``useless-super-delegation`` message when
parameters default values are different from those used in the base class.

Expand All @@ -360,9 +360,9 @@ Other Changes

* Fix the ignored ``pylint disable=fixme`` directives for comments following
the last statement in a file.

* Fix ``line-too-long`` message deactivated by wrong disable directive.
The directive ``disable=fixme`` doesn't deactivate anymore the emission
The directive ``disable=fixme`` doesn't deactivate anymore the emission
of ``line-too-long`` message for long commented lines.

* If the rcfile specified on the command line doesn't exist, then an
Expand All @@ -371,4 +371,4 @@ Other Changes
* Fix the wrong scope of ``disable=`` directive after a commented line.
For example when a ``disable=line-too-long`` directive is at the end of a
long commented line, it no longer disables the emission of ``line-too-long``
message for lines that follow.
message for lines that follow.
2 changes: 1 addition & 1 deletion doc/whatsnew/2.4.rst
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ New checkers
Other Changes
=============

* Don't emit ``protected-access`` when a single underscore prefixed attribute is used
* Don't emit ``protected-access`` when a single underscore prefixed attribute is used
inside a special method

Close #1802
Expand Down
2 changes: 1 addition & 1 deletion elisp/pylint.el
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ output buffer, to go to the lines where pylint found matches.
(let ((map (cond
((boundp 'py-mode-map) py-mode-map)
((boundp 'python-mode-map) python-mode-map))))

(define-key map [menu-bar Python pylint-separator]
'("--" . pylint-separator))
(define-key map [menu-bar Python next-error]
Expand Down
2 changes: 0 additions & 2 deletions examples/pylintrc_camelcase
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,3 @@ argument-rgx=[a-z][a-zA-Z0-9]*$

# Regular expression which should only match correct variable names
variable-rgx=[a-z][a-zA-Z0-9]*$


38 changes: 19 additions & 19 deletions man/pyreverse.1
Original file line number Diff line number Diff line change
Expand Up @@ -4,32 +4,32 @@ pyreverse \- parse python sources files and extract diagrams from
them.

.SH SYNOPSIS
.B pyreverse
.B pyreverse
.I [options]
<modules>

.SH DESCRIPTION
.B pyreverse
is a python source analyzer. It parses python packages and produces UML
diagrams in different output formats. (dot, all formats available for dot,
diagrams in different output formats. (dot, all formats available for dot,
and vcg).
With different options, you can have fine tuning on what and how modules,
With different options, you can have fine tuning on what and how modules,
classes and attributes will be shown in the diagram.
You can combine several modules in one project (except with
You can combine several modules in one project (except with
.B \-c
).

If no \-c and no \-\-diadefs option specified,
.B pyreverse
will create
If no \-c and no \-\-diadefs option specified,
.B pyreverse
will create
\- a diagram 'classes_<name>' for the classes in <modules> and
( if there is more than one module in <projects> )
\- a diagram 'packages_<name>' for the package dependencies in <modules>
\- a diagram 'packages_<name>' for the package dependencies in <modules>

With \-c <class>,
.B pyreverse
.B pyreverse
creates a diagram for that <class> with filename <class>.<format>.
You can do \-c <class1> , \-c <class2>.
You can do \-c <class1> , \-c <class2>.

.SH OPTIONS

Expand All @@ -41,7 +41,7 @@ set project name to <name> if not using \-c option. (default:'No Name')
add files or directories to the blacklist. They should be base names, not
paths. [current: CVS]
.IP "-f<mode>, --filter-mode=<mode>"
filter attributes and functions according to <mode>. You can combine
filter attributes and functions according to <mode>. You can combine
modes using '+' like 'SPECIAL+OTHER'. Correct modes are :
- 'PUB_ONLY' : filter all non public attributes (default)
- 'ALL' : no filter
Expand All @@ -53,7 +53,7 @@ create diagram according to the diagram definitions in <file>
.IP "-c <class>, --class=<class>"
create a class diagram with all classes related to <class> [current: none]
the class must be in the file <modules>. By default, this will include all
ancestors and associated classes of <class> and include module names
ancestors and associated classes of <class> and include module names
(i.e. '\-ASmy' ).

.IP "-a <ancestor>, --show-ancestors=<ancestor>"
Expand All @@ -62,7 +62,7 @@ show <ancestor> generations of ancestor classes not in <projects>
show all ancestors off all classes in <projects> [current: none]
.IP "-s <ass_level>, --show-associated=<associated>"
show <ass_level> associated classes. <ass_level>=1 will only take classes
directly related to the classes in the project, while <ass_level>=2
directly related to the classes in the project, while <ass_level>=2
will also take all classes related to those fetched by<depth>=1.
.IP "-S, --all-associated=[yn]"
show recursively all associated off all associated classes [current: none]
Expand All @@ -74,12 +74,12 @@ include module name in representation of classes. This will include the
full module path in the class name. [current: none]

.IP "-k, --only-classnames"
don't show attributes and methods in the class boxes;
don't show attributes and methods in the class boxes;
this disables \-f values [current: False]

.IP "-o <format>, --output=<format>"
create a *.<format> output file if format available. Available formats
are all formats that dot can produce and
are all formats that dot can produce and
.B vcg.
[default: dot]

Expand All @@ -88,8 +88,8 @@ Here are some examples for command line options:

.IP "pyreverse <project> -a1 -s1 -m"

\-a1 \-s1 will include one level of ancestor and associated classes in the
diagram of the <project> modules, while \-m will show the full module
\-a1 \-s1 will include one level of ancestor and associated classes in the
diagram of the <project> modules, while \-m will show the full module
path of each class. You can use the
.B -a, -s, -A, -S
options in the same way.
Expand All @@ -99,8 +99,8 @@ Note that on class diagrams (using

.IP "pyreverse mod/foo.py mod/fee.py -k"

This is interesting if the diagram for <project>=mod is too complicated:
you can show only the class names (no attributes or methods, option \-k);
This is interesting if the diagram for <project>=mod is too complicated:
you can show only the class names (no attributes or methods, option \-k);
or take only the modules you are interested in (here fee.py and foo.py).

.SH REQUIRES
Expand Down
1 change: 0 additions & 1 deletion man/symilar.1
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,3 @@ Default is 4. So if it finds 3 identical lines, there will be no message, but
.IP "-i, --ignore-comments"
ignore differences concerning only stuff behind a '#' (Python comments). This
means that if just a comment was added, the message will still be triggered.

2 changes: 1 addition & 1 deletion pylint/utils/pragma_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
.*? # Anything (as little as possible)
\bpylint: # pylint word and column
\s* # Any number of whitespaces
([^;#\n]+)) # Anything except semicolon or hash or newline (it is the second matched group)
([^;#\n]+)) # Anything except semicolon or hash or newline (it is the second matched group)
# and end of the first matched group
[;#]{0,1}""" # From 0 to 1 repetition of semicolon or hash
OPTION_PO = re.compile(OPTION_RGX, re.VERBOSE)
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[bdist_rpm]
packager = Sylvain Thenault <sylvain.thenault@logilab.fr>
provides = pylint
provides = pylint

[aliases]
test = pytest
Expand Down
2 changes: 1 addition & 1 deletion tests/functional/a/abstract_class_instantiated_py3.rc
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[testoptions]
min_pyver=3.0
min_pyver=3.0
2 changes: 1 addition & 1 deletion tests/functional/a/abstract_class_instantiated_py34.rc
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[testoptions]
min_pyver=3.4
min_pyver=3.4
2 changes: 1 addition & 1 deletion tests/functional/a/abstract_method_py3.rc
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[testoptions]
min_pyver=3.0
min_pyver=3.0
2 changes: 1 addition & 1 deletion tests/functional/a/access_member_before_definition.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
access-member-before-definition:8:Aaaa.__init__:Access to member '_var2' before its definition line 9
access-member-before-definition:28:Bbbb.catchme:Access to member '_repo' before its definition line 30
access-member-before-definition:28:Bbbb.catchme:Access to member '_repo' before its definition line 30
2 changes: 1 addition & 1 deletion tests/functional/a/anomalous_unicode_escape_py3.rc
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[testoptions]
min_pyver=3.0
min_pyver=3.0
2 changes: 1 addition & 1 deletion tests/functional/a/anomalous_unicode_escape_py3.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
anomalous-unicode-escape-in-string:5::"Anomalous Unicode escape in byte string: '\u'. String constant might be missing an r or u prefix."
anomalous-unicode-escape-in-string:6::"Anomalous Unicode escape in byte string: '\U'. String constant might be missing an r or u prefix."
anomalous-unicode-escape-in-string:8::"Anomalous Unicode escape in byte string: '\N'. String constant might be missing an r or u prefix."
anomalous-unicode-escape-in-string:8::"Anomalous Unicode escape in byte string: '\N'. String constant might be missing an r or u prefix."
Loading

0 comments on commit 3fffdf0

Please sign in to comment.