A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2008-April/078963.html below:

[Python-Dev] socket.try_reuse_address()

[Python-Dev] socket.try_reuse_address() [Python-Dev] socket.try_reuse_address()Raghuram Devarakonda draghuram at gmail.com
Wed Apr 30 20:22:49 CEST 2008
On Wed, Apr 30, 2008 at 2:07 PM, Trent Nelson <tnelson at onresolve.com> wrote:
>
>  > This one will not work.
>  >
>  > >>> 'windows' in System.getProperty('os.name').lower()
>  > Traceback (innermost last):
>  >   File "<console>", line 1, in ?
>  > TypeError: string member test needs char left operand
>  > >>>
>
>  Interesting, which version of Jython were you using?

2.1. Now that you mentioned it, I tested with 2.2 and your code works there.

>  > You may have to do something like
>  > System.getProperty('os.name').lower().find('windows').
>
>  That didn't work for me.  I assume the following works for you:
>
>         System.getProperty('os.name').lower().startswith('windows')

It does.
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4