Skip to content
This repository was archived by the owner on Aug 30, 2024. It is now read-only.

Commit 7ac2a41

Browse files
authored
Merge pull request #346 from cloudant/343-pylint-1.8.1
343 fix pylint 1.8.1
2 parents 1fdf9e8 + 89d9053 commit 7ac2a41

File tree

5 files changed

+9
-10
lines changed

5 files changed

+9
-10
lines changed

pylintrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ confidence=
6666
# Disable "redefined-variable-type" refactor warning messages
6767
# Disable "too-many-..." and "too-few-..." refactor warning messages
6868
# Disable "locally-disabled" message
69-
disable=R0204,R0901,R0902,R0903,R0904,R0913,R0914,R0915,locally-disabled
69+
disable=R0204,R0901,R0902,R0903,R0904,R0913,R0914,R0915,locally-disabled,keyword-arg-before-vararg
7070

7171

7272
[REPORTS]

src/cloudant/database.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env python
2-
# Copyright (c) 2015 IBM. All rights reserved.
2+
# Copyright (C) 2015, 2018 IBM Corp. All rights reserved.
33
#
44
# Licensed under the Apache License, Version 2.0 (the "License");
55
# you may not use this file except in compliance with the License.
@@ -660,7 +660,7 @@ def __iter__(self, remote=True):
660660
super(CouchDatabase, self).__setitem__(doc['id'], document)
661661
yield document
662662

663-
raise StopIteration
663+
return
664664

665665
def bulk_docs(self, docs):
666666
"""

src/cloudant/document.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env python
2-
# Copyright (c) 2015 IBM. All rights reserved.
2+
# Copyright (C) 2015, 2018 IBM Corp. All rights reserved.
33
#
44
# Licensed under the Apache License, Version 2.0 (the "License");
55
# you may not use this file except in compliance with the License.
@@ -257,7 +257,7 @@ def _update_field(self, action, field, value, max_tries, tries=0):
257257
self.save()
258258
except requests.HTTPError as ex:
259259
if tries < max_tries and ex.response.status_code == 409:
260-
return self._update_field(
260+
self._update_field(
261261
action, field, value, max_tries, tries=tries+1)
262262
raise
263263

src/cloudant/replicator.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env python
2-
# Copyright (c) 2015 IBM. All rights reserved.
2+
# Copyright (C) 2015, 2018 IBM Corp. All rights reserved.
33
#
44
# Licensed under the Apache License, Version 2.0 (the "License");
55
# you may not use this file except in compliance with the License.
@@ -158,7 +158,7 @@ def update_state():
158158
if repl_doc:
159159
yield repl_doc
160160
if state is not None and state in ['error', 'completed']:
161-
raise StopIteration
161+
return
162162

163163
# Now listen on changes feed for the state
164164
for change in self.database.changes():
@@ -167,7 +167,7 @@ def update_state():
167167
if repl_doc is not None:
168168
yield repl_doc
169169
if state is not None and state in ['error', 'completed']:
170-
raise StopIteration
170+
return
171171

172172
def stop_replication(self, repl_id):
173173
"""

test-requirements.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
mock==1.3.0
22
nose
33
sphinx
4-
pylint==1.7.4
5-
astroid==1.5.3
4+
pylint
65
flaky

0 commit comments

Comments
 (0)