[issue8981] _struct.__version__ should be string, not bytes

Alexander Belopolsky report at bugs.python.org
Sat Jun 12 06:48:48 CEST 2010


New submission from Alexander Belopolsky <belopolsky at users.sourceforge.net>:

>>> import _struct
>>> _struct.__version__
b'0.3'

I would rather simply remove this since it is no longer exposed in struct.

Yes, it does cause problems in real life code: I have applications that keep track of versions of modules that they use and expect __version__ to be string if defined.

Same problem in _curses, but I have never used that module - just grepped the sources.

----------
components: Extension Modules
keywords: easy
messages: 107627
nosy: belopolsky, mark.dickinson
priority: normal
severity: normal
status: open
title: _struct.__version__ should be string, not bytes
type: behavior
versions: Python 3.2

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue8981>
_______________________________________


More information about the Python-bugs-list mailing list