Re: Weird Problem

Discussion in 'Python' started by Peter Hansen, Aug 21, 2003.

  1. Peter Hansen

    Peter Hansen Guest

    Kris Caselden wrote:
    >
    > I'm sure this is a simple newbie problem, but I can't figure it out
    > for the life of me.
    >
    > The code:
    > import sys, os
    > input = open("example.py","r")
    >
    > Gives me the error:
    > TypeError: an integer is required


    Always post the actual code, and the *full* traceback, and
    don't just retype it: cut and paste.
    Peter Hansen, Aug 21, 2003
    #1
    1. Advertising

  2. Actually, the problem turned out to be a combination of previously
    having used "from os import *" along with not having reloaded the code
    in Pythonwin. Thanks for everyone's help.

    Peter Hansen <> wrote in message news:<>...
    > Kris Caselden wrote:
    > >
    > > I'm sure this is a simple newbie problem, but I can't figure it out
    > > for the life of me.
    > >
    > > The code:
    > > import sys, os
    > > input = open("example.py","r")
    > >
    > > Gives me the error:
    > > TypeError: an integer is required

    >
    > Always post the actual code, and the *full* traceback, and
    > don't just retype it: cut and paste.
    Kris Caselden, Aug 22, 2003
    #2
    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. dorayme
    Replies:
    1
    Views:
    618
    richard
    Jan 21, 2011
  2. richard
    Replies:
    0
    Views:
    578
    richard
    Jan 21, 2011
  3. richard
    Replies:
    0
    Views:
    613
    richard
    Jan 21, 2011
  4. Beauregard T. Shagnasty

    Re: A Weird Appearance for a Weird Site

    Beauregard T. Shagnasty, Jan 21, 2011, in forum: HTML
    Replies:
    1
    Views:
    436
    Captain Paralytic
    Jan 21, 2011
  5. will
    Replies:
    6
    Views:
    407
    Phrogz
    Dec 27, 2006
Loading...

Share This Page