Skip to content

Commit 5443845

Browse files
author
Richard Jones
committed
clearer docs for find(); couple of other post-release fixes
1 parent 4a58701 commit 5443845

File tree

7 files changed

+48
-49
lines changed

7 files changed

+48
-49
lines changed

doc/announcement.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,12 @@ from Ka-Ping Yee in the Software Carpentry "Track" design competition.
55
This 0.8.2 release adds one feature and fixes some bugs:
66

77
Feature:
8+
89
- roundup-server automatically redirects from trackers list
910
to the tracker page if there is only one tracker
1011

1112
Fixed:
13+
1214
- added content to ZRoundup refresh.txt file (sf bug 1147622)
1315
- fix invalid reference to csv.colon_separated
1416
- correct URL to What's New in setup.py meta-data

doc/design.txt

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -397,10 +397,10 @@ Here is the interface provided by the hyperdatabase::
397397
properties.
398398
"""
399399

400-
def restore(self, nodeid):
401-
'''Restore a retired node.
400+
def restore(self, itemid):
401+
'''Restore a retired item.
402402

403-
Make node available for all operations like it was before
403+
Make item available for all operations like it was before
404404
retirement.
405405
'''
406406

@@ -452,20 +452,21 @@ Here is the interface provided by the hyperdatabase::
452452
id is returned; otherwise a KeyError is raised.
453453
"""
454454

455-
def find(self, propname, itemid):
455+
def find(self, **propspec):
456456
"""Get the ids of items in this class which link to the
457457
given items.
458458

459-
'propspec' consists of keyword args propname={itemid:1,}
460-
'propname' must be the name of a property in this class, or
461-
a KeyError is raised. That property must be a Link or
462-
Multilink property, or a TypeError is raised.
459+
'propspec' consists of keyword args propname=itemid or
460+
propname={<itemid 1>:1, <itemid 2>: 1, ...}
461+
'propname' must be the name of a property in this class,
462+
or a KeyError is raised. That property must
463+
be a Link or Multilink property, or a TypeError
464+
is raised.
463465

464466
Any item in this class whose 'propname' property links to
465-
any of the itemids will be returned. Used by the full text
466-
indexing, which knows that "foo" occurs in msg1, msg3 and
467-
file7, so we have hits on these issues:
467+
any of the itemids will be returned. Examples::
468468

469+
db.issue.find(messages='1')
469470
db.issue.find(messages={'1':1,'3':1}, files={'7':1})
470471
"""
471472

roundup/backends/back_anydbm.py

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
# BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
1616
# SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
1717
#
18-
#$Id: back_anydbm.py,v 1.179.2.6 2005-02-14 05:40:54 richard Exp $
18+
#$Id: back_anydbm.py,v 1.179.2.7 2005-03-03 22:12:35 richard Exp $
1919
'''This module defines a backend that saves the hyperdatabase in a
2020
database chosen by anydbm. It is guaranteed to always be available in python
2121
versions >2.1.1 (the dumbdbm fallback in 2.1.1 and earlier has several
@@ -1431,16 +1431,15 @@ def find(self, **propspec):
14311431
'''Get the ids of items in this class which link to the given items.
14321432
14331433
'propspec' consists of keyword args propname=itemid or
1434-
propname={itemid:1, }
1434+
propname={<itemid 1>:1, <itemid 2>: 1, ...}
14351435
'propname' must be the name of a property in this class, or a
14361436
KeyError is raised. That property must be a Link or
14371437
Multilink property, or a TypeError is raised.
14381438
1439-
Any item in this class whose 'propname' property links to any of the
1440-
itemids will be returned. Used by the full text indexing, which knows
1441-
that "foo" occurs in msg1, msg3 and file7, so we have hits on these
1442-
issues:
1439+
Any item in this class whose 'propname' property links to any of
1440+
the itemids will be returned. Examples::
14431441
1442+
db.issue.find(messages='1')
14441443
db.issue.find(messages={'1':1,'3':1}, files={'7':1})
14451444
'''
14461445
propspec = propspec.items()

roundup/backends/back_metakit.py

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $Id: back_metakit.py,v 1.88.2.3 2005-02-14 02:55:31 richard Exp $
1+
# $Id: back_metakit.py,v 1.88.2.4 2005-03-03 22:12:35 richard Exp $
22
'''Metakit backend for Roundup, originally by Gordon McMillan.
33
44
Known Current Bugs:
@@ -1082,20 +1082,18 @@ def destroy(self, id):
10821082
self.db.dirty = 1
10831083

10841084
def find(self, **propspec):
1085-
'''Get the ids of nodes in this class which link to the given nodes.
1085+
'''Get the ids of items in this class which link to the given items.
10861086
1087-
'propspec'
1088-
consists of keyword args propname={nodeid:1,}
1089-
'propname'
1090-
must be the name of a property in this class, or a
1091-
KeyError is raised. That property must be a Link or
1092-
Multilink property, or a TypeError is raised.
1087+
'propspec' consists of keyword args propname=itemid or
1088+
propname={<itemid 1>:1, <itemid 2>: 1, ...}
1089+
'propname' must be the name of a property in this class, or a
1090+
KeyError is raised. That property must be a Link or
1091+
Multilink property, or a TypeError is raised.
10931092
1094-
Any node in this class whose propname property links to any of the
1095-
nodeids will be returned. Used by the full text indexing, which knows
1096-
that "foo" occurs in msg1, msg3 and file7; so we have hits on these
1097-
issues::
1093+
Any item in this class whose 'propname' property links to any of
1094+
the itemids will be returned. Examples::
10981095
1096+
db.issue.find(messages='1')
10991097
db.issue.find(messages={'1':1,'3':1}, files={'7':1})
11001098
'''
11011099
propspec = propspec.items()

roundup/backends/rdbms_common.py

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $Id: rdbms_common.py,v 1.142.2.6 2005-03-02 14:09:30 a1s Exp $
1+
# $Id: rdbms_common.py,v 1.142.2.7 2005-03-03 22:12:36 richard Exp $
22
''' Relational database (SQL) backend common code.
33
44
Basics:
@@ -1885,19 +1885,18 @@ def lookup(self, keyvalue):
18851885
return str(row[0])
18861886

18871887
def find(self, **propspec):
1888-
'''Get the ids of nodes in this class which link to the given nodes.
1888+
'''Get the ids of items in this class which link to the given items.
18891889
1890-
'propspec' consists of keyword args propname=nodeid or
1891-
propname={nodeid:1, }
1890+
'propspec' consists of keyword args propname=itemid or
1891+
propname={<itemid 1>:1, <itemid 2>: 1, ...}
18921892
'propname' must be the name of a property in this class, or a
18931893
KeyError is raised. That property must be a Link or
18941894
Multilink property, or a TypeError is raised.
18951895
1896-
Any node in this class whose 'propname' property links to any of the
1897-
nodeids will be returned. Used by the full text indexing, which knows
1898-
that "foo" occurs in msg1, msg3 and file7, so we have hits on these
1899-
issues:
1896+
Any item in this class whose 'propname' property links to any of
1897+
the itemids will be returned. Examples::
19001898
1899+
db.issue.find(messages='1')
19011900
db.issue.find(messages={'1':1,'3':1}, files={'7':1})
19021901
'''
19031902
# shortcut

roundup/hyperdb.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
# BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
1616
# SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
1717
#
18-
# $Id: hyperdb.py,v 1.107 2004-11-25 22:51:06 richard Exp $
18+
# $Id: hyperdb.py,v 1.107.2.1 2005-03-03 22:12:35 richard Exp $
1919

2020
"""Hyperdatabase implementation, especially field types.
2121
"""
@@ -494,20 +494,20 @@ def lookup(self, keyvalue):
494494
raise NotImplementedError
495495

496496
def find(self, **propspec):
497-
"""Get the ids of nodes in this class which link to the given nodes.
497+
'''Get the ids of items in this class which link to the given items.
498498
499-
'propspec' consists of keyword args propname={nodeid:1,}
499+
'propspec' consists of keyword args propname=itemid or
500+
propname={<itemid 1>:1, <itemid 2>:1, ...}
500501
'propname' must be the name of a property in this class, or a
501-
KeyError is raised. That property must be a Link or Multilink
502-
property, or a TypeError is raised.
502+
KeyError is raised. That property must be a Link or
503+
Multilink property, or a TypeError is raised.
503504
504-
Any node in this class whose 'propname' property links to any of the
505-
nodeids will be returned. Used by the full text indexing, which knows
506-
that "foo" occurs in msg1, msg3 and file7, so we have hits on these
507-
issues:
505+
Any item in this class whose 'propname' property links to any of
506+
the itemids will be returned. Examples::
508507
508+
db.issue.find(messages='1')
509509
db.issue.find(messages={'1':1,'3':1}, files={'7':1})
510-
"""
510+
'''
511511
raise NotImplementedError
512512

513513
def filter(self, search_matches, filterspec, sort=(None,None),

setup.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
# BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
1717
# SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
1818
#
19-
# $Id: setup.py,v 1.77.2.6 2005-03-03 04:47:35 richard Exp $
19+
# $Id: setup.py,v 1.77.2.7 2005-03-03 22:12:35 richard Exp $
2020

2121
from distutils.core import setup, Extension
2222
from distutils.util import get_platform
@@ -347,7 +347,7 @@ def main():
347347
'download_url': 'http://sourceforge.net/project/showfiles.php?group_id=31577',
348348
'packages': packagelist,
349349
'classifiers': [
350-
'Development Status :: 5 - Stable',
350+
'Development Status :: 5 - Production/Stable',
351351
'Environment :: Console',
352352
'Environment :: Web Environment',
353353
'Intended Audience :: End Users/Desktop',

0 commit comments

Comments
 (0)