Opened 13 years ago

Closed 13 years ago

#328 closed defect (fixed)

userid does not exist

Reported by: Jari Häkkinen Owned by:
Priority: major Milestone: svndigest 0.7
Component: svncopyright Version: trunk
Keywords: Cc:

Description (last modified by Jari Häkkinen)

After almost 3 hours of parsing of the BASE project for copyright updating I get

Parsing /Users/jari/tmp/2.7-stable/www/switch.jsp
Parsing /Users/jari/tmp/2.7-stable/base2.license.txt
Parsing /Users/jari/tmp/2.7-stable/build.xml
Parsing /Users/jari/tmp/2.7-stable/credits.txt
Updating copyright statements
svndigest: nicklas does not exist

According to the svndigest config nicklas do exist, http://base.thep.lu.se/browser/branches/2.7-stable/.svndigest/config

There was no further output, not even one copyright was changed! I run svndigest as

./bin/svndigest -r ~/tmp/2.7-stable --copyright --no-report --verbose

Related to ticket:275, or even a duplicate?

Change History (12)

comment:1 Changed 13 years ago by Jari Häkkinen

Description: modified (diff)

comment:2 Changed 13 years ago by Peter Johansson

What is your output from

./bin/svndigest --version

This seems to be different from ticket:275.

comment:3 Changed 13 years ago by Peter Johansson

Also what is the output if you do

./bin/svndigest -r ~/tmp/2.7-stable -g

Is it similar to the config file. Is there any nicklas?

comment:4 in reply to:  2 Changed 13 years ago by Jari Häkkinen

Replying to peter:

What is your output from

./bin/svndigest --version

I am running a binary from trunk

svndigest pre0.7 (r634 compiled 14:05:08, May 12 2008)

comment:5 in reply to:  3 ; Changed 13 years ago by Jari Häkkinen

Replying to peter:

Also what is the output if you do

./bin/svndigest -r ~/tmp/2.7-stable -g

Is it similar to the config file. Is there any nicklas?

Huh ... no and yas. The config file we use is http://base.thep.lu.se/browser/branches/2.7-stable/.svndigest/config. This is similar to the most files I use. Obviously I need to replace a few config when 0.7 is released.

'nicklas' is there and the copyright-alias section matches after I remove the stray ' ' (white space character) at the end of the names in the generated file.

Also, I noticed that

# if true svndigest will warn if file has no copyright statement.
missing-copyright-warning = no

is not describing the outcome of not having this option in the config file. My understanding of the code is that a exception is thrown rather than warning report ... this made my program to abort. Is this the cause to my problems?

comment:6 in reply to:  5 Changed 13 years ago by Peter Johansson

Replying to jari:

Replying to peter:

Also what is the output if you do

./bin/svndigest -r ~/tmp/2.7-stable -g

Is it similar to the config file. Is there any nicklas?

Huh ... no and yas. The config file we use is http://base.thep.lu.se/browser/branches/2.7-stable/.svndigest/config. This is similar to the most files I use. Obviously I need to replace a few config when 0.7 is released.

If an entry is missing in the config file, the default values are used which typically means 0.6 behavior.

'nicklas' is there and the copyright-alias section matches after I remove the stray ' ' (white space character) at the end of the names in the generated file.

Also, I noticed that

# if true svndigest will warn if file has no copyright statement.
missing-copyright-warning = no

is not describing the outcome of not having this option in the config file. My understanding of the code is that a exception is thrown rather than warning report ... this made my program to abort. Is this the cause to my problems?

There should be no exceptions thrown. Warnings should be given through std::cerr. If you are right, it is a bug. There are two kinds of warnings. 1) missing alias or 2) missing copyright statement in a file.

comment:7 Changed 13 years ago by Peter Johansson

As I understand the warning is given through std::cerr approximately at line 298 in File.cc

if (!detect_copyright(old_block, start_line, end_line, prefix)){
  if (Configuration::instance().missing_copyright_warning())
    std::cerr << "svndigest: warning: no copyright statement found in `" 
              << path_ << "'\n";
  return;
}

What throwing are you talking about?

comment:8 in reply to:  7 Changed 13 years ago by Jari Häkkinen

Replying to peter:

As I understand the warning is given through std::cerr approximately at line 298 in File.cc ... What throwing are you talking about?

I ended up in trunk/lib/Stats.cc#L517, and this was after starting copyright update according to svndigest verbose output.

comment:9 Changed 13 years ago by Peter Johansson

First of all, if you wanna test this, remember that you can run on a sub-directory; preferably the smallest you can find.

I would guess the problem is in function copyright_map roughly at source:trunk/lib/File.cc#L72

I was incorrect in previous posting: it seeems the log is still used. I would guess that is the problem: somehow the stats object and the log is not synched. So after all you were right, this is probably a duplicate of ticket:275

comment:10 Changed 13 years ago by Peter Johansson

Owner: changed from Jari Häkkinen to Peter Johansson
Status: newassigned

(In [653]) refs #328 adding a map from year2last_rev - I only wanna create this function once so I create an extra layer and put the creation of map in the intermediate layer.

comment:11 Changed 13 years ago by Peter Johansson

Owner: Peter Johansson deleted
Status: assignednew

(In [654]) Hopefully fixes #328 - need to be tested though

comment:12 Changed 13 years ago by Peter Johansson

Resolution: fixed
Status: newclosed

(in [657]) I've tested copyright update in yat/yat/random and it works as expected.

Note: See TracTickets for help on using tickets.