This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

作者 vstinner
收信人 Arfrever, ezio.melotti, gregory.p.smith, lemburg, loewis, vstinner
日期 2010-04-26.10:37:58
SpamBayes Score 1.2612153e-06
Marked as misclassified
Message-id <1272278280.43.0.421714122935.issue8514@psf.upfronthosting.co.za>
In-reply-to
内容
> They're also useful for dealing with environment variables 
> which are not strictly filesystem (fs) related but also suffer 
> from the same issue requiring surrogate escape.

Yes, Python3 decodes environment variables using sys.getfilesystemencoding()+surrogateescape. And since my last fix on os.execve(), subprocess (and os.execv(p)e) uses also surrogateescape to encode environment variables.

And yes again, I also patched os.getenv() to decode bytes name to unicode using sys.getfilesystemencoding()+surrogateescape.

> But other than just calling these os.encode and os.decode

*fs*encode() and *fs*decode() is a reference to the encoding: sys.get*filesystem*encoding().

> I just wanted to point the other use out

See also issue #8513.
历史
日期 用户 动作 参数
2010-04-26 10:38:00vstinner修改recipients: + vstinner, lemburg, loewis, gregory.p.smith, ezio.melotti, Arfrever
2010-04-26 10:38:00vstinner修改messageid: <1272278280.43.0.421714122935.issue8514@psf.upfronthosting.co.za>
2010-04-26 10:37:59vstinner链接issue8514 messages
2010-04-26 10:37:59vstinner创建