New submission from anatoly techtonik <techtonik(a)gmail.com>:
I've just noticed that my application is incompatible with Python 2.5, because ctypes.wintypes is missing SHORT constants. However, I can't find the information when these symbols were introduced first. To prevent such confusion in future it would be nice to extract symbol information for each Python release and automatically include the version of the first appearance in documentation.
----------
assignee: docs@python
components: Documentation
messages: 128893
nosy: docs@python, techtonik
priority: normal
severity: normal
status: open
title: autodocument first appearance of ctypes.wintypes constants
versions: Python 2.5, Python 2.6, Python 2.7, Python 3.1, Python 3.2, Python 3.3
_______________________________________
Python tracker <report(a)bugs.python.org>
<http://bugs.python.org/issue11253>
_______________________________________
New submission from John <jh45dev(a)gmail.com>:
A few months ago I read that in 3.2 it will be possible to import modules that are located on paths containing any unicode character. (more precisely, with chars not in the local code page)
After an hour or two trying to get this to work in 3.2rc3, I went looking for clues, and found these 2 messages in which Victor Stinner says this feature is delayed until Python 3.3:
http://bugs.python.org/issue3080#msg126514http://bugs.python.org/issue10828#msg125787
Could you please make it clear in documentation and web pages, that this feature is not working yet.
The Python 3.2 download page includes this:
"countless fixes regarding bytes/string issues; among them full support for a bytes environment (filenames, environment variables)"
and I guessed this must cover importing from any unicode path, as there was no mention that such importing had been abandoned for this version.
-- jh
----------
assignee: docs@python
components: Documentation
messages: 128711
nosy: docs@python, jh45
priority: normal
severity: normal
status: open
title: "Full unicode import system" not in 3.2
versions: Python 3.2
_______________________________________
Python tracker <report(a)bugs.python.org>
<http://bugs.python.org/issue11230>
_______________________________________
New submission from Ian <ifreecarve(a)gmail.com>:
Concerning this section of the docs:
http://docs.python.org/library/functions.html#staticmethod
There is no example for calling a static method from another static method within the same class.
As I discovered later, it's simple: C.f() -- from inside the class or outside it.
A total newbie will accept this and move on... but in other programming languages, it's frowned upon to the class name from within the class. For example, in PHP you use the "self::" prefix and Java you don't need a prefix at all.
So, even though I had it right the first time, it didn't SEEM right... so I went on a wild goose chase, for nothing. Googling "java call static method" will get you java documentation that lists both cases, as does "c++ call static method" and "php call static method".
I feel that by adding "Note: you must also use the C.f() syntax when calling from within the class", the documentation will be more complete.
----------
assignee: docs@python
components: Documentation
messages: 121314
nosy: docs@python, ifreecarve
priority: normal
severity: normal
status: open
title: list an example for calling static methods from WITHIN classes
type: feature request
_______________________________________
Python tracker <report(a)bugs.python.org>
<http://bugs.python.org/issue10438>
_______________________________________
New submission from Éric Araujo <merwok(a)netwok.org>:
Python 2 has a -b command-line option which is undocumented.
It is used by the warnings machinery to decide to warn about (-b) or raise an error (-bb) if someone uses str(bytes) or str(buffer) (explanation courtesy of grep and Python/pythonrun.c).
----------
assignee: docs@python
components: Documentation
keywords: easy
messages: 132195
nosy: docs@python, eric.araujo
priority: normal
severity: normal
stage: needs patch
status: open
title: -b option undocumented
versions: Python 2.7
_______________________________________
Python tracker <report(a)bugs.python.org>
<http://bugs.python.org/issue11681>
_______________________________________
New submission from Humberto Diogenes <humberto(a)digi.com.br>:
On some systems, datetime.strftime() accepts a %s format string that returns epoch / UNIX timestamp, but this behavior is not documented at http://docs.python.org/library/datetime.html
Python 2.7 (r27:82508, Jul 3 2010, 21:12:11)
[GCC 4.0.1 (Apple Inc. build 5493)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import datetime
>>> datetime.datetime.now().strftime('%s')
'1295376929'
----------
assignee: docs@python
components: Documentation
messages: 126481
nosy: docs@python, hdiogenes
priority: normal
severity: normal
status: open
title: Undocumented option for datetime.strftime: %s
versions: Python 2.7
_______________________________________
Python tracker <report(a)bugs.python.org>
<http://bugs.python.org/issue10938>
_______________________________________
New submission from Marc-Andre Lemburg <mal(a)egenix.com>:
Mark Shannon on python-dev:
The following API functions were removed from 3.1.3:
PyAST_Compile
PyCObject_AsVoidPtr
PyCObject_FromVoidPtr
PyCObject_FromVoidPtrAndDesc
PyCObject_GetDesc
PyCObject_Import
PyCObject_SetVoidPtr
PyCode_CheckLineNumber
Py_CompileStringFlags
PyEval_CallObject
PyOS_ascii_atof
PyOS_ascii_formatd
PyOS_ascii_strtod
PyThread_exit_prog
PyThread__PyThread_exit_prog
PyThread__PyThread_exit_thread
PyUnicode_SetDefaultEncoding
And the following were added to 3.2,
of which only 2 are documented:
PyArg_ValidateKeywordArguments
PyAST_CompileEx
Py_CompileString
Py_CompileStringExFlags
PyErr_NewExceptionWithDoc (documented)
PyErr_SyntaxLocationEx
PyErr_WarnFormat
PyFrame_GetLineNumber
PyImport_ExecCodeModuleWithPathnames
PyImport_GetMagicTag
PyLong_AsLongLongAndOverflow (documented)
PyModule_GetFilenameObject
Py_SetPath
PyStructSequence_GetItem
PyStructSequence_NewType
PyStructSequence_SetItem
PySys_AddWarnOptionUnicode
PySys_AddXOption
PySys_FormatStderr
PySys_FormatStdout
PySys_GetXOptions
PyThread_acquire_lock_timed
PyType_FromSpec
PyUnicode_AsUnicodeCopy
PyUnicode_AsWideCharString
PyUnicode_EncodeFSDefault
PyUnicode_FSDecoder
Py_UNICODE_strcat
Py_UNICODE_strncmp
Py_UNICODE_strrchr
PyUnicode_TransformDecimalToASCII
For added confusion PySys_SetArgvEx is documented as
new in 3.2, but exists in 3.1.3
Note that this only include functions.
The API also includes a number of macros such as
Py_False and Py_RETURN_FALSE, types ,
and data like PyBool_Type.
----------
assignee: docs@python
components: Documentation
messages: 128294
nosy: docs@python, lemburg
priority: normal
severity: normal
status: open
title: Undocumented public APIs in Python 3.2
versions: Python 3.2
_______________________________________
Python tracker <report(a)bugs.python.org>
<http://bugs.python.org/issue11173>
_______________________________________
New submission from STINNER Victor <victor.stinner(a)haypocalc.com>:
linecache document doesn't tell that the module reads the #coding:xxx cookie to get the encoding of the Python file. linecache reads this cookie since 41665 (May 09 2007).
"The linecache module allows one to get any line from any file, ..."
=> "any file"!
And the example uses /etc/passwd which is not a Python file.
Not only it reads the #coding:xxx cookie, but updatecache() tries also a PEP 302 loader to read the file.
linecache should be marked as very specific to Python scripts, or it should be patched to become more generic (don't read the cookie / use loader by default).
Note: the locale encoding may change between to calls to the linecache module.
----------
assignee: docs@python
components: Documentation, Library (Lib)
messages: 132641
nosy: docs@python, haypo
priority: normal
severity: normal
status: open
title: linecache becomes specific to Python scripts in Python 3
versions: Python 3.1, Python 3.2, Python 3.3
_______________________________________
Python tracker <report(a)bugs.python.org>
<http://bugs.python.org/issue11726>
_______________________________________
New submission from Larry Hastings <larry(a)hastings.org>:
The documentation for configparser.RawConfigParser.read_file() states:
"Read and parse configuration data from the file or file-like object in f (only the readline() method is used)."
This was true in Python 3.1 and before. However in 3.2 the implementation of read_file changed. It no longer calls readline(). Instead, it iterates over the file object. Whoever made this change neglected to
* fix the docs, or apparently
* tell anybody.
I've got the commit bit, so I'd be happy to fix this.
I'd like to add it to the What's New In Python 3.2 as well; there's a section about configparser changes that would be perfect. Is it permissible to change the What's New document ex post facto like this? (Adding rhettinger so he can answer this.)
----------
assignee: docs@python
components: Documentation
messages: 132075
nosy: docs@python, larry, rhettinger
priority: low
severity: normal
stage: needs patch
status: open
title: configparser read_file now iterates over f, docs still say it calls readline
type: behavior
versions: Python 3.2
_______________________________________
Python tracker <report(a)bugs.python.org>
<http://bugs.python.org/issue11670>
_______________________________________
New submission from Justin Lebar <justin.lebar(a)gmail.com>:
The readline documentation currently says:
> readline.insert_text(string)
> Insert text into the command line.
But as far as I can tell, readline.insert_text() does something only when called from startup_hook or pre_input_hook.
Here's an example of someone using the module in a way that works:
http://swapoff.org/svn/cly/tags/0.7/cly/interactive.py
----------
assignee: docs@python
components: Documentation
messages: 121178
nosy: Justin.Lebar, docs@python
priority: normal
severity: normal
status: open
title: readline.insert_text documentation incomplete
versions: Python 3.1
_______________________________________
Python tracker <report(a)bugs.python.org>
<http://bugs.python.org/issue10415>
_______________________________________
New submission from DSM <dsm001(a)users.sourceforge.net>:
Various typo fixes for the docs. As usual, I left historical documents alone (except for 3.1 whatsnew: fixed the spelling of Jack Diederich's name). Fixing ~30 means I probably introduced ~3 problems of my own, but that should still be a net win..
Patch against py3k r84944.
----------
assignee: docs@python
components: Documentation
files: typos.patch
keywords: patch
messages: 117052
nosy: docs@python, dsm001
priority: normal
severity: normal
status: open
title: doc copyedits
versions: Python 3.3
Added file: http://bugs.python.org/file18947/typos.patch
_______________________________________
Python tracker <report(a)bugs.python.org>
<http://bugs.python.org/issue9911>
_______________________________________