IDLE; Pythonwin and windows network drives

Discussion in 'Python' started by Tuure Laurinolli, Jul 1, 2004.

  1. Some time ago I was playing with the idea of using an actual IDE to
    write my python code. I first played with IDLE, but noticed that it was
    kind of limited and for some reason it worked extremely slowly when
    started from a shortcut on desktop(not so when started from shortcut in
    start menu).

    Then I tried Pythonwin and noticed that it didn't provide any
    indentation help at all - to my surprise. I discarded the idea of using
    it, but for some reason tried it again later - only to find indentation
    working just fine.

    A bit of research revealed that the problem was caused by opening a file
    residing on a network drive. How strange.

    Some more research and the problem became apparent. When python opened
    the file and windows code took over python code, it silently changed the
    locale to "the right locale", which happens to use , as decimal
    delimiter instead of the "standard" . So when pythonwin(or IDLE, they
    use the same indentation code) tried to convert a string into float into
    int in order to find the line I was on(strange Tkinter stuff), it
    promptly raised an exception because "19.3" obviously wasn't a float -
    it contained strange characters!

    A dive into python source shows that when python locale is normally set
    through appropriate module, it preserves the LC_NUMEERIC locale as the
    standard C to ensure correct handling of floating point values and only
    sets the user-defined locale for the module-specific functions that
    actually make use of it(and resets it back to C-locale whenever user
    changes the locale).

    Also, Pythonwin and IDLE must use some truly wondrous way to open files
    which triggers this behavior, standard open() didn't change anything.

    Forgive any mad-rambling-like qualities of this post, It's late (or
    early, if you will), and I'm nearly asleep already.
    Tuure Laurinolli, Jul 1, 2004
    #1
    1. Advertising

  2. Tuure Laurinolli

    Peter Maas Guest

    Tuure Laurinolli schrieb:
    > Then I tried Pythonwin and noticed that it didn't provide any
    > indentation help at all - to my surprise. I discarded the idea of using
    > it, but for some reason tried it again later - only to find indentation
    > working just fine.


    There seem to be some issues with Pythonwin and network drives / UNC paths.
    I observed recently that the install of pythonwin (build 201) failed with
    a "freopen stderr" message. After moving the setup exe from an UNC path
    to a local path everything worked fine. That happened on my Win2k/SP4
    machine and the UNC path was on a Samba 3.0.4 server.

    Mit freundlichen Gruessen,

    Peter Maas

    --
    -------------------------------------------------------------------
    Peter Maas, M+R Infosysteme, D-52070 Aachen, Tel +49-241-93878-0
    eMail 'cGV0ZXIubWFhc0BtcGx1c3IuZGU=\n'.decode('base64')
    -------------------------------------------------------------------
    Peter Maas, Jul 1, 2004
    #2
    1. Advertising

  3. Peter Maas <> writes:

    > There seem to be some issues with Pythonwin and network drives / UNC paths.
    > I observed recently that the install of pythonwin (build 201) failed with
    > a "freopen stderr" message. After moving the setup exe from an UNC path
    > to a local path everything worked fine. That happened on my Win2k/SP4
    > machine and the UNC path was on a Samba 3.0.4 server.


    That would probably be a bug in the bdist_wininst installer, but I
    cannot reproduce it. Although I can only test with my WinXP machine,
    and UNC paths on Windows servers.

    Can you or anyone else reproduce what you describe?

    Thomas
    Thomas Heller, Jul 1, 2004
    #3
  4. Tuure Laurinolli

    David Fraser Guest

    Thomas Heller wrote:
    > Peter Maas <> writes:
    >
    >
    >>There seem to be some issues with Pythonwin and network drives / UNC paths.
    >>I observed recently that the install of pythonwin (build 201) failed with
    >>a "freopen stderr" message. After moving the setup exe from an UNC path
    >>to a local path everything worked fine. That happened on my Win2k/SP4
    >>machine and the UNC path was on a Samba 3.0.4 server.

    >
    >
    > That would probably be a bug in the bdist_wininst installer, but I
    > cannot reproduce it. Although I can only test with my WinXP machine,
    > and UNC paths on Windows servers.
    >
    > Can you or anyone else reproduce what you describe?
    >


    I have had this bug, I think it may be related to reinstalling pythonwin
    on top of intself. I had it on Win2k, also installing from a samba server.

    David
    David Fraser, Jul 1, 2004
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?UHJhZGVlcCBTdW5kYXJhbShNU0ZUKQ==?=

    Enumerate all the drives including Mapped network drives on a serv

    =?Utf-8?B?UHJhZGVlcCBTdW5kYXJhbShNU0ZUKQ==?=, Feb 25, 2005, in forum: ASP .Net
    Replies:
    2
    Views:
    1,030
    =?Utf-8?B?UHJhZGVlcCBTdW5kYXJhbShNU0ZUKQ==?=
    Feb 26, 2005
  2. kalbee
    Replies:
    2
    Views:
    374
    steph
    Oct 12, 2004
  3. stephan
    Replies:
    0
    Views:
    434
    stephan
    Jul 30, 2003
  4. Read Roberts
    Replies:
    0
    Views:
    346
    Read Roberts
    Dec 22, 2004
  5. David S.
    Replies:
    0
    Views:
    420
    David S.
    Feb 16, 2005
Loading...

Share This Page