"Frank Millman" writes:
> "Steven D'Aprano" wrote in message
> news:53ce0b96$0$29897$c3e8da3$54964...@news.astraweb.com...
>> On Tue, 22 Jul 2014 08:18:08 +0200, Frank Millman wrote:
>>
>>> This is not important, but I would appreciate it if someone could
>>> explain the following, run from cmd
On 7/22/2014 2:18 AM, Frank Millman wrote:
Hi all
This is not important, but I would appreciate it if someone could explain
the following, run from cmd.exe on Windows Server 2003 -
C:\>python
Python 3.4.1 (v3.4.1:c0e311e010fc, May 18 2014, 10:38:22) [MSC v.1600 32 bit
(In
tel)] on win32
Type "h
"Peter Otten" <__pete...@web.de> wrote in message
news:lql9oi$hlt$1...@ger.gmane.org...
> Frank Millman wrote:
>
[...]
>
>> Out of interest, does the same thing happen when writing to sys.stderr?
>
> If you are asking about the fallback mechanism, that is specific to
> sys.displayhook in the inte
Frank Millman wrote:
>
> "Peter Otten" <__pete...@web.de> wrote in message
> news:lql3am$2q7$1...@ger.gmane.org...
>> Frank Millman wrote:
>>
>>> Hi all
>>>
>>> This is not important, but I would appreciate it if someone could
>>> explain the following, run from cmd.exe on Windows Server 2003 -
>
"Peter Otten" <__pete...@web.de> wrote in message
news:lql3am$2q7$1...@ger.gmane.org...
> Frank Millman wrote:
>
>> Hi all
>>
>> This is not important, but I would appreciate it if someone could explain
>> the following, run from cmd.exe on Windows Server 2003 -
>>
>> C:\>python
>> Python 3.4.1 (
Peter Otten <__pete...@web.de> writes:
> No, both print to stdout, but just
>
x
>
> is passed to the display hook of the interactive interpreter. This applies
> repr() and then tries to print the result. If this fails it makes another
> effort, roughly (the actual code is written in C)
>
>
"Lele Gaifax" wrote in message
news:87d2cx271o.fsf@nautilus.nautilus...
> "Frank Millman" writes:
>
>>> No, both statements actually emit noise on the standard output, but the
>>> former prints the *repr* of the string, the latter tries to encode it to
>>> CP437, which you console seems to be u
"Frank Millman" writes:
> "Steven D'Aprano" wrote in message
> news:53ce0b96$0$29897$c3e8da3$54964...@news.astraweb.com...
>> I would be surprised if that were the case, but I don't have a Windows
>> box to test it. Try this:
>>
>>
>> import sys
>> print(x, file=sys.stderr) # I expect this wil
"Frank Millman" writes:
>> No, both statements actually emit noise on the standard output, but the
>> former prints the *repr* of the string, the latter tries to encode it to
>> CP437, which you console seems to be using.
>>
>
> Thanks, Lele, but I don't think that is quite right - see my separat
Frank Millman wrote:
> Hi all
>
> This is not important, but I would appreciate it if someone could explain
> the following, run from cmd.exe on Windows Server 2003 -
>
> C:\>python
> Python 3.4.1 (v3.4.1:c0e311e010fc, May 18 2014, 10:38:22) [MSC v.1600 32
> bit (In
> tel)] on win32
> Type "help
"Steven D'Aprano" wrote in message
news:53ce0b96$0$29897$c3e8da3$54964...@news.astraweb.com...
> On Tue, 22 Jul 2014 08:18:08 +0200, Frank Millman wrote:
>
>> Hi all
>>
>> This is not important, but I would appreciate it if someone could
>> explain the following, run from cmd.exe on Windows Serv
"Lele Gaifax" wrote in message
news:87lhrl28ie.fsf@nautilus.nautilus...
> "Frank Millman" writes:
>
>> Python 3.4.1 (v3.4.1:c0e311e010fc, May 18 2014, 10:38:22) [MSC v.1600 32
>> bit
>> (In
>> tel)] on win32
>> Type "help", "copyright", "credits" or "license" for more information.
> x = '\
On Tue, 22 Jul 2014 08:18:08 +0200, Frank Millman wrote:
> Hi all
>
> This is not important, but I would appreciate it if someone could
> explain the following, run from cmd.exe on Windows Server 2003 -
>
> C:\>python
> Python 3.4.1 (v3.4.1:c0e311e010fc, May 18 2014, 10:38:22) [MSC v.1600 32
> b
"Frank Millman" writes:
> Python 3.4.1 (v3.4.1:c0e311e010fc, May 18 2014, 10:38:22) [MSC v.1600 32 bit
> (In
> tel)] on win32
> Type "help", "copyright", "credits" or "license" for more information.
x = '\u2119'
x # this uses stderr
> '\u2119'
print(x) # this uses stdout
> Trace
Hi all
This is not important, but I would appreciate it if someone could explain
the following, run from cmd.exe on Windows Server 2003 -
C:\>python
Python 3.4.1 (v3.4.1:c0e311e010fc, May 18 2014, 10:38:22) [MSC v.1600 32 bit
(In
tel)] on win32
Type "help", "copyright", "credits" or "license" f
15 matches
Mail list logo