[New-bugs-announce] [issue41190] msilib: SetProperty() accepts str, but GetProperty() returns bytes

Serhiy Storchaka report at bugs.python.org
Wed Jul 1 14:15:29 EDT 2020


New submission from Serhiy Storchaka <storchaka+cpython at gmail.com>:

There is an inconsistency in the _msi.SummaryInformation class. Its method SetProperty() accepts str, but GetProperty() returns bytes (encoded with the Windows ANSI encoding).

Since os.fsencode()/os.fsdecode() now use UTF-8 encoding, it is not so easy to convert between bytes and str. Also, the encoding with the Windows ANSI encoding is lossy, so it may be that there is a loss in GetProperty().

----------
components: Windows
messages: 372777
nosy: paul.moore, serhiy.storchaka, steve.dower, tim.golden, zach.ware
priority: normal
severity: normal
status: open
title: msilib: SetProperty() accepts str, but GetProperty() returns bytes
type: behavior

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue41190>
_______________________________________


More information about the New-bugs-announce mailing list