0

I am using Eclipse with PyDev and Python 3.4.1. I would like to try the curses lib included with Python. I have read the documentation for Python 3.4.1 and the tutorial there gives the code:

import curses
stdscr = curses.initscr()

However, I am getting this error:

Traceback (most recent call last):

File "D:\Programming\Eclipse Standard IDE\Projects\LCD Display\src\main.py", line 9, in import curses File "D:\Programming\Python 3.4.1\Lib\curses__init__.py", line 13, in from _curses import * ImportError: No module named '_curses'

In the curses lib file the first line is from _curses import *.

  1. What should I make of this?
  2. Is this an error in the lib file or is this for legacy support?
  3. How can I fix this?

EDIT: I've tried switching interpreters to the Pythonw.exe (3.4.1) to no avail and the 2.7.8 does not work either. I believe I have already set up PyDev properly (according to the website).

Joran Beasley
  • 110,522
  • 12
  • 160
  • 179
Klik
  • 1,757
  • 1
  • 21
  • 38
  • 3
    you need ncurses windows package ... it does not come bundled with the dll for curses ... which unfortunately only exists in gnuwin32 which may or may not be usable by python... basically on windows curses is a nightmare ... it just works on pretty much any other os ... but its a pain on windows ... if you do get a working dll make sure you put it in your `C:\windows\system32` folder – Joran Beasley Jul 07 '14 at 22:56
  • @JoranBeasley So basically it's incredibly outdated and not worth the time in learning? – Klik Jul 07 '14 at 23:04
  • 1
    no that is not quite what I said ... better put is that for whatever reason it is very hard to use with windows, and is likely not worth the overhead of getting it setup ... it is much easier to use something like wx and make a real gui program .... unless you just really really really wanna make a console based UI ... in which case it is probably easiest to run a Ubuntu virtual box and use that to develope and accept that it will likely never run on windows – Joran Beasley Jul 07 '14 at 23:07
  • @JoranBeasley Great, I'll check out wx. I appreciate the advice. It's my first day with Python, so I'm trying to get my hands a little dirty and I'd rather be getting some programming practice than wasting my time trying to go through a setup. – Klik Jul 07 '14 at 23:38
  • jumping right into gui devel may be a bit daunting .... why dont you do the django tutorial on setting up a blog ... that is a little more straight forward and ends up being sort of a primer on python ... that said you certainly could setup a gui first ... you just might struggle with some of the concepts that may not be related to python at all (like not blocking your ui) – Joran Beasley Jul 07 '14 at 23:49

0 Answers0