Repository started as svn copy, any hope for StatSVN

8 messages Options
Embed this post
Permalink
Allan Cochrane

Repository started as svn copy, any hope for StatSVN

Reply Threaded More More options
Print post
Permalink
Hi,

the repository I'm trying to analyse started as an SVN copy of another repository.

StatSVN 0.6 cannot handle this:

cam-eis5:acochran > java -jar ../statsvn.jar -verbose -debug ../svn_log.xml $PWD
Oct 2, 2009 7:53:36 PM net.sf.statsvn.util.JavaUtilTaskLogger info
INFO: StatSVN - SVN statistics generation

Parsing SVN log '../svn_log.xml'No exclude pattern
FINE statsvn.util.JavaUtilTaskLogger log(): starting to parse...
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn log finished in 614 ms.
FINE statsvn.util.JavaUtilTaskLogger log(): verifying implicit actions ...
FINE statsvn.util.JavaUtilTaskLogger log(): verifying implicit actions finished in 0 ms.
FINE statsvn.util.JavaUtilTaskLogger log(): Repositories: java.io.FileNotFoundException: /home/acochran/.statsvn/repositories.xml (No such file or directory)
FINE statsvn.util.JavaUtilTaskLogger log(): parsing repositories finished in 93 ms.
FINE statsvn.util.JavaUtilTaskLogger log(): Cache: java.io.FileNotFoundException: /home/acochran/.statsvn/cache_f12f6618-48eb-0310-9b08-91bc75ea3a48.xml (No such file or directory)
FINE statsvn.util.JavaUtilTaskLogger log(): parsing line counts finished in 1 ms.
Scheduled 0 svn diff calls on 0 threads.
FINE statsvn.util.JavaUtilTaskLogger log(): ================ Wait for completion =========================
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn diff
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn diff finished in 18 ms.
Generating report for /targets/heron/trunk/target into
Using default CSS file (objectlab-statcvs.css)
memory usage After Build: 0.0 kb
The repository object is not valid. Please check your settings.
Possible reasons:
1/ Did you use the option -v to create the SVN log
2/ Is the log file empty?
3/ Do you run from a checked out directory (you should)?
4/ Do you have non-committed items?


This is version 0.6 (beta). The same things happens with 0.5


Reading other posts in the forums would seem to indicate that using the svn copy feature breaks StatSVN.

Is there any way that I might be able to use StatSVN on the repository?

If not, can I hack the XML from svn log to make it work?

Thanks,

Allan
Jason Kealey-2

Re: Repository started as svn copy, any hope for StatSVN

Reply Threaded More More options
Print post
Permalink
I doubt you are crashing here because of the fact that this is an SVN copy. It looks more like the fact that your log file is empty or you have one of the other common errors listed by StatSVN, for example. By default, svn log follows copies - the limitation it currently has (if I remember correctly) is that it sees copies as additions so you might get inflated stats. 

Start by taking a look at what data is available in your log file and that you are pointing to the correct checked out directory ( $PWD looks like an unreplaced script variable ) 

Thanks, 
---
Jason Kealey - [hidden email]
LavaBlast Franchise Software - http://www.lavablast.com
Simplifying day-to-day franchise operations


On Fri, Oct 2, 2009 at 4:37 PM, Allan Cochrane <[hidden email]> wrote:

Hi,

the repository I'm trying to analyse started as an SVN copy of another
repository.

StatSVN 0.6 cannot handle this:

cam-eis5:acochran > java -jar ../statsvn.jar -verbose -debug ../svn_log.xml
$PWD
Oct 2, 2009 7:53:36 PM net.sf.statsvn.util.JavaUtilTaskLogger info
INFO: StatSVN - SVN statistics generation

Parsing SVN log '../svn_log.xml'No exclude pattern
FINE statsvn.util.JavaUtilTaskLogger log(): starting to parse...
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn log finished in 614
ms.
FINE statsvn.util.JavaUtilTaskLogger log(): verifying implicit actions ...
FINE statsvn.util.JavaUtilTaskLogger log(): verifying implicit actions
finished in 0 ms.
FINE statsvn.util.JavaUtilTaskLogger log(): Repositories:
java.io.FileNotFoundException: /home/acochran/.statsvn/repositories.xml (No
such file or directory)
FINE statsvn.util.JavaUtilTaskLogger log(): parsing repositories finished in
93 ms.
FINE statsvn.util.JavaUtilTaskLogger log(): Cache:
java.io.FileNotFoundException:
/home/acochran/.statsvn/cache_f12f6618-48eb-0310-9b08-91bc75ea3a48.xml (No
such file or directory)
FINE statsvn.util.JavaUtilTaskLogger log(): parsing line counts finished in
1 ms.
Scheduled 0 svn diff calls on 0 threads.
FINE statsvn.util.JavaUtilTaskLogger log(): ================ Wait for
completion =========================
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn diff
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn diff finished in 18
ms.
Generating report for /targets/heron/trunk/target into
Using default CSS file (objectlab-statcvs.css)
memory usage After Build: 0.0 kb
The repository object is not valid. Please check your settings.
Possible reasons:
1/ Did you use the option -v to create the SVN log
2/ Is the log file empty?
3/ Do you run from a checked out directory (you should)?
4/ Do you have non-committed items?


This is version 0.6 (beta). The same things happens with 0.5


Reading other posts in the forums would seem to indicate that using the svn
copy feature breaks StatSVN.

Is there any way that I might be able to use StatSVN on the repository?

If not, can I hack the XML from svn log to make it work?

Thanks,

Allan
--
View this message in context: http://n2.nabble.com/Repository-started-as-svn-copy-any-hope-for-StatSVN-tp3757628p3757628.html
Sent from the StatSVN Users mailing list archive at Nabble.com.

------------------------------------------------------------------------------
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
_______________________________________________
Statsvn-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/statsvn-users



------------------------------------------------------------------------------
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
_______________________________________________
Statsvn-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/statsvn-users
Allan Cochrane

Re: Repository started as svn copy, any hope for StatSVN

Reply Threaded More More options
Print post
Permalink

I doubt you are crashing here because of the fact that this is an SVN copy.
It looks more like the fact that your log file is empty or you have one of
the other common errors listed by StatSVN, for example. By default, svn log
follows copies - the limitation it currently has (if I remember correctly)
is that it sees copies as additions so you might get inflated stats.
Start by taking a look at what data is available in your log file and that
you are pointing to the correct checked out directory ( $PWD looks like an
unreplaced script variable )

Hi,

thanks for the quick response!

The log file looks OK, it starts with the lines:

<?xml version="1.0"?>
<log>
<logentry
   revision="35619">
<author>dbrook</author>
<date>2009-08-12T10:53:07.051959Z</date>
<paths>
<path
   kind=""
   copyfrom-path="/targets/c"
   copyfrom-rev="35618"
   action="A">/targets/h</path>
</paths>
<msg>Copied world to new project.</msg>
</logentry>
...

$PWD is expanded by the shell, it evaluates to the current directory (aka '.')

I am running from a checked out directory, I have put the log elsewhere and can also ask that the output directory and cache directories are located somewhere else, without any success.

I think that the repositories.xml file is the culprit, first run gives:

Parsing SVN log '../svn_log.xml' exclude pattern 'null'
FINE statsvn.util.JavaUtilTaskLogger log(): starting to parse...
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn log finished in 511 ms.
FINE statsvn.util.JavaUtilTaskLogger log(): verifying implicit actions ...
FINE statsvn.util.JavaUtilTaskLogger log(): verifying implicit actions finished in 1 ms.
FINE statsvn.util.JavaUtilTaskLogger log(): Repositories: java.io.FileNotFoundException: ../statsvn.cache/repositories.xml (No such file or directory)
FINE statsvn.util.JavaUtilTaskLogger log(): parsing repositories finished in 70 ms.
FINE statsvn.util.JavaUtilTaskLogger log(): Cache: java.io.FileNotFoundException: ../statsvn.cache/cache_f12f6618-48eb-0310-9b08-91bc75ea3a48.xml (No such file or directory)
FINE statsvn.util.JavaUtilTaskLogger log(): parsing line counts finished in 1 ms.
Scheduled 0 svn diff calls on 0 threads.
FINE statsvn.util.JavaUtilTaskLogger log(): ================ Wait for completion =========================
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn diff
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn diff finished in 20 ms.
Generating report for /targets/heron/trunk/target into ../html_report/
Using default CSS file (objectlab-statcvs.css)
The repository object is not valid. Please check your settings.
Is the log file empty? Do you run from a checked out directory? Do you have non-committed items?

and the second run gives:

eis5:acochran > java -jar ../statsvn.jar -disable-twitter-button -output-dir ../html_report -cache-dir ../statsvn.cache -verbose -debug ../svn_log.xml .
Oct 2, 2009 10:25:33 PM net.sf.statsvn.util.JavaUtilTaskLogger info
INFO: StatSVN - SVN statistics generation

Parsing SVN log '../svn_log.xml' exclude pattern 'null'
FINE statsvn.util.JavaUtilTaskLogger log(): starting to parse...
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn log finished in 506 ms.
FINE statsvn.util.JavaUtilTaskLogger log(): verifying implicit actions ...
FINE statsvn.util.JavaUtilTaskLogger log(): verifying implicit actions finished in 1 ms.
FINE statsvn.util.JavaUtilTaskLogger log(): parsing repositories finished in 30 ms.
Cache: org.xml.sax.SAXParseException: Premature end of file.
FINE statsvn.util.JavaUtilTaskLogger log(): parsing line counts finished in 5 ms.
Scheduled 0 svn diff calls on 0 threads.
FINE statsvn.util.JavaUtilTaskLogger log(): ================ Wait for completion =========================
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn diff
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn diff finished in 20 ms.
Generating report for /targets/heron/trunk/target into ../html_report/
Using default CSS file (objectlab-statcvs.css)
The repository object is not valid. Please check your settings.
Is the log file empty? Do you run from a checked out directory? Do you have non-committed items?


The issue seems to be that the cache_<UUID>.xml file is not written correctly since it contains only the <?xml ...?> line

Allan
Jason Kealey-2

Re: Repository started as svn copy, any hope for StatSVN

Reply Threaded More More options
Print post
Permalink
Have you managed to run it successfully on any project other than yours? It might be good to start by running on some small open source project to ensure that there are no conflicts with the XML parsers installed on your machine. 

From what I can see, the cache_<UUID>.xml is a symptom - not the cause. It can't find any work to do, so it doesn't save anything to the cache. 

1) What version of SVN are you using?
2) Does svn info --xml give some information when executed in your checked out folder?
3) What is the last revision shown in your log file? (I assume your file is very lengthy)
4) Can you get it running on another project?

Thanks,
---
Jason Kealey - [hidden email]
LavaBlast Franchise Software - http://www.lavablast.com
Simplifying day-to-day franchise operations


On Fri, Oct 2, 2009 at 5:30 PM, Allan Cochrane <[hidden email]> wrote:


I doubt you are crashing here because of the fact that this is an SVN copy.
It looks more like the fact that your log file is empty or you have one of
the other common errors listed by StatSVN, for example. By default, svn log
follows copies - the limitation it currently has (if I remember correctly)
is that it sees copies as additions so you might get inflated stats.
Start by taking a look at what data is available in your log file and that
you are pointing to the correct checked out directory ( $PWD looks like an
unreplaced script variable )

Hi,

thanks for the quick response!

The log file looks OK, it starts with the lines:

<?xml version="1.0"?>
<log>
<logentry
  revision="35619">
<author>dbrook</author>
<date>2009-08-12T10:53:07.051959Z</date>
<paths>
<path
  kind=""
  copyfrom-path="/targets/c"
  copyfrom-rev="35618"
  action="A">/targets/h</path>
</paths>
<msg>Copied world to new project.</msg>
</logentry>
...

$PWD is expanded by the shell, it evaluates to the current directory (aka
'.')

I am running from a checked out directory, I have put the log elsewhere and
can also ask that the output directory and cache directories are located
somewhere else, without any success.

I think that the repositories.xml file is the culprit, first run gives:

Parsing SVN log '../svn_log.xml' exclude pattern 'null'
FINE statsvn.util.JavaUtilTaskLogger log(): starting to parse...
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn log finished in 511
ms.
FINE statsvn.util.JavaUtilTaskLogger log(): verifying implicit actions ...
FINE statsvn.util.JavaUtilTaskLogger log(): verifying implicit actions
finished in 1 ms.
FINE statsvn.util.JavaUtilTaskLogger log(): Repositories:
java.io.FileNotFoundException: ../statsvn.cache/repositories.xml (No such
file or directory)
FINE statsvn.util.JavaUtilTaskLogger log(): parsing repositories finished in
70 ms.
FINE statsvn.util.JavaUtilTaskLogger log(): Cache:
java.io.FileNotFoundException:
../statsvn.cache/cache_f12f6618-48eb-0310-9b08-91bc75ea3a48.xml (No such
file or directory)
FINE statsvn.util.JavaUtilTaskLogger log(): parsing line counts finished in
1 ms.
Scheduled 0 svn diff calls on 0 threads.
FINE statsvn.util.JavaUtilTaskLogger log(): ================ Wait for
completion =========================
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn diff
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn diff finished in 20
ms.
Generating report for /targets/heron/trunk/target into ../html_report/
Using default CSS file (objectlab-statcvs.css)
The repository object is not valid. Please check your settings.
Is the log file empty? Do you run from a checked out directory? Do you have
non-committed items?

and the second run gives:

eis5:acochran > java -jar ../statsvn.jar -disable-twitter-button -output-dir
../html_report -cache-dir ../statsvn.cache -verbose -debug ../svn_log.xml .
Oct 2, 2009 10:25:33 PM net.sf.statsvn.util.JavaUtilTaskLogger info
INFO: StatSVN - SVN statistics generation

Parsing SVN log '../svn_log.xml' exclude pattern 'null'
FINE statsvn.util.JavaUtilTaskLogger log(): starting to parse...
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn log finished in 506
ms.
FINE statsvn.util.JavaUtilTaskLogger log(): verifying implicit actions ...
FINE statsvn.util.JavaUtilTaskLogger log(): verifying implicit actions
finished in 1 ms.
FINE statsvn.util.JavaUtilTaskLogger log(): parsing repositories finished in
30 ms.
Cache: org.xml.sax.SAXParseException: Premature end of file.
FINE statsvn.util.JavaUtilTaskLogger log(): parsing line counts finished in
5 ms.
Scheduled 0 svn diff calls on 0 threads.
FINE statsvn.util.JavaUtilTaskLogger log(): ================ Wait for
completion =========================
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn diff
FINE statsvn.util.JavaUtilTaskLogger log(): parsing svn diff finished in 20
ms.
Generating report for /targets/heron/trunk/target into ../html_report/
Using default CSS file (objectlab-statcvs.css)
The repository object is not valid. Please check your settings.
Is the log file empty? Do you run from a checked out directory? Do you have
non-committed items?


The issue seems to be that the cache_<UUID>.xml file is not written
correctly since it contains only the <?xml ...?> line

Allan

--
View this message in context: http://n2.nabble.com/Repository-started-as-svn-copy-any-hope-for-StatSVN-tp3757628p3757877.html
Sent from the StatSVN Users mailing list archive at Nabble.com.

------------------------------------------------------------------------------
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
_______________________________________________
Statsvn-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/statsvn-users



------------------------------------------------------------------------------
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
_______________________________________________
Statsvn-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/statsvn-users
Allan Cochrane

Re: Repository started as svn copy, any hope for StatSVN

Reply Threaded More More options
Print post
Permalink
Jason Kealey-2 wrote:
Have you managed to run it successfully on any project other than yours? It
might be good to start by running on some small open source project to
ensure that there are no conflicts with the XML parsers installed on your
machine.
>From what I can see, the cache_<UUID>.xml is a symptom - not the cause. It
can't find any work to do, so it doesn't save anything to the cache.

1) What version of SVN are you using?
2) Does svn info --xml give some information when executed in your checked
out folder?
3) What is the last revision shown in your log file? (I assume your file is
very lengthy)
4) Can you get it running on another project?
I do have it running well on a different site so it may be a version difference even though the IT folk try to keep things consistent!

1) svn revision 1.6.2 (r37639)
2) Yes that all looks fine
3) the log extends from the most recent revision 35619 to the oldest revision 3108
4) It works on another project and it partially works on a directory above the one I'm interested in

Thanks,

Allan
Jason Kealey-2

Re: Repository started as svn copy, any hope for StatSVN

Reply Threaded More More options
Print post
Permalink
At this point, I admit we'd have to run StatSVN in Eclipse (debug) to have an idea of what might be going wrong in your machine. Are you familiar with Java (given this is sensitive data)?

Thanks,
---
Jason Kealey - [hidden email]
LavaBlast Franchise Software - http://www.lavablast.com
Simplifying day-to-day franchise operations


On Mon, Oct 5, 2009 at 12:45 PM, Allan Cochrane <[hidden email]> wrote:


Jason Kealey-2 wrote:
>
> Have you managed to run it successfully on any project other than yours?
> It
> might be good to start by running on some small open source project to
> ensure that there are no conflicts with the XML parsers installed on your
> machine.
>>From what I can see, the cache_<UUID>.xml is a symptom - not the cause. It
> can't find any work to do, so it doesn't save anything to the cache.
>
> 1) What version of SVN are you using?
> 2) Does svn info --xml give some information when executed in your checked
> out folder?
> 3) What is the last revision shown in your log file? (I assume your file
> is
> very lengthy)
> 4) Can you get it running on another project?
>
>
>

I do have it running well on a different site so it may be a version
difference even though the IT folk try to keep things consistent!

1) svn revision 1.6.2 (r37639)
2) Yes that all looks fine
3) the log extends from the most recent revision 35619 to the oldest
revision 3108
4) It works on another project and it partially works on a directory above
the one I'm interested in

Thanks,

Allan

--
View this message in context: http://n2.nabble.com/Repository-started-as-svn-copy-any-hope-for-StatSVN-tp3757628p3770056.html
Sent from the StatSVN Users mailing list archive at Nabble.com.

------------------------------------------------------------------------------
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
_______________________________________________
Statsvn-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/statsvn-users



------------------------------------------------------------------------------
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
_______________________________________________
Statsvn-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/statsvn-users
Allan Cochrane

Re: Repository started as svn copy, any hope for StatSVN

Reply Threaded More More options
Print post
Permalink
Some javascript/style in this post has been disabled (why?)

Hi,

 

I can debug Java, I think! I’ll check out the sources and see where I get to. Do you have any possible starting points?

 

Allan

 

 
--
IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.
------------------------------------------------------------------------------
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
_______________________________________________
Statsvn-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/statsvn-users
Jason Kealey-2

Re: Repository started as svn copy, any hope for StatSVN

Reply Threaded More More options
Print post
Permalink
Start by looking at net.sf.statsvn.Main.validate() to figure out which of the conditions is failing. 

private static void validate(final ReportConfig config) {
        if (config.getRepository() == null || config.getRepository().getRoot() == null || config.getRepository().getDirectories() == null) {
            String cr = System.getProperty("line.separator");
            printErrorMessageAndExit("The repository object is not valid. Please check your settings." + cr + "Possible reasons:" + cr
                    + "1/ Did you use the option -v to create the SVN log" + cr + "2/ Is the log file empty?" + cr
                    + "3/ Do you run from a checked out directory (you should)?" + cr + "4/ Do you have non-committed items?");
        }
    }

Then, move back up the code to see if you can find anything of interest that is failing. 

---
Jason Kealey - [hidden email]
LavaBlast Franchise Software - http://www.lavablast.com
Simplifying day-to-day franchise operations


On Mon, Oct 5, 2009 at 1:15 PM, Allan Cochrane <[hidden email]> wrote:

Hi,

 

I can debug Java, I think! I’ll check out the sources and see where I get to. Do you have any possible starting points?

 

Allan

 

 
--
IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.


------------------------------------------------------------------------------
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
_______________________________________________
Statsvn-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/statsvn-users