Browse Source

Fix docstring syntax to be compatible with pydoctor.

Jelmer Vernooij 13 years ago
parent
commit
77c90fc333
2 changed files with 6 additions and 9 deletions
  1. 1 1
      dulwich/pack.py
  2. 5 8
      dulwich/tests/test_pack.py

+ 1 - 1
dulwich/pack.py

@@ -711,7 +711,7 @@ class PackStreamReader(object):
 
 
         :param compute_crc32: If True, compute the CRC32 of the compressed
         :param compute_crc32: If True, compute the CRC32 of the compressed
             data. If False, the returned CRC32 will be None.
             data. If False, the returned CRC32 will be None.
-        :yield: Tuples of (
+        :return: Iterator over tuples of (
             type number,
             type number,
             list of uncompressed chunks,
             list of uncompressed chunks,
             length of compressed data,
             length of compressed data,

+ 5 - 8
dulwich/tests/test_pack.py

@@ -621,18 +621,15 @@ class DeltaChainIteratorTests(TestCase):
     def write_pack_data(self, objects_spec):
     def write_pack_data(self, objects_spec):
         """Write test pack data from a concise spec.
         """Write test pack data from a concise spec.
 
 
-        :param objects_spec: A list of (type_num, obj). For non-delta types, obj
-            is the string of that object's data.
-
+        :param objects_spec: A list of (type_num, obj). For non-delta types,
+            obj is the string of that object's data.
             For delta types, obj is a tuple of (base_index, data), where
             For delta types, obj is a tuple of (base_index, data), where
             base_index is the index in objects_spec of the base for that delta,
             base_index is the index in objects_spec of the base for that delta,
             and data is the full, non-deltified data for that object.
             and data is the full, non-deltified data for that object.
             (Offsets/refs and deltas are computed within this function.)
             (Offsets/refs and deltas are computed within this function.)
-
-        :return: A tuple of (f, entries), where f is a file-like object pointed
-            at the beginning of a pack with the requested data, and entries is a
-            list of tuples of:
-              (offset, type num, data, sha, CRC32)
+        :return: A tuple of (f, entries), where f is a file-like object
+            pointed at the beginning of a pack with the requested data, and
+            entries is a list of tuples of (offset, type num, data, sha, CRC32)
             These tuples match the result format from TestPackIterator, and are
             These tuples match the result format from TestPackIterator, and are
             returned in the order specified by objects_spec.
             returned in the order specified by objects_spec.
         """
         """