Clarify where the "following template" is
Reading through these docs, I was confused by the instruction to use the "following template" which wasn't followed by a template. Reading some more I realised that the template is a little further down the page. I've made this more explicit by adding a link to the template and changing the wording slightly. Change-Id: I9f5086ae8102e42a7929e1467be834b20b64440a
This commit is contained in:
parent
db287dbc05
commit
71249aeb0a
13
HACKING.rst
13
HACKING.rst
|
@ -32,7 +32,8 @@ Imports
|
||||||
- [H303] Do not use wildcard ``*`` import (*)
|
- [H303] Do not use wildcard ``*`` import (*)
|
||||||
- [H304] Do not make relative imports
|
- [H304] Do not make relative imports
|
||||||
- Order your imports by the full module path
|
- Order your imports by the full module path
|
||||||
- [H305 H306 H307] Organize your imports according to the following template
|
- [H305 H306 H307] Organize your imports according to the `Import order
|
||||||
|
template`_ and `Real-world Import Order Examples`_ below.
|
||||||
|
|
||||||
(*) exceptions are:
|
(*) exceptions are:
|
||||||
|
|
||||||
|
@ -40,7 +41,10 @@ Imports
|
||||||
- imports from ``sqlalchemy`` package
|
- imports from ``sqlalchemy`` package
|
||||||
- imports from ``oslo-incubator.openstack.common.gettextutils`` module
|
- imports from ``oslo-incubator.openstack.common.gettextutils`` module
|
||||||
|
|
||||||
Example::
|
Import order template
|
||||||
|
^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
|
::
|
||||||
|
|
||||||
{{stdlib imports in human alphabetical order}}
|
{{stdlib imports in human alphabetical order}}
|
||||||
\n
|
\n
|
||||||
|
@ -51,9 +55,8 @@ Example::
|
||||||
\n
|
\n
|
||||||
{{begin your code}}
|
{{begin your code}}
|
||||||
|
|
||||||
|
Real-world Import Order Examples
|
||||||
Human Alphabetical Order Examples
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
---------------------------------
|
|
||||||
Example::
|
Example::
|
||||||
|
|
||||||
import httplib
|
import httplib
|
||||||
|
|
Loading…
Reference in New Issue