summaryrefslogtreecommitdiff
path: root/HACKING.rst
diff options
context:
space:
mode:
authorStephen Finucane <sfinucan@redhat.com>2020-02-21 09:56:37 +0000
committerStephen Finucane <sfinucan@redhat.com>2020-02-21 09:56:37 +0000
commitb9a7e03074cbaacc3f270b2b8228a5b85350a2de (patch)
tree0542e32065b3f54624918c95d3d9a05b2c2da311 /HACKING.rst
parent8f50f84981f354e0dbac0af843d7d936c319b77f (diff)
downloadpython-novaclient-b9a7e03074cbaacc3f270b2b8228a5b85350a2de.tar.gz
Random cleanups
Remove some cruft from Sphinx config files, drop the use of 'u' prefixed strings, which are unnecessary in Python 3, and generally tidy stuff up. Change-Id: Ib0f33576e160ec842d7fc82b4fcfee99829623d7 Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
Diffstat (limited to 'HACKING.rst')
-rw-r--r--HACKING.rst30
1 files changed, 6 insertions, 24 deletions
diff --git a/HACKING.rst b/HACKING.rst
index 5a5d01d7..b5653449 100644
--- a/HACKING.rst
+++ b/HACKING.rst
@@ -5,30 +5,12 @@ Nova Client Style Commandments
https://docs.openstack.org/hacking/latest
- Step 2: Read on
-
Nova Client Specific Commandments
---------------------------------
None so far
Text encoding
-------------
-- All text within python code should be of type 'unicode'.
-
- WRONG:
-
- >>> s = 'foo'
- >>> s
- 'foo'
- >>> type(s)
- <type 'str'>
-
- RIGHT:
-
- >>> u = u'foo'
- >>> u
- u'foo'
- >>> type(u)
- <type 'unicode'>
- Transitions between internal unicode and external strings should always
be immediately and explicitly encoded or decoded.
@@ -36,13 +18,13 @@ Text encoding
- All external text that is not explicitly encoded (database storage,
commandline arguments, etc.) should be presumed to be encoded as utf-8.
- WRONG:
+ Wrong::
mystring = infile.readline()
myreturnstring = do_some_magic_with(mystring)
outfile.write(myreturnstring)
- RIGHT:
+ Right::
mystring = infile.readline()
mytext = s.decode('utf-8')
@@ -52,8 +34,8 @@ Text encoding
Running Tests
-------------
-The testing system is based on a combination of tox and testr. If you just
-want to run the whole suite, run `tox` and all will be fine. However, if
+
+The testing system is based on a combination of tox and stestr. If you just
+want to run the whole suite, run ``tox`` and all will be fine. However, if
you'd like to dig in a bit more, you might want to learn some things about
-testr itself. A basic walkthrough for OpenStack can be found at
-http://wiki.openstack.org/testr
+stestr itself.