Your message dated Thu, 20 Apr 2017 09:50:44 +0200 with message-id <20170420075044.ka6pb7oz47c7z...@gaara.hadrons.org> and subject line Re: Bug#860128: dpkg: sys.stdin.encoding is set to None in postinst has caused the Debian Bug report #860128, regarding dpkg: sys.stdin.encoding is set to None in postinst to be marked as done.
This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact ow...@bugs.debian.org immediately.) -- 860128: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=860128 Debian Bug Tracking System Contact ow...@bugs.debian.org with problems
--- Begin Message ---Package: dpkg Version: 1.18.18 Severity: normal Dear Maintainer, While packaging a python program I faced this issue. It was solve by the developer by setting 'UTF-8' as a fallback encoding when sys.stdin.encoding is None. In order to prevent this, could you please stop setting sys.stdin.encoding to None ? Traceback (most recent call last): File "/usr/share/opensvc/lib/nodemgr.py", line 101, in <module> ret = main() File "/usr/share/opensvc/lib/nodemgr.py", line 93, in main return _main(node, argv=argv) File "/usr/share/opensvc/lib/nodemgr.py", line 73, in _main err = node.action(action) File "/usr/share/opensvc/lib/node.py", line 719, in action ret = getattr(self, action)() File "/usr/share/opensvc/lib/node.py", line 1561, in set self.write_config() File "/usr/share/opensvc/lib/node.py", line 575, in write_config self.config.write(tmpf) File "/usr/share/opensvc/lib/rcConfigParser.py", line 31, in write value = value.decode(sys.stdin.encoding) TypeError: decode() argument 1 must be string, not None Regards -- System Information: Debian Release: stretch/sid APT prefers testing APT policy: (500, 'testing') Architecture: amd64 (x86_64) Kernel: Linux 4.7.0-1-amd64 (SMP w/2 CPU cores) Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) Versions of packages dpkg depends on: ii libbz2-1.0 1.0.6-8 ii libc6 2.24-8 ii liblzma5 5.2.2-1.2 ii libselinux1 2.6-3 ii tar 1.29b-1.1 ii zlib1g 1:1.2.8.dfsg-4 dpkg recommends no packages. Versions of packages dpkg suggests: ii apt 1.4~beta2 -- no debconf information -- Jean-Michel Kelbertsignature.asc
Description: PGP signature
--- End Message ---
--- Begin Message ---Hi! On Tue, 2017-04-11 at 22:56:13 +0200, Jean-Michel Kelbert wrote: > Package: dpkg > Version: 1.18.18 > Severity: normal > While packaging a python program I faced this issue. > It was solve by the developer by setting 'UTF-8' as a fallback encoding > when sys.stdin.encoding is None. In order to prevent this, could you > please stop setting sys.stdin.encoding to None ? > > Traceback (most recent call last): > File "/usr/share/opensvc/lib/nodemgr.py", line 101, in <module> > ret = main() > File "/usr/share/opensvc/lib/nodemgr.py", line 93, in main > return _main(node, argv=argv) > File "/usr/share/opensvc/lib/nodemgr.py", line 73, in _main > err = node.action(action) > File "/usr/share/opensvc/lib/node.py", line 719, in action > ret = getattr(self, action)() > File "/usr/share/opensvc/lib/node.py", line 1561, in set > self.write_config() > File "/usr/share/opensvc/lib/node.py", line 575, in write_config > self.config.write(tmpf) > File "/usr/share/opensvc/lib/rcConfigParser.py", line 31, in write > value = value.decode(sys.stdin.encoding) > TypeError: decode() argument 1 must be string, not None dpkg is not doing anything special with the standard input, this is all python-specific behavior. Which depends AFAIK, at least on the python interpreter version used (and how it treats streams and encodings), the current locale set and whether the stream is redirected or not, etc. If you need stdin to be interpreted as UTF-8, then you'll need to handle that yourself, I'm afraid. Thus closing. Thanks, Guillem
--- End Message ---