Unable to view changes for a topic comments by clicking parallel link when using Clearcase Dynamic Repository

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Unable to view changes for a topic comments by clicking parallel link when using Clearcase Dynamic Repository

Ramesh Natarajan
Hi,

I installed codestriker 1.9.9  and created a clearcase dynamic repository.  When I create a issue and click on the parallel link, I get the error "No such file or directory"  in a popup window.

When I look at return value of  lib/Codestriker/Repository/ClearCaseDynamic.pm, we return empty string in case of no error

# Retrieve the data corresponding to $filename and $revision.  Store each line
# into $content_array_ref.
sub retrieve ($$$\$)
  {
      my ($self, $filename, $revision, $content_array_ref) = @_;
      my $error_msg = '';
.............
..............


  return $error_msg;
  }

and in lib/Codestriker/Action/ViewTopicFile.pm   we are checking if the

if ( ! $repository->retrieve($filename, $revision, \@filedata) )
$http_response->error("Couldn't get repository data for $filename " .
                                  "$revision: $!");
        }


Shouldn't  $error_msg in lib/Codestriker/Repository/ClearCaseDynamic.pm  initialized to undef  instead of empty string?

thanks
Ramesh

------------------------------------------------------------------------------
Come build with us! The BlackBerry® Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9-12, 2009. Register now!
http://p.sf.net/sfu/devconf
_______________________________________________
Codestriker-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/codestriker-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Unable to view changes for a topic comments by clicking parallel link when using Clearcase Dynamic Repository

David Sitsky
Administrator
> Shouldn't  $error_msg in lib/Codestriker/Repository/ClearCaseDynamic.pm
> initialized to undef  instead of empty string?

It appears that way.  Does this fix your issue if you make this change?

Cheers,
David

------------------------------------------------------------------------------
Come build with us! The BlackBerry® Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9-12, 2009. Register now!
http://p.sf.net/sfu/devconf
_______________________________________________
Codestriker-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/codestriker-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Unable to view changes for a topic comments by clicking parallel link whe

Ramesh Natarajan
Thanks for the quick response.

Yes. I got it to work by changing the Clearcase retrieve function to return 1 if the $error_msg eq ""

return 1 if ( $error_msg eq "" ); --> added to the ClearcaseDynamic.pm
return $error_msg;

I am not sure if this is the correct way to handle this..I am seeing inconsistency in handling error condition and the return values in the repository implementations for retrieve function.

For eg:

in Perforce.pm, we call die in case of error and there is no eval block to catch the die
and in success scenario the function doesn't return any value to the caller. The return value is assumed to be 1

in ClearcaseDynamic.pm we call die/eval in some places, reuse $error_msg variable in case of error while closing the view and
mask any error when trying to retrieve the clearcase data.

I started looking at codestriker today and I am really very impressed. Thanks for the fantastic tool.


thanks
Ramesh


On Oct 5, 2009 10:00pm, David Sitsky <[hidden email]> wrote:

> > Shouldn't  $error_msg in lib/Codestriker/Repository/ClearCaseDynamic.pm
>
> > initialized to undef  instead of empty string?
>
>
>
> It appears that way.  Does this fix your issue if you make this change?
>
>
>
> Cheers,
>
> David
>
------------------------------------------------------------------------------
Come build with us! The BlackBerry&reg; Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9&#45;12, 2009. Register now&#33;
http://p.sf.net/sfu/devconf
_______________________________________________
Codestriker-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/codestriker-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Unable to view changes for a topic comments by clicking parallel link whe

David Sitsky
Administrator
It is inconsistent.. I'll make sure this is cleaned up for 1.9.10.
The ClearCase modules were contributed and not well maintained.

On Tue, Oct 6, 2009 at 3:47 PM,  <[hidden email]> wrote:

> Thanks for the quick response.
>
> Yes. I got it to work by changing the Clearcase retrieve function to return
> 1 if the $error_msg eq ""
>
> return 1 if ( $error_msg eq "" ); --> added to the ClearcaseDynamic.pm
> return $error_msg;
>
> I am not sure if this is the correct way to handle this..I am seeing
> inconsistency in handling error condition and the return values in the
> repository implementations for retrieve function.
>
> For eg:
>
> in Perforce.pm, we call die in case of error and there is no eval block to
> catch the die
> and in success scenario the function doesn't return any value to the caller.
> The return value is assumed to be 1
>
> in ClearcaseDynamic.pm we call die/eval in some places, reuse $error_msg
> variable in case of error while closing the view and
> mask any error when trying to retrieve the clearcase data.
>
> I started looking at codestriker today and I am really very impressed.
> Thanks for the fantastic tool.
>
>
> thanks
> Ramesh
>
>
> On Oct 5, 2009 10:00pm, David Sitsky <[hidden email]> wrote:
>> > Shouldn't  $error_msg in lib/Codestriker/Repository/ClearCaseDynamic.pm
>>
>> > initialized to undef  instead of empty string?
>>
>>
>>
>> It appears that way.  Does this fix your issue if you make this change?
>>
>>
>>
>> Cheers,
>>
>> David
>>

------------------------------------------------------------------------------
Come build with us! The BlackBerry&reg; Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9&#45;12, 2009. Register now&#33;
http://p.sf.net/sfu/devconf
_______________________________________________
Codestriker-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/codestriker-user
Loading...