From d96e82c39a6b0bc9dedaf60b9c91e57fa9b4510b Mon Sep 17 00:00:00 2001 From: richard Date: Wed, 12 Feb 2003 00:00:32 +0000 Subject: [PATCH] - fixed error in indexargs_url (thanks Patrick Ohly) - fixed getnode (sf bug 684531) git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@1495 57a73879-2fb5-44c3-a270-3262357dd7e2 --- CHANGES.txt | 3 +++ doc/index.txt | 1 + roundup/backends/back_anydbm.py | 4 ++-- roundup/backends/back_metakit.py | 9 ++++++--- roundup/backends/rdbms_common.py | 4 ++-- roundup/cgi/client.py | 6 +----- roundup/cgi/templating.py | 2 +- 7 files changed, 16 insertions(+), 13 deletions(-) diff --git a/CHANGES.txt b/CHANGES.txt index 76da383..d3d3da2 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -43,8 +43,11 @@ are given with the most recent entry first. return positive values..." (literal 0xffff0000 in portalocker.py) - fixed ZPT code generating SyntaxWarning for assignment to None - add "ago" to intervals in the past (sf bug 679232) +- clarified licensing - another attempt to fix cookie misbehaviour - customise cookie name using tracker name +- fixed error in indexargs_url (thanks Patrick Ohly) +- fixed getnode (sf bug 684531) 2003-??-?? 0.5.6 diff --git a/doc/index.txt b/doc/index.txt index 37ad702..dec63c8 100644 --- a/doc/index.txt +++ b/doc/index.txt @@ -69,6 +69,7 @@ Luke Opperman, Will Partain, Bernhard Reiter, John P. Rouillard, +Florian Schulze, Dougal Scott, Stefan Seefeld, Jeffrey P Shell, diff --git a/roundup/backends/back_anydbm.py b/roundup/backends/back_anydbm.py index 681698b..ace6c45 100644 --- a/roundup/backends/back_anydbm.py +++ b/roundup/backends/back_anydbm.py @@ -15,7 +15,7 @@ # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. # -#$Id: back_anydbm.py,v 1.100 2003-02-06 05:43:47 richard Exp $ +#$Id: back_anydbm.py,v 1.101 2003-02-12 00:00:18 richard Exp $ ''' This module defines a backend that saves the hyperdatabase in a database chosen by anydbm. It is guaranteed to always be available in python @@ -30,7 +30,7 @@ from sessions import Sessions from roundup.indexer import Indexer from roundup.backends import locking from roundup.hyperdb import String, Password, Date, Interval, Link, \ - Multilink, DatabaseError, Boolean, Number + Multilink, DatabaseError, Boolean, Number, Node # # Now the database diff --git a/roundup/backends/back_metakit.py b/roundup/backends/back_metakit.py index 4d1fd4c..711a41b 100755 --- a/roundup/backends/back_metakit.py +++ b/roundup/backends/back_metakit.py @@ -50,7 +50,7 @@ def Database(config, journaltag=None): pass return db -class _Database(hyperdb.Database): +class _Database(hyperdb.Database, roundupdb.Database): def __init__(self, config, journaltag=None): self.config = config self.journaltag = journaltag @@ -1206,13 +1206,16 @@ class FileClass(Class): def get(self, nodeid, propname, default=_marker, cache=1): x = Class.get(self, nodeid, propname, default, cache) + poss_msg = 'Possibly an access right configuration problem.' if propname == 'content': if x.startswith('file:'): fnm = x[5:] try: x = open(fnm, 'rb').read() - except Exception, e: - x = repr(e) + except IOError, (strerror): + # XXX by catching this we donot see an error in the log. + return 'ERROR reading file: %s%s\n%s\n%s'%( + self.classname, nodeid, poss_msg, strerror) return x def create(self, **propvalues): diff --git a/roundup/backends/rdbms_common.py b/roundup/backends/rdbms_common.py index 3d41caf..1214555 100644 --- a/roundup/backends/rdbms_common.py +++ b/roundup/backends/rdbms_common.py @@ -1,4 +1,4 @@ -# $Id: rdbms_common.py,v 1.31 2003-02-08 15:31:28 kedder Exp $ +# $Id: rdbms_common.py,v 1.32 2003-02-12 00:00:25 richard Exp $ ''' Relational database (SQL) backend common code. Basics: @@ -27,7 +27,7 @@ import sys, os, time, re, errno, weakref, copy # roundup modules from roundup import hyperdb, date, password, roundupdb, security from roundup.hyperdb import String, Password, Date, Interval, Link, \ - Multilink, DatabaseError, Boolean, Number + Multilink, DatabaseError, Boolean, Number, Node from roundup.backends import locking # support diff --git a/roundup/cgi/client.py b/roundup/cgi/client.py index 80874cc..d2cb1a7 100644 --- a/roundup/cgi/client.py +++ b/roundup/cgi/client.py @@ -1,4 +1,4 @@ -# $Id: client.py,v 1.77 2003-02-07 04:49:13 richard Exp $ +# $Id: client.py,v 1.78 2003-02-12 00:00:28 richard Exp $ __doc__ = """ WWW request handler (also used in the stand-alone server). @@ -1166,10 +1166,6 @@ class Client: This is typically used on, eg. the file upload page to indicated which issue to link the file to. - - TODO: I suspect that this and newfile will go away now that - there's the ability to upload a file using the issue :file form - element! ''' cn = self.classname cl = self.db.classes[cn] diff --git a/roundup/cgi/templating.py b/roundup/cgi/templating.py index d69f68e..fc9713c 100644 --- a/roundup/cgi/templating.py +++ b/roundup/cgi/templating.py @@ -1526,7 +1526,7 @@ env: %(env)s else: val = self.group[1] l.append(':group=%s'%val) - if self.filter and not args.has_key(':columns'): + if self.filter and not args.has_key(':filter'): l.append(':filter=%s'%(','.join(self.filter))) for k,v in self.filterspec.items(): if not args.has_key(k): -- 2.30.2