You can subscribe to this list here.
| 2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(4) |
Jul
(3) |
Aug
(9) |
Sep
(4) |
Oct
|
Nov
|
Dec
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
| 2010 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(2) |
Jun
(1) |
Jul
|
Aug
(1) |
Sep
(2) |
Oct
|
Nov
|
Dec
|
| 2011 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
(1) |
Aug
|
Sep
|
Oct
(1) |
Nov
(1) |
Dec
(1) |
| 2012 |
Jan
|
Feb
|
Mar
(2) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
(1) |
Nov
(2) |
Dec
(2) |
| 2013 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
|
|
|
|
1
|
2
|
3
|
|
4
|
5
|
6
|
7
|
8
|
9
|
10
|
|
11
|
12
|
13
|
14
|
15
|
16
|
17
|
|
18
|
19
|
20
|
21
(2) |
22
|
23
|
24
(1) |
|
25
(1) |
26
|
27
|
28
|
29
|
30
|
|
|
From: Eldar O. <eom...@gm...> - 2005-09-25 02:05:14
|
Hi all. I heard we're using svn now for CanDo. Can I please have access to that so I can commit some changes? Cheers. -Eldar |
|
From: Tom v. S. <tv...@ci...> - 2005-09-24 20:11:05
|
Paul, et al
The coding conventions mail I sent to Paul and Jeff a short while ago is
reproduced here so everyone can see it. =20
Following these conventions (and reading the referenced guides) will
help us keep CanDo code up to the SchoolTool and Zope3 coding standards
while also lowering the barriers of entry for new developers and other
interested parties.
I incorporated these conventions into the tvon-refactor brach of CanDo,
however this branch also breaks CanDo out into it's own module and is
not really a practical candidate for merging into trunk at this stage in
the game.
-Tom
Coding Conventions
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
PEP 8 [1] and the Zope3 Coding Standards [2] are followed closely in
Zope3 and even more so in SchoolTool. It is a good idea to ask anyone
who might be working with CanDo code to review those two documents.
What follows is a summary of some specific issues covered in PEP 8 that
I found problems with in the CanDo code:
Blank Lines: Keep top-level function and class definitions separated
with two blank lines. Keep method definitions inside a class separated
by one blank line.
example:
---------------------------------------- bad
class Foo(object):
def one(self):
print "one"
def two(self):
print "two"
---------------------------------------- good
class Foo(object):
def one(self):
print "one"
def two(self):
print "two"
----------------------------------------
Imports: Imports should be grouped and follow a logical order. Import
groups should be separated by a blank line. A CanDo specific order to
follow is here:
1) standard library imports ('time', 're', etc)
2) related major package imports (eg, all xml package imports next)
3) zope imports
2) school[tool|bell] imports
3) local package imports
example:
----------------------------------------
import time
from persistent import Persistent
from persistent.dict import PersistentDict
from persistent.list import PersistentList
from schoolbell.app.app import PersonContainer, GroupContainer
from schoolbell.relationship import RelationshipProperty
from cando.interfaces import ICanDoContainer
----------------------------------------
Also, do not group module imports on one line unless 'from' is used:
example:
----------------------------------------bad
import time, pickle
----------------------------------------good
import time
import pickle
from Foo import Baz, Bar, Bing
----------------------------------------
Docstrings: Multi-line docstrings [3] should have the second """ on a
line by itself
example:
----------------------------------------
def foo(self, bar):
"""Foo the bar
Do something to something for some good reason.
"""
----------------------------------------
Line Width: Keep lines under 80 characters unless absolutely necessary
(eg, if it's more readable without splitting it up). You can often rely
on Python's implied line continuation to handle things inside
parenthesis and braces without having to add a slash '\'.
Misc
=3D=3D=3D=3D
* Both Vim and Emacs have ways to show whitespace. I suggest enabling
this so you can see extra whitespace at the ends of lines and even tabs
if they happen to creep into the code. For Vim this relates to the
'listchars' settings, I don't know what the corresponding setting is for
Emacs but ask in #schooltool and someone should be able to help.
* PEP 8 says to use ascii or latin-1 encoding for everything.
SchoolTool uses UTF-8 and I see no reason why CanDO shouldn't too (it
currently does so it's fine).
[1] PEP 8 - Style Guide for Python Code:
http://www.python.org/peps/pep-0008.html
[2] Zope 3 Coding Standards:
http://www.zope.org/DevHome/Wikis/DevSite/Projects/ComponentArchitecture/Co=
dingStyle
[3] PEP 257 - Docstring Conventions:
http://www.python.org/peps/pep-0257.html
|
|
From: Eldar O. <eom...@gm...> - 2005-09-21 18:45:53
|
> These changes are in the SVN trunk... O_o Did I miss something, which SVN trunk are you talking about? -Eldar |
|
From: Paul C. <pau...@gm...> - 2005-09-21 17:15:21
|
I have gotten it optimized to around 5 seconds. There is still more I can do.... expect it to be around 1 second by the time i'm finished.=20 These changes are in the SVN trunk... - Paul |