Skip to content

Commit 9935d15

Browse files
committed
Style fixes.
1 parent 52a1c9b commit 9935d15

File tree

5 files changed

+9
-27
lines changed

5 files changed

+9
-27
lines changed

dulwich/annotate.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828

2929
import difflib
3030

31-
from dulwich.object_store import tree_lookup_path
3231
from dulwich.walk import (
3332
ORDER_DATE,
3433
Walker,
@@ -39,7 +38,8 @@
3938
# When checking each revision, find lines that according to difflib.Differ()
4039
# are common between versions.
4140
# Any lines that are not in common were introduced by the newer revision.
42-
# If there were no lines kept from the older version, stop going deeper in the graph.
41+
# If there were no lines kept from the older version, stop going deeper in the
42+
# graph.
4343

4444
def update_lines(annotated_lines, new_history_data, new_blob):
4545
"""Update annotation lines with old blob lines.
@@ -61,7 +61,8 @@ def update_lines(annotated_lines, new_history_data, new_blob):
6161
return ret
6262

6363

64-
def annotate_lines(store, commit_id, path, order=ORDER_DATE, lines=None, follow=True):
64+
def annotate_lines(store, commit_id, path, order=ORDER_DATE, lines=None,
65+
follow=True):
6566
"""Annotate the lines of a blob.
6667
6768
:param store: Object store to retrieve objects from
@@ -74,7 +75,7 @@ def annotate_lines(store, commit_id, path, order=ORDER_DATE, lines=None, follow=
7475
commit is the oldest commit that changed a line
7576
"""
7677
walker = Walker(store, include=[commit_id], paths=[path], order=order,
77-
follow=follow)
78+
follow=follow)
7879
revs = []
7980
for log_entry in walker:
8081
for tree_change in log_entry.changes():

dulwich/fastexport.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,8 @@
4646

4747

4848
def split_email(text):
49-
# TODO(jelmer): Dedupe this and the same functionality in format_annotate_line.
49+
# TODO(jelmer): Dedupe this and the same functionality in
50+
# format_annotate_line.
5051
(name, email) = text.rsplit(b" <", 1)
5152
return (name, email.rstrip(b">"))
5253

dulwich/porcelain.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1150,4 +1150,5 @@ def annotate(repo, path, committish=None):
11501150
commit_id = parse_commit(r, committish).id
11511151
return annotate_lines(r.object_store, commit_id, path)
11521152

1153+
11531154
blame = annotate

dulwich/tests/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,7 @@ def run_command(self, name, args):
9898

9999
def self_test_suite():
100100
names = [
101+
'annotate',
101102
'archive',
102103
'blackbox',
103104
'client',

dulwich/tests/test_annotate.py

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -17,25 +17,3 @@
1717
# MA 02110-1301, USA.
1818

1919
"""Tests for annotate support."""
20-
21-
import tarfile
22-
23-
from dulwich.archive import tar_stream
24-
from dulwich.object_store import (
25-
MemoryObjectStore,
26-
)
27-
from dulwich.objects import (
28-
Blob,
29-
Tree,
30-
)
31-
from dulwich.tests import (
32-
TestCase,
33-
)
34-
from dulwich.tests.utils import (
35-
build_commit_graph,
36-
)
37-
38-
39-
class AnnotateTests(TestCase):
40-
41-
def test_onerev(self):

0 commit comments

Comments
 (0)