Merge lp://qastaging/~jelmer/wikkid/dulwich into lp://qastaging/wikkid

Proposed by Jelmer Vernooij
Status: Merged
Merged at revision: 74
Proposed branch: lp://qastaging/~jelmer/wikkid/dulwich
Merge into: lp://qastaging/wikkid
Diff against target: 522 lines (+362/-16)
12 files modified
bin/wikkid-serve (+18/-8)
setup.py (+1/-0)
wikkid/dispatcher.py (+1/-1)
wikkid/filestore/basefile.py (+1/-2)
wikkid/filestore/bzr.py (+2/-1)
wikkid/filestore/git.py (+205/-0)
wikkid/filestore/volatile.py (+2/-1)
wikkid/interface/filestore.py (+0/-3)
wikkid/tests/__init__.py (+1/-0)
wikkid/tests/filestore.py (+2/-0)
wikkid/tests/test_git_filestore.py (+55/-0)
wikkid/user/git.py (+74/-0)
To merge this branch: bzr merge lp://qastaging/~jelmer/wikkid/dulwich
Reviewer Review Type Date Requested Status
Tim Penhey Approve
Gavin Panella Approve
Review via email: mp+183373@code.qastaging.launchpad.net

Description of the change

Add a dulwich-based filestore backend to wikkid, which can be used for git repositories.

To post a comment you must log in.
76. By Jelmer Vernooij

Simplify commit, add --format=git option.

77. By Jelmer Vernooij

Fix user id.

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

ping, anyone?

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

ping (-:

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

ping :-)

Revision history for this message
Gavin Panella (allenap) wrote :

I'm not sure that I'm really qualified to review this, but cosmic
radiation seems to have flipped a bit in Launchpad's database such that
I have been invited to pass judgement.

[1]

+            try:
+                (mode, sha) = tree[el]
+                if not stat.S_ISDIR(mode):
+                    raise FileExists(
+                        "File %s exists and is not a directory" % el)
+            except KeyError:
+                tree = Tree()
+            else:
+                tree = self.store[sha]

I'm guessing that you're not trying to guard against a KeyError in the
`if not stat.S_ISDIR(...` block, so it probably ought to go in the else:
block.

[2]

+                ret.append(
+                    File(self.store, mode, sha, posixpath.join(directory_path, name), commit_id))

In places you use "/" as the separator. Consider using posixpath.sep
for, I don't know, cleanliness?

[3]

Can you add dulwich as a dependency in setup.py?

[4]

There are a lot of new things here without obvious tests, like the
middleware, but given that there's little other development activity I
hardly want to block for that. In other words, you're very naughty for
not testing things, but there's no punishment, and thanks for the
contribution :)

review: Approve
Revision history for this message
Jelmer Vernooij (jelmer) wrote :

Thanks for the review, Gavin. Much appreciated! :-)

I'll follow up with some fixes when I get back from vacation.

78. By Jelmer Vernooij

Merge trunk.

79. By Jelmer Vernooij

Add dulwich dependency.

80. By Jelmer Vernooij

Use posixpath.sep rather than /

81. By Jelmer Vernooij

Move extra code out of try/except.

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

Thanks, I've now fixed the issues you pointed out.

Revision history for this message
Tim Penhey (thumper) wrote :

On 16/01/14 13:06, Jelmer Vernooij wrote:
> Thanks, I've now fixed the issues you pointed out.

Now I have to remember what this is all about and how to run the tests :-)

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

On Thu, Jan 16, 2014 at 12:18:16AM -0000, Tim Penhey wrote:
> On 16/01/14 13:06, Jelmer Vernooij wrote:
> > Thanks, I've now fixed the issues you pointed out.
>
> Now I have to remember what this is all about and how to run the tests :-)

FWIW I get two failing tests, but those happen under trunk as well. :-)

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

ping? :)

Revision history for this message
Tim Penhey (thumper) wrote :

Guys, I've been pretty crap at following up, but both Jelmer and Gavin have commit rights to trunk :-)

Trunk is owned by ~wikkid. Jelmer, you are good to merge.

review: Approve
Revision history for this message
Jelmer Vernooij (jelmer) wrote :

Thanks, Tim! Merged.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches