Re: setting the default database in gnats 3.999.2

Hans-Albert Schneider <[email protected]>
Newsgroups gmane.comp.bug-tracking.gnats.general
Message-ID <[email protected]>
On Monday 16 June 2003 19:56, Erwin, Richard D wrote:

> I am going to assume, forthe moment, that can grab a copy of and
> adjust my categories file from my build of gnats 3.113 and adjust
> to suit.

The format did only change slightly.  Here are the explanations
from the "categories" file of the current sources:

# Each entry has the format:
#
# 	category:description:responsible:notify
#
# * `category' is the name of the classification for the PR.  The
#   first category listed will be the default assigned to PRs that
#   arrive without one set.  This is traditionally called "pending".
#
# * `description' can be a normal text description for the
#    category, like "Development Tools" for the `tools' category.
#
# * `responsible' gives the name (which can be found in the responsible
#    file) of the person who will be given responsibility for any PR
#    appearing in this category.
#
# * `notify' are other email addresses which should be given copies of
#    any PR in this category.  These names are also mapped through the
#    responsible file when trying to determine the email address to use.
#

I see the following differences compares to 3.1xx:

- The name of the "pending" category is not fixed anymore; it is simply
  the first one listed. So if you want the old behaviour, make sure there
  is a category named "pending", and that it is the first one listed in the
  categories file.

- According to the documentation cited above, the "notify" field is now
  also mapped through the "responsibles" file; in 3.1xx it contained
  e-mail addresses.  (I did not check the source code for this.)


Please note that both the name and the format of the file are now defined
in the "dbconfig" file, and can be changed there; look for
	field "Category" {
	...
	}
You can also rename the field; but you must keep the line
	builtin-name "category"

If you want to change the name of the category or the format of the file,
also look for cross references like 'Category[notify]'.

> In the meantime, any suggestions on how to fix the abovementioned
> error would be appreciated.

Check the permissions of the files and directories involved.
Especially: can you read the source file? Does it exits?
Try
	ls -l /usr/local/etc/gnats/defaults/categories
	ls -ld /usr/local/etc/gnats/defaults
The file should have mode 644 ("-rw-r--r--" at the beginning of the line),
and the directory should have mode 755 ("drwxr-xr-x"). The same holds
for the directories "above" it; i.e., for /usr/local/etc/gnats, /usr/local/etc,
/usr/local, /usr, and /).
(Well, this is not exactly true, but it simplifies the explanation.)

If one of the directories has fewer permissions, e.g. "drwx------",
please change them with the command
	chmod 755 /usr/local/etc/gnats/defaults
(or whichever directory it is).  The permissions of the file
can be changed with
	chmod 644 /usr/local/etc/gnats/defaults/categories

If
	cat /usr/local/etc/gnats/defaults/categories
works, so should the "cp".  Please also check the other files in
/usr/local/etc/gnats/defaults; they also need mode 644.

If it is really the permissions, please report this to the list.
I suspect that the "umask" which was active when you installed
gnats, so please type (as the user who did the "make install"):
	umask
and include the result in your report.
It may also have happened that someone changed the
permissions after installation.

Other ideas (they may be a bit queer):
- If /usr/local is mounted from another machine (typically via NFS),
  that machine may have been down when you typed mkdb.
- Are you sure you used the "mkdb" from the right place?
  (Not from another installation, or whatever.)
- What about error messages during installation?


Hans-Albert
-- 
Hans-Albert Schneider
Munich, Germany
EMail: [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.