Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 25bee51

Browse filesBrowse files
author
Andrea Bedini
committed
Fix wrong syntax for assert
The assert statement doesn't take parentheses, see http://docs.python.org/3.2/reference/simple_stmts.html#assert http://docs.python.org/2/reference/simple_stmts.html#grammar-token-assert_stmt I found this because python gave me the following ```SyntaxWarning: assertion is always true, perhaps remove parentheses?```
1 parent 8bba2a4 commit 25bee51
Copy full SHA for 25bee51

File tree

1 file changed

+2
-2
lines changed
Filter options

1 file changed

+2
-2
lines changed

‎lib/matplotlib/docstring.py

Copy file name to clipboardExpand all lines: lib/matplotlib/docstring.py
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ def some_function(x):
3333
"%s %s wrote the Raven"
3434
"""
3535
def __init__(self, *args, **kwargs):
36-
assert (not (args and kwargs),
37-
"Only positional or keyword args are allowed")
36+
assert not (args and kwargs), \
37+
"Only positional or keyword args are allowed"
3838
self.params = args or kwargs
3939

4040
def __call__(self, func):

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.