Rev 1956: Merge 0.4. in file:///data/jelmer/bzr-svn/trunk/
Jelmer Vernooij
jelmer at samba.org
Mon Nov 3 03:55:04 GMT 2008
At file:///data/jelmer/bzr-svn/trunk/
------------------------------------------------------------
revno: 1956
revision-id: jelmer at samba.org-20081103035500-ekmm1fam44l875aq
parent: jelmer at samba.org-20081017003342-w4vs80x50zbfsptj
parent: jelmer at samba.org-20081103034353-5ez9e3g8dzullsj9
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: trunk
timestamp: Mon 2008-11-03 04:55:00 +0100
message:
Merge 0.4.
modified:
NEWS news-20061231030336-h9fhq245ie0de8bs-1
commit.py commit.py-20060607190346-qvq128wgfubhhgm2-1
fetch.py fetch.py-20060625004942-x2lfaib8ra707a8p-1
mapping3/__init__.py __init__.py-20080502174630-9324zh25kka98vlw-1
remote.py format.py-20060406233823-b6fa009fe35dfde7
subvertpy/subvertpy/delta.py delta.py-20080316001917-xyng7m3jlxvdc4c9-1
subvertpy/subvertpy/editor.c editor.c-20080602191336-frj7az1sdk13o1tw-1
subvertpy/subvertpy/editor.h editor.h-20080602191336-frj7az1sdk13o1tw-2
subvertpy/subvertpy/ra.c ra.pyx-20080313140933-qybkqaxe3m4mcll7-1
subvertpy/subvertpy/wc.c wc.pyx-20080313142018-10l8l23vha2j9e6b-1
tests/test_commit.py test_commit.py-20060624213521-l5kcufywkh9mnilk-1
tests/test_mapping.py test_mapping.py-20080201131338-0zd86eznn4bojtee-1
tests/test_push.py test_push.py-20070201165715-g2ievcdfqi33wqsy-1
tree.py tree.py-20060624222557-dudlwqcmkf22lt2s-1
------------------------------------------------------------
revno: 1669.1.66
revision-id: jelmer at samba.org-20081103034353-5ez9e3g8dzullsj9
parent: jelmer at samba.org-20081103031851-rl7k1fq4zt7tl4p6
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: 0.4
timestamp: Mon 2008-11-03 04:43:53 +0100
message:
Fix more tests.
modified:
tests/test_commit.py test_commit.py-20060624213521-l5kcufywkh9mnilk-1
------------------------------------------------------------
revno: 1669.1.65
revision-id: jelmer at samba.org-20081103031851-rl7k1fq4zt7tl4p6
parent: jelmer at samba.org-20081103023151-uq0avcijru3yv1ys
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: 0.4
timestamp: Mon 2008-11-03 04:18:51 +0100
message:
Fix tests.
modified:
logwalker.py logwalker.py-20060621215743-c13fhfnyzh1xzwh2-1
tree.py tree.py-20060624222557-dudlwqcmkf22lt2s-1
------------------------------------------------------------
revno: 1669.1.64
revision-id: jelmer at samba.org-20081103023151-uq0avcijru3yv1ys
parent: jelmer at samba.org-20081103021504-g48y6yynberqulby
parent: john at arbash-meinel.com-20081030191211-3jxp7vj5lx1makmz
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: 0.4
timestamp: Mon 2008-11-03 03:31:51 +0100
message:
merge John's win32 fixes, fix segfault.
modified:
editor.c editor.c-20080602191336-frj7az1sdk13o1tw-1
editor.h editor.h-20080602191336-frj7az1sdk13o1tw-2
ra.c ra.pyx-20080313140933-qybkqaxe3m4mcll7-1
wc.c wc.pyx-20080313142018-10l8l23vha2j9e6b-1
------------------------------------------------------------
revno: 1669.7.1
revision-id: john at arbash-meinel.com-20081030191211-3jxp7vj5lx1makmz
parent: jelmer at samba.org-20080924160103-8eaf0uaujrsnz7he
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: 0.4.13-win32
timestamp: Thu 2008-10-30 14:12:11 -0500
message:
We can't point directly at dll imported functions.
So instead, create an 'initeditor()' function which initializes those
members, and then call it when the module is loaded.
modified:
client.c client.pyx-20080313235339-wbyjbw2namuiql8f-1
editor.c editor.c-20080602191336-frj7az1sdk13o1tw-1
------------------------------------------------------------
revno: 1669.1.63
revision-id: jelmer at samba.org-20081103021504-g48y6yynberqulby
parent: jelmer at samba.org-20081103021228-0pkqcw3cikpuc6zv
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: 0.4
timestamp: Mon 2008-11-03 03:15:04 +0100
message:
Update NEWS.
modified:
NEWS news-20061231030336-h9fhq245ie0de8bs-1
------------------------------------------------------------
revno: 1669.1.62
revision-id: jelmer at samba.org-20081103021228-0pkqcw3cikpuc6zv
parent: jelmer at samba.org-20081010180416-pjcrar4dr033waod
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: 0.4
timestamp: Mon 2008-11-03 03:12:28 +0100
message:
Fix python2.6 deprecation warnings.
modified:
commit.py commit.py-20060607190346-qvq128wgfubhhgm2-1
delta.py delta.py-20080316001917-xyng7m3jlxvdc4c9-1
fetch.py fetch.py-20060625004942-x2lfaib8ra707a8p-1
mapping3/__init__.py __init__.py-20080502174630-9324zh25kka98vlw-1
tests/test_mapping.py test_mapping.py-20080201131338-0zd86eznn4bojtee-1
tree.py tree.py-20060624222557-dudlwqcmkf22lt2s-1
------------------------------------------------------------
revno: 1669.1.61
revision-id: jelmer at samba.org-20081010180416-pjcrar4dr033waod
parent: jelmer at samba.org-20081010180222-jfu5n8vccpq2fvk6
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: 0.4
timestamp: Fri 2008-10-10 20:04:16 +0200
message:
Don't assume root path can't change; Microsoft's CodePlex site does this.
modified:
NEWS news-20061231030336-h9fhq245ie0de8bs-1
logwalker.py logwalker.py-20060621215743-c13fhfnyzh1xzwh2-1
------------------------------------------------------------
revno: 1669.1.60
revision-id: jelmer at samba.org-20081010180222-jfu5n8vccpq2fvk6
parent: jelmer at samba.org-20081010172549-ioc4mogloxqorcc3
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: 0.4
timestamp: Fri 2008-10-10 20:02:22 +0200
message:
Fix format name.
modified:
remote.py format.py-20060406233823-b6fa009fe35dfde7
------------------------------------------------------------
revno: 1669.1.59
revision-id: jelmer at samba.org-20081010172549-ioc4mogloxqorcc3
parent: jelmer at samba.org-20081010170900-y453te3a4knu3b8l
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: 0.4
timestamp: Fri 2008-10-10 19:25:49 +0200
message:
Add bug #
modified:
NEWS news-20061231030336-h9fhq245ie0de8bs-1
------------------------------------------------------------
revno: 1669.1.58
revision-id: jelmer at samba.org-20081010170900-y453te3a4knu3b8l
parent: jelmer at samba.org-20081010163928-t9v4qigvj93u2o7d
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: 0.4
timestamp: Fri 2008-10-10 19:09:00 +0200
message:
Cope with pushing files changed into directories.
modified:
NEWS news-20061231030336-h9fhq245ie0de8bs-1
commit.py commit.py-20060607190346-qvq128wgfubhhgm2-1
tests/test_push.py test_push.py-20070201165715-g2ievcdfqi33wqsy-1
------------------------------------------------------------
revno: 1669.1.57
revision-id: jelmer at samba.org-20081010163928-t9v4qigvj93u2o7d
parent: jelmer at samba.org-20081010021427-a6gd3hsticsrgpms
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: 0.4
timestamp: Fri 2008-10-10 18:39:28 +0200
message:
Convert svn errors while stacking.
modified:
versionedfiles.py versionedfiles.py-20080626134117-j8g0ntz1pj228iox-1
------------------------------------------------------------
revno: 1669.1.56
revision-id: jelmer at samba.org-20081010021427-a6gd3hsticsrgpms
parent: jelmer at samba.org-20081010020827-pwhtotcdk6gorl1s
committer: Jelmer Vernooij <jelmer at samba.org>
branch nick: 0.4
timestamp: Fri 2008-10-10 04:14:27 +0200
message:
Mention 1.9 compatibility.
modified:
NEWS news-20061231030336-h9fhq245ie0de8bs-1
=== modified file 'NEWS'
--- a/NEWS 2008-10-06 15:08:38 +0000
+++ b/NEWS 2008-11-03 03:55:00 +0000
@@ -60,6 +60,17 @@
+ Standard commit code provides commit notification. (#79333)
+ BUG FIXES
+
+ * Fix compatibility with Bazaar 1.9. (#279444)
+
+ * Cope with pushing files changed into directories. (#277369)
+
+ * Don't assume root path can't change; Microsoft's CodePlex site
+ does this. (#278930)
+
+ * Fix python2.6 deprecation warnings. (#292306)
+
bzr-svn 0.4.13 2008-09-24
BUG FIXES
=== modified file 'commit.py'
--- a/commit.py 2008-10-15 20:09:44 +0000
+++ b/commit.py 2008-11-03 03:55:00 +0000
@@ -163,7 +163,8 @@
# Loop over entries of file_id in old_inv
# remove if they no longer exist with the same name
# or parents
- if file_id in old_inv:
+ if (file_id in old_inv and
+ self.old_inv[file_id].kind == 'directory'):
for child_name in old_inv[file_id].children:
child_ie = old_inv.get_child(file_id, child_name)
# remove if...
=== modified file 'fetch.py'
--- a/fetch.py 2008-10-02 21:18:28 +0000
+++ b/fetch.py 2008-11-03 03:55:00 +0000
@@ -23,7 +23,7 @@
from bzrlib.trace import mutter
from cStringIO import StringIO
-import md5
+from bzrlib.osutils import md5
from subvertpy import properties
from subvertpy.delta import apply_txdelta_handler
@@ -61,7 +61,7 @@
:param strings: Strings to find the MD5sum of.
:return: MD5sum
"""
- s = md5.new()
+ s = md5()
map(s.update, strings)
return s.hexdigest()
@@ -326,7 +326,7 @@
self.file_stream = None
def _apply_textdelta(self, base_checksum=None):
- actual_checksum = md5.new(self.file_data).hexdigest()
+ actual_checksum = md5(self.file_data).hexdigest()
assert (base_checksum is None or base_checksum == actual_checksum,
"base checksum mismatch: %r != %r" % (base_checksum,
actual_checksum))
=== modified file 'mapping3/__init__.py'
--- a/mapping3/__init__.py 2008-10-02 21:18:28 +0000
+++ b/mapping3/__init__.py 2008-11-03 03:55:00 +0000
@@ -28,7 +28,7 @@
TrunkBranchingScheme, ListBranchingScheme,
InvalidSvnBranchPath)
from subvertpy.ra import DIRENT_KIND
-import sha
+from bzrlib.osutils import sha
SVN_PROP_BZR_BRANCHING_SCHEME = 'bzr:branching-scheme'
@@ -217,7 +217,7 @@
if len(ret) > 150:
ret = "%d@%s:%s;%s" % (revnum, uuid,
mapping.escape_svn_path(branch),
- sha.new(inv_path).hexdigest())
+ sha(inv_path).hexdigest())
assert isinstance(ret, str)
return osutils.safe_file_id(ret)
=== modified file 'remote.py'
--- a/remote.py 2008-10-02 21:18:28 +0000
+++ b/remote.py 2008-11-03 03:55:00 +0000
@@ -90,7 +90,7 @@
def cloning_metadir(self, stacked=False):
"""Produce a metadir suitable for cloning with."""
if stacked:
- return bzrlib.bzrdir.format_registry.make_bzrdir("1.6-rich-root")
+ return bzrlib.bzrdir.format_registry.make_bzrdir("1.6.1-rich-root")
else:
return bzrlib.bzrdir.format_registry.make_bzrdir("rich-root-pack")
=== modified file 'subvertpy/subvertpy/delta.py'
--- a/subvertpy/subvertpy/delta.py 2008-10-15 20:09:44 +0000
+++ b/subvertpy/subvertpy/delta.py 2008-11-03 03:55:00 +0000
@@ -15,7 +15,7 @@
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
"""Subversion delta operations."""
-import md5
+from bzrlib.osutils import md5
TXDELTA_SOURCE = 0
TXDELTA_TARGET = 1
@@ -55,7 +55,7 @@
def send_stream(stream, handler, block_size=SEND_STREAM_BLOCK_SIZE):
- hash = md5.new()
+ hash = md5()
text = stream.read(block_size)
while text != "":
hash.update(text)
=== modified file 'subvertpy/subvertpy/editor.c'
--- a/subvertpy/subvertpy/editor.c 2008-10-02 20:22:45 +0000
+++ b/subvertpy/subvertpy/editor.c 2008-11-03 03:55:00 +0000
@@ -137,7 +137,7 @@
/* Methods to implement standard operations */
- (destructor)PyObject_Del, /* destructor tp_dealloc; */
+ NULL, // done in initeditor() (destructor)PyObject_Del, /* destructor tp_dealloc; */
NULL, /* printfunc tp_print; */
NULL, /* getattrfunc tp_getattr; */
NULL, /* setattrfunc tp_setattr; */
@@ -235,7 +235,7 @@
/* Methods to implement standard operations */
- (destructor)PyObject_Del, /* destructor tp_dealloc; */
+ NULL, // Done in initeditor() (destructor)PyObject_Del, /* destructor tp_dealloc; */
NULL, /* printfunc tp_print; */
NULL, /* getattrfunc tp_getattr; */
NULL, /* setattrfunc tp_setattr; */
@@ -492,7 +492,7 @@
/* Methods to implement standard operations */
- (destructor)PyObject_Del, /* destructor tp_dealloc; */
+ NULL, // Done in initeditor() (destructor)PyObject_Del, /* destructor tp_dealloc; */
NULL, /* printfunc tp_print; */
NULL, /* getattrfunc tp_getattr; */
NULL, /* setattrfunc tp_setattr; */
@@ -688,3 +688,9 @@
};
+void initeditor(void)
+{
+ TxDeltaWindowHandler_Type.tp_dealloc = (destructor)PyObject_Del;
+ FileEditor_Type.tp_dealloc = (destructor)PyObject_Del;
+ DirectoryEditor_Type.tp_dealloc = (destructor)PyObject_Del;
+}
=== modified file 'subvertpy/subvertpy/editor.h'
--- a/subvertpy/subvertpy/editor.h 2008-10-02 20:22:45 +0000
+++ b/subvertpy/subvertpy/editor.h 2008-11-03 03:55:00 +0000
@@ -41,4 +41,6 @@
#pragma GCC visibility pop
+extern void initeditor(void);
+
#endif /* _BZR_SVN_EDITOR_H_ */
=== modified file 'subvertpy/subvertpy/ra.c'
--- a/subvertpy/subvertpy/ra.c 2008-10-09 21:05:39 +0000
+++ b/subvertpy/subvertpy/ra.c 2008-11-03 03:55:00 +0000
@@ -2854,6 +2854,8 @@
if (PyType_Ready(&AuthProvider_Type) < 0)
return;
+ initeditor();
+
apr_initialize();
pool = Pool(NULL);
if (pool == NULL)
=== modified file 'subvertpy/subvertpy/wc.c'
--- a/subvertpy/subvertpy/wc.c 2008-10-02 20:22:45 +0000
+++ b/subvertpy/subvertpy/wc.c 2008-11-03 03:55:00 +0000
@@ -954,6 +954,8 @@
if (PyType_Ready(&TxDeltaWindowHandler_Type) < 0)
return;
+ initeditor();
+
apr_initialize();
mod = Py_InitModule3("wc", wc_methods, "Working Copies");
=== modified file 'tests/test_commit.py'
--- a/tests/test_commit.py 2008-10-02 21:18:28 +0000
+++ b/tests/test_commit.py 2008-11-03 03:55:00 +0000
@@ -510,6 +510,7 @@
wt = local_dir.open_workingtree()
local_dir.open_branch().bind(master_branch)
self.build_tree({'b/file': 'data'})
+ wt.branch.nick = "somenick"
wt.add('file')
revid = wt.commit(message="Commit from Bzr")
master_branch = Branch.open(repos_url)
@@ -523,6 +524,7 @@
wt = local_dir.open_workingtree()
local_dir.open_branch().bind(master_branch)
self.build_tree({'b/file': 'data'})
+ wt.branch.nick = "some-nick"
wt.add('file')
oldid = wt.path2id("file")
revid1 = wt.commit(message="Commit from Bzr")
@@ -550,6 +552,7 @@
local_dir = master_branch.bzrdir.sprout("b")
wt = local_dir.open_workingtree()
local_dir.open_branch().bind(master_branch)
+ wt.branch.nick = "some-nick"
self.build_tree({'b/dir/file': 'data'})
wt.add('dir')
wt.add('dir/file')
=== modified file 'tests/test_mapping.py'
--- a/tests/test_mapping.py 2008-09-09 18:53:33 +0000
+++ b/tests/test_mapping.py 2008-11-03 03:55:00 +0000
@@ -15,7 +15,7 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-import sha
+from bzrlib.osutils import sha
from bzrlib.errors import InvalidRevisionId, NotBranchError
from bzrlib.tests import TestCase, TestNotApplicable
@@ -144,7 +144,7 @@
def sha1(text):
- return sha.new(text).hexdigest()
+ return sha(text).hexdigest()
class ParseRevisionIdTests(object):
=== modified file 'tests/test_push.py'
--- a/tests/test_push.py 2008-10-02 21:18:28 +0000
+++ b/tests/test_push.py 2008-11-03 03:55:00 +0000
@@ -699,6 +699,20 @@
self.assertEquals(u"Do á commït",
Repository.open(repos_url).get_revision(revid1).message)
+ def test_kind_change_file_to_directory(self):
+ repos_url = self.make_repository("a")
+ bzrwt = BzrDir.create_standalone_workingtree("c",
+ format=format.get_rich_root_format())
+ self.build_tree({'c/foo.txt': "foo"})
+ bzrwt.add("foo.txt")
+ revid1 = bzrwt.commit(u"somecommit")
+ os.remove("c/foo.txt")
+ self.build_tree({"c/foo.txt/bar": "contents"})
+ bzrwt.add("foo.txt")
+ revid2 = bzrwt.commit(u"somecommit")
+ newdir = BzrDir.open(repos_url+"/trunk")
+ newdir.import_branch(bzrwt.branch)
+
def test_multiple_part_exists(self):
repos_url = self.make_repository("a")
=== modified file 'tree.py'
--- a/tree.py 2008-10-02 21:18:28 +0000
+++ b/tree.py 2008-11-03 03:55:00 +0000
@@ -23,7 +23,7 @@
from bzrlib.revisiontree import RevisionTree
import os
-import md5
+from bzrlib.osutils import md5
from cStringIO import StringIO
import urllib
@@ -86,7 +86,7 @@
finally:
repository.transport.add_connection(conn)
- def get_file_text(self, file_id):
+ def get_file_text(self, file_id, path=None):
return self.file_data[file_id]
@@ -194,7 +194,7 @@
ie = self.tree._inventory.add_path(self.path, 'file', file_id)
ie.revision = revision_id
- actual_checksum = md5.new(file_data).hexdigest()
+ actual_checksum = md5(file_data).hexdigest()
assert(checksum is None or checksum == actual_checksum,
"checksum mismatch: %r != %r" % (checksum, actual_checksum))
@@ -309,8 +309,10 @@
def get_file_byname(self, name):
return open(self.abspath(name))
- def get_file_text(self, file_id):
- return self.get_file_byname(self.id2path(file_id)).read()
+ def get_file_text(self, file_id, path=None):
+ if path is None:
+ path = self.id2path(file_id)
+ return self.get_file_byname(path).read()
def annotate_iter(self, file_id,
default_revision=CURRENT_REVISION):
More information about the bazaar-commits
mailing list