Changes between Version 61 and Version 62 of DeveloperGuidelines/Py_2_3
- Timestamp:
- 07/05/19 23:23:44 (6 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
DeveloperGuidelines/Py_2_3
v61 v62 226 226 === Don't unicode.encode === 227 227 228 Since there is no difference between {{{unicode}}} and {{{str}}} , using the {{{encode()}}} method will produce {{{bytes}}} rather than {{{str}}}. A {{{bytes}}} object differs from string in that it is an array of integers rather than an array of characters. It will also give a distorted result with any later {{{str()}}} or {{{s3_str()}}}.228 Since there is no difference between {{{unicode}}} and {{{str}}} in Python-3, using the {{{encode()}}} method will produce {{{bytes}}} rather than {{{str}}}. A {{{bytes}}} object differs from string in that it is an array of integers rather than an array of characters. It will also give a distorted result with any later {{{str()}}} or {{{s3_str()}}}. 229 229 230 230 {{{#!python