Re: Python on Windows

Discussion in 'Python' started by Marco Nawijn, Oct 16, 2012.

  1. Marco Nawijn

    Marco Nawijn Guest

    On Tuesday, October 16, 2012 1:29:23 PM UTC+2, graham wrote:
    > Downloaded and installed Python 2.7.3 for windows (an XP machine).
    >
    >
    >
    > Entered the Python interactive interpreter/command line and typed the
    >
    > following:
    >
    >
    >
    > >>>import feedparser
    >
    >
    >
    > and I get the error message "No module named feedparser".
    >
    >
    >
    > There is a feedparser.py file lurking around - so I suppose Python
    >
    > cannot find it.
    >
    >
    >
    > Anyone: What to do?
    >
    >
    >
    >
    >
    >
    >
    > GC

    Hi,

    feedparser.py is not a Python standard library. So, if it feedparser is located in a non-standard folder you have at least the following two options:
    1. Update the PYTHONPATH environment variable such that it includes the path the installation location of feedparser.py

    2. Add the path to feedparser.py directly in the script that uses it. Something like the following:
    import sys
    sys.path.append("path to feedparser.py")

    import feedparser

    Regards,

    Marco
    Marco Nawijn, Oct 16, 2012
    #1
    1. Advertising

  2. Marco Nawijn

    Dwight Hutto Guest

    On Tue, Oct 16, 2012 at 7:35 AM, Marco Nawijn <> wrote:
    > On Tuesday, October 16, 2012 1:29:23 PM UTC+2, graham wrote:
    >> Downloaded and installed Python 2.7.3 for windows (an XP machine).
    >>
    >>
    >>
    >> Entered the Python interactive interpreter/command line and typed the
    >>
    >> following:
    >>
    >>
    >>
    >> >>>import feedparser

    >>
    >>
    >>
    >> and I get the error message "No module named feedparser".
    >>
    >>


    Did you install it into the site-packages directory? Or did you cd to
    the directory it's in, and launch, or place it into the directory
    you're trying to launch it from?
    >>



    --
    Best Regards,
    David Hutto
    CEO: http://www.hitwebdevelopment.com
    Dwight Hutto, Oct 16, 2012
    #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. Achim Domma
    Replies:
    0
    Views:
    428
    Achim Domma
    Jul 19, 2003
  2. Replies:
    1
    Views:
    354
    David Fraser
    Nov 26, 2004
  3. Michael Kearns
    Replies:
    35
    Views:
    1,814
  4. Max M
    Replies:
    1
    Views:
    407
    Brandon K
    Oct 10, 2005
  5. Replies:
    8
    Views:
    630
    =?ISO-8859-1?Q?=22Martin_v=2E_L=F6wis=22?=
    Apr 11, 2007
Loading...

Share This Page