From 859d57514518e10f3648de2ab1896c689af88164 Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Thu, 13 Nov 2008 14:19:38 -0500 Subject: Added Hubert Chathi's git set-root bug report. Bug report patch from http://void.printf.net/pipermail/be-devel/attachments/20080623/49500aaf/0cad.bin Reporting thread [Be-devel] Re: set-root in git repository fails Hubert Chathi hubert at uhoreg.ca Tue Jun 24 03:49:23 BST 2008 http://void.printf.net/pipermail/be-devel/2008-June/000038.html --- .../16ba77d3-dfc9-4732-8d08-0e471f400d85/body | 34 ++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 .be/bugs/0cad2ac6-76ef-4a88-abdf-b2e02de76f5c/comments/16ba77d3-dfc9-4732-8d08-0e471f400d85/body (limited to '.be/bugs/0cad2ac6-76ef-4a88-abdf-b2e02de76f5c/comments/16ba77d3-dfc9-4732-8d08-0e471f400d85/body') diff --git a/.be/bugs/0cad2ac6-76ef-4a88-abdf-b2e02de76f5c/comments/16ba77d3-dfc9-4732-8d08-0e471f400d85/body b/.be/bugs/0cad2ac6-76ef-4a88-abdf-b2e02de76f5c/comments/16ba77d3-dfc9-4732-8d08-0e471f400d85/body new file mode 100644 index 0000000..595381c --- /dev/null +++ b/.be/bugs/0cad2ac6-76ef-4a88-abdf-b2e02de76f5c/comments/16ba77d3-dfc9-4732-8d08-0e471f400d85/body @@ -0,0 +1,34 @@ +When I try to do set-root on a git repository, I get: +# be set-root . +Traceback (most recent call last): + File "/usr/local/bin/be", line 55, in + sys.exit(execute(sys.argv[1], sys.argv[2:])) + File "/usr/lib/python2.5/site-packages/libbe/cmdutil.py", line 105, in execute + File "/usr/lib/python2.5/site-packages/becommands/set_root.py", line 57, in execute + File "/usr/lib/python2.5/site-packages/libbe/bugdir.py", line 110, in create_bug_dir + File "/usr/lib/python2.5/site-packages/libbe/bugdir.py", line 70, in set_version + File "/usr/lib/python2.5/site-packages/libbe/git.py", line 51, in set_file_contents + File "/usr/lib/python2.5/site-packages/libbe/git.py", line 38, in add_id + File "/usr/lib/python2.5/site-packages/libbe/git.py", line 33, in invoke_client + File "/usr/lib/python2.5/site-packages/libbe/rcs.py", line 63, in invoke + File "/usr/lib/python2.5/subprocess.py", line 594, in __init__ + errread, errwrite) + File "/usr/lib/python2.5/subprocess.py", line 1147, in _execute_child + raise child_exception +OSError: [Errno 2] No such file or directory: '' + +because the cwd argument for Popen is set to '' (the empty string). + +The following patch fixes the issue: +--- libbe/git.py 2008-06-22 19:52:14.000000000 -0400 ++++ libbe/git.py 2008-06-23 00:53:39.000000000 -0400 +@@ -26,7 +26,7 @@ + return filename + + def invoke_client(*args, **kwargs): +- directory = kwargs['directory'] ++ directory = kwargs['directory'] or None + expect = kwargs.get('expect', (0, 1)) + cl_args = ["git"] + cl_args.extend(args) + -- cgit