@@ -219,14 +219,6 @@ def _parse_string(value):
return bytes(ret)
-def _unescape_value(value):
- """Unescape a value."""
- ret = bytearray()
- i = 0
-
- return ret
def _escape_value(value):
"""Escape a value."""
return value.replace(b"\\", b"\\\\").replace(b"\n", b"\\n").replace(b"\t", b"\\t").replace(b"\"", b"\\\"")
@@ -30,7 +30,6 @@ This implementation is experimental and does not have any tests.
import paramiko
import paramiko.client
-import subprocess
import threading
class _ParamikoWrapper(object):
@@ -473,7 +473,6 @@ def _all_wants_satisfied(store, haves, wants):
earliest = min([store[h].commit_time for h in haves])
else:
earliest = 0
- unsatisfied_wants = set()
for want in wants:
if not _want_satisfied(store, haves, want, earliest):
return False
@@ -134,7 +134,6 @@ class TestPack(PackTests):
# two copy operations in git's binary delta format.
raise SkipTest('skipping slow, large test')
with self.get_pack(pack1_sha) as orig_pack:
- orig_blob = orig_pack[a_sha]
new_blob = Blob()
new_blob.data = 'big blob' + ('x' * 2 ** 25)
new_blob_2 = Blob()
@@ -28,7 +28,6 @@ from dulwich.config import (
_format_string,
_escape_value,
_parse_string,
- _unescape_value,
parse_submodules,
)
from dulwich.tests import (
@@ -20,7 +20,6 @@
import os
import stat
import shutil
-import sys
import tempfile
from dulwich import errors
@@ -523,11 +523,10 @@ class PushTests(PorcelainTestCase):
porcelain.push(clone_path, self.repo.path, b":" + refs_path, outstream=outstream,
errstream=errstream)
- with closing(Repo(clone_path)) as r_clone:
- self.assertEqual({
- b'HEAD': new_id,
- b'refs/heads/master': new_id,
- }, self.repo.get_refs())
+ self.assertEqual({
+ b'HEAD': new_id,
+ b'refs/heads/master': new_id,
+ }, self.repo.get_refs())
@@ -23,7 +23,6 @@
import datetime
import time
import types