[ClearCase] cat: /usr/cc_storage/unix_STREAM/.../myjava.sql@@/main/STREAM/2: No such file or directory\n

2009-08-12 Thread MiZhKa

Hi,

I wonder how reviewboard fetches file versions from ClearCase. Now I
have strange error from /api/json/reviewrequests/74/diff/new/:
{fields: {path: [cat: cat: /usr/cc_storage/unix_STREAM/.../
myjava.sql@@/main/STREAM/2: No such file or directory\n]}, stat:
fail, err: {msg: One or more fields had errors, code: 105}}

It seems that reviewboard (on server side) doesn't use cleartool to
fetch version of file. This can be seen from scmtools/clearcase.py:

class ClearCaseClient:
def __init__(self, path):
self.path = path

def cat_file(self, filename, revision):
p = subprocess.Popen(
['cat', filename],
stderr=subprocess.PIPE,
stdout=subprocess.PIPE,
close_fds=(os.name != 'nt')
)
contents = p.stdout.read()
errmsg = p.stderr.read()
failure = p.wait()

if not failure:
return contents

if errmsg.startswith(fatal: Not a valid object name):
raise FileNotFoundError(filename)
else:
raise SCMError(errmsg)

Is it mistake or my misunderstanding?

Thank you for your help!

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Re: [ClearCase] cat: /usr/cc_storage/unix_STREAM/.../myjava.sql@@/main/STREAM/2: No such file or directory\n

2009-08-12 Thread Christian Hammond
I think the person who contributed ClearCase support on the server expected
that the repository would be locally checked out with the path given. We'll
certainly take a patch to use cleartool to fix this.

We don't have access to ClearCase, so we can't do a lot of testing
ourselves.

Christian

-- 
Christian Hammond - chip...@chipx86.com
Review Board - http://www.review-board.org
VMware, Inc. - http://www.vmware.com


On Wed, Aug 12, 2009 at 10:56 AM, MiZhKa miz...@gmail.com wrote:


 Hi,

 I wonder how reviewboard fetches file versions from ClearCase. Now I
 have strange error from /api/json/reviewrequests/74/diff/new/:
 {fields: {path: [cat: cat: /usr/cc_storage/unix_STREAM/.../
 myjava.sql@@/main/STREAM/2: No such file or directory\n]}, stat:
 fail, err: {msg: One or more fields had errors, code: 105}}

 It seems that reviewboard (on server side) doesn't use cleartool to
 fetch version of file. This can be seen from scmtools/clearcase.py:

 class ClearCaseClient:
def __init__(self, path):
self.path = path

def cat_file(self, filename, revision):
p = subprocess.Popen(
['cat', filename],
stderr=subprocess.PIPE,
stdout=subprocess.PIPE,
close_fds=(os.name != 'nt')
)
contents = p.stdout.read()
errmsg = p.stderr.read()
failure = p.wait()

if not failure:
return contents

if errmsg.startswith(fatal: Not a valid object name):
raise FileNotFoundError(filename)
else:
raise SCMError(errmsg)

 Is it mistake or my misunderstanding?

 Thank you for your help!

 


--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---