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.

Author mark
Recipients mark
Date 2008-09-24.12:37:19
SpamBayes Score 2.588732e-10
Marked as misclassified No
Message-id <1222259902.44.0.148184723221.issue3955@psf.upfronthosting.co.za>
In-reply-to
Content
# This program works fine with Python 2.5 and 2.6:
def f():
    """
    >>> f()
    'xyz'
    """
    return "xyz"

if __name__ == "__main__":
    import doctest
    doctest.testmod()


But if you put the statement "from __future__ import unicode_literals"
at the start then it fails:
File "/tmp/test.py", line 5, in __main__.f
Failed example:
    f()
Expected:
    'xyz'
Got:
    u'xyz'

I don't know if it is a bug or a feature but I didn't see any mention of
it in the bugs or docs so thought I'd mention it.
History
Date User Action Args
2008-09-24 12:38:22marksetrecipients: + mark
2008-09-24 12:38:22marksetmessageid: <1222259902.44.0.148184723221.issue3955@psf.upfronthosting.co.za>
2008-09-24 12:37:19marklinkissue3955 messages
2008-09-24 12:37:19markcreate