New User? Register here - Existing Users: Username: Password: [Advanced Login]

 

 

Current Poll

Your preferred Interactive shell?









( 1355 votes ~ 14 comments )

 

Weblog entry #41 for dkg

Python editor/IDE for new (high school) coders?
Posted by dkg on Wed 4 Feb 2009 at 19:56
I'm supporting a class of high school students who are new to programming, and will be learning some python. Most of these students are comfortable with computers, but not hacker types, and few if any of them have written code before.

I'm looking for an editor or an Integrated Development Environment (IDE) that won't be too scary for them, and will help them get used to the novel idea of writing code without simultaneously having to get used to the novel idea of an unfamiliar user interface.

So i can't expect them to pick up my beloved emacs, for example. But on the other end of the spectrum, i'd hate for them to try to write python in an word processor (i've seen people do it!). Here's what i think i'm looking for:

  • comfortable graphical interface -- these students have not used the command line before, and while they'll be introduced to the python shell, they should be able to write code and browse for files, etc. in the "normal" (sigh) way. This means, for instance, that tk-based interfaces are less good because they don't integrate with the common GTK-based UI.
  • syntax highlighting -- the students will need to figure out what's a variable, what's a function name, what's an operator, what's a reserved word, etc. Visual indications like font-lock-mode from emacs would be really useful.
  • whitespace management -- since python has syntactic whitespace, it would be great if there were convenient/intuitive ways for students to adjust the whitespace in their programs. Of course, it's hard to say what's going to be intuitive for other people. I like tab-cycling whitespace myself; are there other approaches i should be proposing?
Do you have suggestions for tools that work well for the above needs? Favorites? Are there features other than the "top three" i listed above that you think i should pay attention to?

FWIW, they'll be working in a labful of machines running Ubuntu Hardy for the most part, but i'm willing to port and deploy programs (particularly ones that feel like a perfect fit) if they're not available in hardy.

 

Comments on this Entry

Posted by Anonymous (213.17.xx.xx) on Wed 4 Feb 2009 at 20:20
Geany would be a good option I think. Besides being gtk2, offering code highlighting and the possibility to set tabs/spacing indents to your liking it has:
Namespace browser (or whatever you'd call it): a sidepanel with a list of classes, methods and functions in the file.
Built in shell: have a ipython shell and the python file open right on top of each other.
'Run' button in the toolbar to run the program.

[ Parent | Reply to this comment ]

Posted by Anonymous (75.57.xx.xx) on Mon 16 Feb 2009 at 21:34
Definitely Geany. It is easy, neat, has cool features like completion, handles whitespace well. Available in Hardy, and updated debs available widely to install the newer versions if I remember correctly.

Also runs on windows with a little work.

Very easy to learn, customize, and use plugins.

[ Parent | Reply to this comment ]

Posted by Anonymous (217.216.xx.xx) on Wed 4 Feb 2009 at 20:43
Ready for use in Debian:

* SPE (Stani's Python Editor).

Spe is a Python IDE with auto-indentation, auto completion, call tips, syntax coloring, syntax highlighting, UML viewer, class explorer, source index, auto todo list, sticky notes, integrated pycrust shell, Python file browser, recent file browser, drag&drop, context help, ... Special is its Blender support with a Blender 3d object browser and its ability to run interactively inside blender. Spe ships with wxGlade & XRCed (gui designers), PyChecker (source code doctor) and Kiki (regular expression console). Spe is extensible with wxGlade.

* PIDA (Python Integrated Development Application).

PIDA is the Python Integrated Development Application. It is an IDE (integrated development environment) written in Python (http://www.python.org/) and the GTK+ (http://www.pygtk.org/) graphical toolkit.

Pida is an IDE, but one that is slightly different from other IDEs. Rather than attempting to write a set of development tools of its own, Pida uses tools that the developer has available. In this regards Pida can be used as a framework for putting together your own bespoke IDE.

Although still a young application, Pida can already boast a huge number of features because of the power of some of the tools it integrates. For example features such as code completion and syntax highlighting are well implemented in Pida's integrated editors far better than any editor built for a commercial IDE. Pida currently features: Full code editing (syntax highlighting, code completion, automatic indenting, block commenting etc) Project management, version control management, Python debugger and profiler, GTK+ graphical user interface building and rapid application design, Pastebin integration.

* Kate, if you don't want to scare your students with Emacs ;)

[ Parent | Reply to this comment ]

Posted by mlc (24.186.xx.xx) on Wed 4 Feb 2009 at 20:49
[ Send Message ]

It's Java, not Python, but BlueJ is a really nice UI for learning coders. I don't know if there is anything similar for Python or any other languages.

[ Parent | Reply to this comment ]

Posted by Anonymous (84.76.xx.xx) on Wed 4 Feb 2009 at 20:52
Netbeans has recently grown support for python. It's not as heavyweight as Eclipse (pydev) but still very powerful.

[ Parent | Reply to this comment ]

Posted by Anonymous (192.146.xx.xx) on Wed 4 Feb 2009 at 21:02
Komodo Edit is a pretty nice IDE. You could always use IDLE too.

[ Parent | Reply to this comment ]

Posted by Anonymous (213.112.xx.xx) on Wed 4 Feb 2009 at 21:51
Scite is very nice, it uses the standard gtk2 dialogs. It integrates nicely with python, just save your file as .py and press F5 to run it, no magic shebang or chmodding needed. If you get an error you can just dubbleclick on the error and it jumps to the right place in the code.

It also work in windows so the students can use it while they are home, if the don't run linux.

[ Parent | Reply to this comment ]

Posted by Anonymous (79.138.xx.xx) on Wed 4 Feb 2009 at 22:23
I would go for PyDev (Eclipse plugin). Syntax highlighting, clever code completion and some refactoring tools. All working very nicely and stable
http://pydev.sourceforge.net/

Emacs + rope http://rope.sourceforge.net/ropemacs.html gives an equivalent set of features, it's is not as pretty as PyDev. Flymake works great with python in Emacs (uses pylint just like pydev can)

[ Parent | Reply to this comment ]

Posted by Anonymous (66.114.xx.xx) on Wed 4 Feb 2009 at 22:48
I'm surprised nobody has said this yet. I bet you're looking for drpython.

[ Parent | Reply to this comment ]

Posted by Anonymous (83.42.xx.xx) on Thu 5 Feb 2009 at 00:19

[ Parent | Reply to this comment ]

Posted by schmichael (76.115.xx.xx) on Thu 5 Feb 2009 at 03:52
[ Send Message ]
There have been lots of good suggestions already, so I'll stick to making a related suggestion:

Make sure the IDE has a simple Windows installer. A "portable" version that can run from a flash drive is even better.

While these features mean nothing to me personally, I've worked with high school students before and they're quite often forced into Windows-only environments. If not at school, then at home, or at friends' homes. In my experience it doesn't take much friction to cause a high school student to just say: "Forget it. This is too much work."

[ Parent | Reply to this comment ]

Posted by Anonymous (217.216.xx.xx) on Thu 5 Feb 2009 at 05:42
For windows-only users (may $deity forgive them) there is pyscripter:

http://code.google.com/p/pyscripter/

[ Parent | Reply to this comment ]

Posted by Anonymous (2a01:0xx:0xx:0xxx:0xxx:0xxx:xx) on Thu 5 Feb 2009 at 09:23
I'm using Wing IDE for professonial work. They give free license for educational.
You can use Boa too.

[ Parent | Reply to this comment ]

Posted by Anonymous (87.17.xx.xx) on Thu 5 Feb 2009 at 09:48
Ulipad is great. Try it

[ Parent | Reply to this comment ]

Posted by daemon (146.231.xx.xx) on Thu 5 Feb 2009 at 12:20
[ Send Message | View Weblogs ]

C a n ' t . . . r e s i s t . . . u r g e . . . ..

gVim?

That really doesn't help I know, but hell, it does a great job, truly it does.

I also can't work out why no-one's mentioned Eric yet? (I suppose because it's Qt based?)

Cheers.
:wq

[ Parent | Reply to this comment ]

Posted by Anonymous (79.44.xx.xx) on Thu 5 Feb 2009 at 13:54
I'd say to simply use gedit, the default gnome text editor (it just requires gtk, not full gnome and it also runs on windows)
- it's in gtk
- it's simple and has a familiar UI
- it has a good syntax highlight
- with a few plugins you can suggest to the students it can become a very powerful python ide
- it is scriptable in python itself!

[ Parent | Reply to this comment ]

Posted by dkg (216.254.xx.xx) on Thu 5 Feb 2009 at 15:09
[ Send Message | View dkg's Scratchpad | View Weblogs ]
Thanks, i didn't realize that gedit had syntax highlighting. that's good to know.

can you suggest the plugins that you think make it into powerful python IDE? I've never tried to set up gedit for that purpose.

[ Parent | Reply to this comment ]

Posted by Anonymous (79.44.xx.xx) on Sun 8 Feb 2009 at 13:27
as part of the default gedit tarball there are some very useful plugins, in particular the filebrowser sidepane, "external tools" that allows to run scripts and "snippets" which provide a powerful keyword-expansion framework (e.f. type "if<tab>" and get a if block where you can cicle through the positions). There is also a pythonconsole plugin which embeds a python console in gedit.

Apart from that the gedit-plugins debian package includes other useful plugins as codecomment, drawspaces etc

and then there are third party plugins listed on live.gnome.org/Gedit/Plugins, some of which are specific to python

[ Parent | Reply to this comment ]

Posted by Anonymous (193.235.xx.xx) on Thu 5 Feb 2009 at 15:21
I believe anybody with an open mind could pick up emacs with ease and without an open mind you really shouldn't take any programming class.

[ Parent | Reply to this comment ]

Posted by dkg (216.254.xx.xx) on Thu 5 Feb 2009 at 15:47
[ Send Message | View dkg's Scratchpad | View Weblogs ]
I realize that "High School students" is probably jargon specific to the USA. I should clarify -- I'm talking about students aged 13 to 18 here.

If you really think that people that age only need an open mind to pick up emacs with ease, i'd love to get to work with whatever students you're working with. In my experience, high school students have a ton of other things competing for their mental energy: figuring out how to be adults in a society that demands responsibility while withholding rights; navigating the shifting social dynamic of their peers; learning far more four years than many people learn afterwards; trying to stay in school in the face of pressures to drop out and get a job; dealing with unreasonable parents; and so on. Not to mention their other (non-programming) classes!

I grant that there are a few kids with the life stability and focus and interest and time and open mind that it would take to get them learning emacs. But even for those kids, it isn't necessarily done "with ease". Let's face it, emacs is a complete change from "the way most people use computers". It's real work to learn an unfamiliar tool and the learning curve on emacs is intimidating for folks raised in a GUI environment. I say this as a die-hard emacs user, btw. I will happily support kids who want to learn emacs, and i think it is a wonderful environment for all kinds of things. But i want to provide a smoother path into coding for those who aren't going to be able to pick up emacs over the next year.

[ Parent | Reply to this comment ]

Posted by Anonymous (209.91.xx.xx) on Thu 5 Feb 2009 at 16:37
Loved your commments about high school students - bet you make a great teacher. So many people seem to have no idea what it's like to be one - even though they were one!

[ Parent | Reply to this comment ]

Posted by Anonymous (167.7.xx.xx) on Thu 5 Feb 2009 at 15:55
I use Anjuta for all my light coding. I think it would be a great little program for developing Python. ..plus it is a part of the Gnome Development Enviroment..so a great start!

[ Parent | Reply to this comment ]

Posted by mjgoins (24.89.xx.xx) on Sat 7 Feb 2009 at 03:45
[ Send Message ]
After giving drpython a spin (it was suggested above), I endorse its use for this purpose.

Very simple interface, and seems very teaching-oriented. I plan on using it myself, in fact, since I'm still pretty new to python, in spite of it being nothing at all like vim :)

Looking forward to reading more about how this goes.

[ Parent | Reply to this comment ]

Posted by dkg (216.254.xx.xx) on Sat 7 Feb 2009 at 03:56
[ Send Message | View dkg's Scratchpad | View Weblogs ]
Thanks! Recommendations from personal experimentation are really helpful. Did you try any of the other suggestions above and rule any of them out? I confess i wasn't expecting the level of response i've gotten here, and i'm a bit overwhelmed myself.

i'll be posting about what we end up using.

[ Parent | Reply to this comment ]

 

 

Flattr