Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(75)

Issue 40050: Make upload.py send svn cp'd and svn mv'd files correctly.

Can't Edit
Can't Publish+Mail
Start Review
Created:
16 years, 9 months ago by Collin Winter
Modified:
16 years, 9 months ago
Reviewers:
Andi Albrecht, GvR
CC:
Jeffrey Yasskin
Base URL:
http://rietveld.googlecode.com/svn/trunk/
Visibility:
Public.

Description

This resolves http://code.google.com/p/rietveld/issues/detail?id=82. Note that the patch will look correct in Rietveld, but won't have the same effect when downloaded via the "Download raw patch set" link; I could conceivably have upload.py send up the entire file, but that still wouldn't produce the same effect in the patched working copy (specifically, it wouldn't fix up SVN's internal metadata).

Patch Set 1 #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+68 lines, -9 lines) Patch
M static/upload.py View 1 chunk +68 lines, -9 lines 2 comments Download

Messages

Total messages: 3
Collin Winter
Hey Guido, please take a look at this patch to upload.py. Let me know how ...
16 years, 9 months ago (2009-04-10 21:42:14 UTC) #1
GvR
Sorry Collin, I'm all out of round tuits this week. Maybe Andi can have a ...
16 years, 9 months ago (2009-04-10 22:53:56 UTC) #2
Andi Albrecht
16 years, 9 months ago (2009-04-11 12:42:40 UTC) #3
IMO when downloading the diff from codereview it should apply as clean as
possible to give reviewers a chance to patch it in and test it locally.

As the diff always is in unified diff format VCS specific history will be lost,
at least for SVN. I'd prefer to have the base file uploaded for copied sources.
I think, it's up to the contributor to communicate that a certain file should be
copied when a patch goes in.

http://codereview.appspot.com/40050/diff/1/2
File static/upload.py (right):

http://codereview.appspot.com/40050/diff/1/2#newcode806
Line 806: data = RunShell(diff_cmd)
I think you should use RunShellWithReturnCode here or set the "silent_ok" flag
to True. If the changeset only contains a copied file from a remote location,
the script will stop here with "No output from ['svn', 'diff']". It only works,
if the changeset has other changes too.

http://codereview.appspot.com/40050/diff/1/2#newcode830
Line 830: data = RunShell(status_cmd)
Again, this raises an ErrorExit if "svn status" returns no output. IMO it's
better to raise the "No valid patches found..." exception in line 861.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b