~gandelman-a/ubuntu/precise/keystone/UCA_2012.2.1

« back to all changes in this revision

Viewing changes to HACKING.rst

  • Committer: Package Import Robot
  • Author(s): Chuck Short, Adam Gandelman, Soren Hansen, Logan Rosen, Chuck Short
  • Date: 2012-09-07 13:04:01 UTC
  • mfrom: (1.1.22)
  • Revision ID: package-import@ubuntu.com-20120907130401-o49wh9xxkr2cmuqx
Tags: 2012.2~rc1~20120906.2517-0ubuntu2
[ Adam Gandelman ]
* Refreshed patches.

[ Soren Hansen ]
* Update debian/watch to account for symbolically named tarballs and
  use newer URL.
* Fix Launchpad URLs in debian/watch.

[ Logan Rosen ]
* Fix control file to suggest python-memcache instead of python-memcached
  (LP: #998991).

[ Chuck Short ]
* New upstream version.
* Dont FTBFS if the testsuite fails.

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
- Include your name with TODOs as in "#TODO(termie)"
16
16
- Do not name anything the same name as a built-in or reserved word
17
17
- When defining global constants, define them before functions and classes
 
18
- Avoid using "double quotes" where you can reasonably use 'single quotes'
18
19
 
19
20
 
20
21
TODO vs FIXME
25
26
- FIXME(name): implies that the method/function/etc shouldn't be used until
26
27
  that code is resolved and bug fixed.
27
28
 
 
29
 
28
30
Logging
29
31
-------
30
32
 
36
38
 
37
39
    LOG.debug('Foobar')
38
40
 
 
41
 
39
42
Imports
40
43
-------
41
44
 
48
51
Example::
49
52
 
50
53
  # vim: tabstop=4 shiftwidth=4 softtabstop=4
51
 
  {{stdlib imports in human alphabetical order}}
52
 
  \n
53
 
  {{third-party lib imports in human alphabetical order}}
54
 
  \n
55
 
  {{nova imports in human alphabetical order}}
 
54
  {{stdlib imports ordered by full module path}}
 
55
  \n
 
56
  {{third-party lib imports ordered by full module path}}
 
57
  \n
 
58
  {{nova imports ordered by full module path}}
56
59
  \n
57
60
  \n
58
61
  {{begin your code}}
59
62
 
60
63
 
61
 
Human Alphabetical Order Examples
62
 
---------------------------------
 
64
Import by Full Module Path Examples
 
65
-----------------------------------
63
66
 
64
67
Example::
65
68
 
73
76
  import eventlet
74
77
  import webob.exc
75
78
 
76
 
  from nova import test
77
 
  from nova import utils
 
79
  import nova.api.ec2
78
80
  from nova.api import openstack
79
81
  from nova.auth import ldap
80
82
  from nova.auth import users
81
83
  from nova.endpoint import cloud
82
84
  import nova.flags
83
 
  import nova.api.ec2
 
85
  from nova import test
 
86
  from nova import utils
84
87
 
85
88
 
86
89
Docstrings