Hi, Dana: I saw your posts are rendered at full length each line, but mine are wrapped at 70-80 characters, which makes them look quite different from what I originally posted.
What is the trick? Thanks On Sep 23, 11:28 am, Hui Lin <hui....@bankofamerica.com> wrote: > The issue started from line 107 of "diffutils.py". This is how the > "patch" is executed: > p = subprocess.Popen(['patch', '-o', newfile, oldfile], > stdin=subprocess.PIPE, > stdout=subprocess.PIPE, > stderr=subprocess.STDOUT) > > The subsequent error checking isn't adequent, as in this case, "p.wait > ()" returns "false", but the "patch_output" indicates that it actually > failed. > patch_output = p.stdout.read() > failure = p.wait() > > if failure: > ... > > On Sep 23, 1:00 am, Christian Hammond <chip...@chipx86.com> wrote: > > > > > Strange. This is not an issue I've seen before. I can't tell if the error is > > just overly escaping the "\" or if the filename is invalid. > > > Do you know exactly what line is causing that error in the code? > > > Christian > > > -- > > Christian Hammond - chip...@chipx86.com > > Review Board -http://www.review-board.org > > VMware, Inc. -http://www.vmware.com > > > On Tue, Sep 22, 2009 at 10:39 PM, Hui Lin <hui....@bankofamerica.com> wrote: > > > > Uploading the diff works now after fixing some perforce registry > > > issues. > > > > However, when I click the "View Diff" button in the request details > > > page, I got this error: > > > [Errno 2] No such file or directory: 'c:\\winnt\\temp\ > > > \reviewboard.jyl6y5\\tmpsx6zut-new' > > > > The patched new file isn't there. I turned on the debug, and saw the > > > output of the patch command: > > > Hmm... I can't seem to find a patch in there anywhere. > > > > I tweaked the code of "diffutils.py" by first saving the diff data > > > into a file, and then run the patch command: > > > patch -d c:\winnt\temp\reviewboard.jyl6y5 -i tmpsx6zut-diff -o > > > tmpsx6zut-new tmpsx6zut > > > > But still not working. This command worked fine when executed in the > > > DOS console. > > > > It also works fine when executed in python runtime interactively: > > > >>> command = 'patch -d c:\winnt\temp\reviewboard.jyl6y5 -i > > > tmpsx6zut-diff -o tmpsx6zut-new tmpsx6zut' > > > >>> import subprocess > > > >>> p = subprocess.Popen(command, stdin=subprocess.PIPE, > > > stdout=subprocess.PIPE, stderr=subprocess.STDOUT) > > > >>> p.stdout.read() > > > 'patching file c:\\winnt\\temp\\reviewboard.zug54j\\tmp-wkiqd\r\n' > > > > What could be wrong? > > > > I am using the GnuWin32 patch version 2.5.9. > > > > On Sep 22, 6:45 pm, "Lacoste, Dana (TSG Software San Diego)" > > > <dana.laco...@hp.com> wrote: > > > > OK, that makes sense. > > > > > I was just hoping for a quicker solution to the "give me the whole file" > > > problem ☺ > > > > > I'll see what I can provide in the realm of support for coding that ☺ > > > > > Dana > > > > > From: reviewboard@googlegroups.com [mailto:reviewbo...@googlegroups.com] > > > On Behalf Of Christian Hammond > > > > Sent: Tuesday, September 22, 2009 4:38 PM > > > > To: reviewboard@googlegroups.com > > > > Subject: Re: post-review login issue > > > > > Hi Dana, > > > > > We specifically avoid this for a few reasons. > > > > > 1) It's much more efficient to store a diff in the database instead of a > > > full file. > > > > > 2) We need both an original, unmodified file along with the patched > > > > file. > > > This means that either we still need to do a server fetch, or we now need > > > both files uploaded and stored in the database. > > > > > 3) It actually limits us. By having the diff, future extensions to > > > > Review > > > Board may be able to do things like track a patch's freshness (useful for > > > contributed patches to open source projects) by periodically attempting to > > > apply the patch to the latest version in a codebase. If we use full files, > > > we can't build this kind of extensibility. > > > > > 4) Review Board now needs to know how to generate every kind of diff we > > > could possibly need for every revision control system when the user clicks > > > Download Diff. We want to preserve the diffs uploaded. For example, A Git > > > diff may contain some author and description information embedded in the > > > diff. We can't reproduce this. > > > > > There's no reason today why we can't build the functionality to download > > > the modified files. It's just a matter of looking up the list of files > > > associated with a change and calling our existing function to grab the > > > patched version of the file from the repository, then assemble them into a > > > zip or something for download. > > > > > Christian > > > > > -- > > > > Christian Hammond - chip...@chipx86.com<mailto:chip...@chipx86.com> > > > > Review Board -http://www.review-board.org > > > > VMware, Inc. -http://www.vmware.com-Hide quoted text - > > > - Show quoted text -- Hide quoted text - > > - Show quoted text - --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "reviewboard" group. To post to this group, send email to reviewboard@googlegroups.com To unsubscribe from this group, send email to reviewboard+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/reviewboard?hl=en -~----------~----~----~----~------~----~------~--~---