By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
444,089 Members | 2,432 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 444,089 IT Pros & Developers. It's quick & easy.

curses is not imported under Linux (and Python 2.4)

P: n/a
import curses
produces the ImportError: No module named _curses
("from _curses import *" in line 15 in __init__.py)
Of course imp.find_module ("_curses") reports the same error.
How can I make use of the curses package for writing a Python script
with curses?
Jul 18 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Konrad Koller wrote:
import curses
produces the ImportError: No module named _curses
("from _curses import *" in line 15 in __init__.py)
Of course imp.find_module ("_curses") reports the same error.
How can I make use of the curses package for writing a Python script
with curses?


I get the same thing under Windows: _curses is the compiled extension
supporting the curses library, so I must presume that isn't supported by
default on Windows.

No problems under Cygwin or on Linux.

Googling for "python curses windows" might provide a few pointers.

regards
Steve
--
Steve Holden http://www.holdenweb.com/
Python Web Programming http://pydish.holdenweb.com/
Holden Web LLC +1 703 861 4237 +1 800 494 3119
Jul 18 '05 #2

P: n/a
On Fri, 2005-01-07 at 00:38, Konrad Koller wrote:
import curses
produces the ImportError: No module named _curses
("from _curses import *" in line 15 in __init__.py)
Of course imp.find_module ("_curses") reports the same error.
How can I make use of the curses package for writing a Python script
with curses?


What Linux distro?
Is the Python version you're running one you compiled, one that shipped
with the distro, or a 3rd party RPM?

At a guess, I'd say you compiled it yourself and you don't have the
ncurses development packages (providing the ncurses header files and
static libs) installed.

--
Craig Ringer

Jul 18 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.