Mercurial > p > roundup > code
diff doc/design.txt @ 6238:6834bb5473da
Summary: Constrain format of classname and document
Define the format of a valid classname. Updated design doc, function
doc and glossary to document format.
Error message for case where we have a redefinition of a classname now
says why ValueError is raised since we are raising ValueError for
incorrect classname format as well.
Tests for all cases including verification of cause for ValueError
exceptions.
| author | John Rouillard <rouilj@ieee.org> |
|---|---|
| date | Tue, 28 Jul 2020 06:24:39 -0400 |
| parents | 5522c950a2e4 |
| children | 6f5054751fb6 |
line wrap: on
line diff
--- a/doc/design.txt Tue Jul 28 05:51:00 2020 -0400 +++ b/doc/design.txt Tue Jul 28 06:24:39 2020 -0400 @@ -379,9 +379,13 @@ specification. 'classname' must not collide with the name of an existing - class, or a ValueError is raised. The keyword arguments in - 'properties' must map names to property objects, or a - TypeError is raised. + class, or a ValueError is raised. 'classname' must start + with an alphabetic letter. It must end with an + alphabetic letter or '_'. Internal characters can + be alphanumeric or '_'. ValueError is raised if the + classname is not correct. + The keyword arguments in 'properties' must map names to + property objects, or a TypeError is raised. A proxied reference to the database is available as the 'db' attribute on instances. For example, in @@ -1741,6 +1745,7 @@ - New Templating - Access Controls - Added "actor" property +- 'classname' format specified in class Class. .. _customisation: customizing.html
