Python education survey

R

Raymond Hettinger

Do you use IDLE when teaching Python?
If not, what is the tool of choice?

Students may not be experienced with the command-line and may be
running Windows, Linux, or Macs. Ideally, the tool or IDE will be
easy to install and configure (startup directory, path, associated
with a particular version of Python etc).

Though an Emacs user myself, I've been teaching with IDLE because it's
free; it runs on multiple OSes, it has tooltips and code colorization
and easy indent/dedent/comment/uncomment commands, it has tab
completion; it allows easy editing at the interactive prompt; it has
an easy run-script command (F5); it has direct access to source code
(File OpenModule) and a class browser (Cntl+B).

On the downside, some python distros aren't built with the requisite
Tcl/Tk support; some distros like the Mac OS ship with a broken Tcl/Tk
so users have to install a fix to that as well; and IDLE sometimes
just freezes for no reason. It also doesn't have an easy way to
specify the startup directory.

If your goal is to quickly get new users up and running in Python,
what IDE or editor do you recommend?


Raymond
 
A

Alec Taylor

Two suggestions:

- Editra (free): Requires a little bit of fiddling around and enabling
Shelf, installing plugins but then it is great
- Recently I was introduced to Sublime Text 2 which has an über
streamlined layout.
 
L

Luka Dornhecker

Do you use IDLE when teaching Python?
If not, what is the tool of choice?

Students may not be experienced with the command-line and may be
running Windows, Linux, or Macs. Ideally, the tool or IDE will be
easy to install and configure (startup directory, path, associated
with a particular version of Python etc).

Though an Emacs user myself, I've been teaching with IDLE because it's
free; it runs on multiple OSes, it has tooltips and code colorization
and easy indent/dedent/comment/uncomment commands, it has tab
completion; it allows easy editing at the interactive prompt; it has
an easy run-script command (F5); it has direct access to source code
(File OpenModule) and a class browser (Cntl+B).

On the downside, some python distros aren't built with the requisite
Tcl/Tk support; some distros like the Mac OS ship with a broken Tcl/Tk
so users have to install a fix to that as well; and IDLE sometimes
just freezes for no reason. It also doesn't have an easy way to
specify the startup directory.

If your goal is to quickly get new users up and running in Python,
what IDE or editor do you recommend?


Raymond

If you want an easy to use, cross-platform editor with lots of nice features I would also recommend Sulbime Text 2.
You would have to teach how to use the terminal on different platforms but for basic stuff, like running a python program it's basically the same on Linux, Windows and OSX.
 
D

Devin Jeanpierre

My university (University of Toronto) helped design Wing 101, and uses
it exclusively in introductory courses.

Overall, the only major sticking points that I saw (as a TA who helped
with the code labs and setup) were installation issues on OS X
(relating to X11) and some confusion on when the embedded interactive
interpreter gets refreshed ("hit run first"). It's a "big" editor with
lots of buttons, but IME students are good at ignoring things.

Truthfully I'm not sure why it's great for teaching, though. And there
were some discussions I overheard about perhaps switching to PyCharm,
which at least one professor thought was much better. And I personally
prefer simpler editors for my own use, not just for educational
purposes. Eh.

-- Devin
 
S

Stefan Behnel

Devin Jeanpierre, 20.12.2011 08:32:
Truthfully I'm not sure why it's great for teaching, though. And there
were some discussions I overheard about perhaps switching to PyCharm,
which at least one professor thought was much better.

I recently started using PyCharm personally, but not for my courses.
There's a free OSS developers licence and it's a really nice (although
young and somewhat resource hungry) IDE, but you can't really advocate a
non-free IDE for teaching. "Buy me as a teacher, and, BTW, buy this IDE for
everyone as well or I won't teach you"? Doesn't quite work.

For teaching, I think it's better to come around with something simpler
than a full-blown IDE, so that you can show off interactive development,
help() and other introspection features. IMHO much better than hiding all
that behind an IDE, especially behind the additional complexity of an IDE.
IPython is much better suited to present an interactive language like Python.

Stefan
 
A

Andrea Crotti

Do you use IDLE when teaching Python?
If not, what is the tool of choice?

Students may not be experienced with the command-line and may be
running Windows, Linux, or Macs. Ideally, the tool or IDE will be
easy to install and configure (startup directory, path, associated
with a particular version of Python etc).

Though an Emacs user myself, I've been teaching with IDLE because it's
free; it runs on multiple OSes, it has tooltips and code colorization
and easy indent/dedent/comment/uncomment commands, it has tab
completion; it allows easy editing at the interactive prompt; it has
an easy run-script command (F5); it has direct access to source code
(File OpenModule) and a class browser (Cntl+B).

On the downside, some python distros aren't built with the requisite
Tcl/Tk support; some distros like the Mac OS ship with a broken Tcl/Tk
so users have to install a fix to that as well; and IDLE sometimes
just freezes for no reason. It also doesn't have an easy way to
specify the startup directory.

If your goal is to quickly get new users up and running in Python,
what IDE or editor do you recommend?


Raymond

I think ipython and a good editor gives a much nicer experience
than IDLE, which I actually almost never used, and
for everything else there is python and python-mode.

New users however can be pointed to something like PyCharm
or Eclipse+PyDev if they are more familiar to IDEs..
 
E

Eelco

I taught a Python class just recently, and thought long and hard about
this problem. I settled on PyCharm and was happy with that.

My reasons:
- available on all main platoforms
- not entirely broken code completion (ive tried literally every
python editor, and pycharm is the only one that meets this requirement
on all platforms. Try import numpy; numpy.array. 90% of editors with
'code completion' will fail that simple benchmark. The only thing
worse than no completion list is an incomplete list of completions.
Only pyscripter is better in this regard, but win-only.)
- easy installation
- integrated console
- integrated debugger
- free (for classroom use)
- fairly uncluttered
I recently started using PyCharm personally, but not for my courses.
There's a free OSS developers licence and it's a really nice (although
young and somewhat resource hungry) IDE, but you can't really advocate a
non-free IDE for teaching. "Buy me as a teacher, and, BTW, buy this IDE for
everyone as well or I won't teach you"? Doesn't quite work.

PyCharm provides a free 1 year classroom license.
For teaching, I think it's better to come around with something simpler
than a full-blown IDE, so that you can show off interactive development,
help() and other introspection features. IMHO much better than hiding all
that behind an IDE, especially behind the additional complexity of an IDE.
IPython is much better suited to present an interactive language like Python.

PyCharm has an integrated interpreter (a wrapper around Ipython that
superimposes the pycharm based code completion stuff).
Plus, it does not start by default into a clutter-overload mode, and
if you click away a pane or two, you have a rather clean editor.

Aside from worrying about your editor, worry about how to install
python. As a windows user, I had scarcely imagined the nightmares of
installing everything on all platforms, different OS versions, and so
forth. DONT install/compile via the command line, and DO use a
precompiled distro like enthought. Macosx does not come with a C
compiler, and your only recourse is the 4-gig xcode download. That is,
if *friggin ITunes* lets you install it, and does not silently screw
up your installation. I could go on, but anyway you get the point.
Unless its your own computer, anything more complex than double
clicking an installer WILL GO WRONG, and spending hours debugging
other peoples computers is not how you want to spend your time.
 
R

Rick Johnson

For teaching, I think it's better to come around with something simpler
than a full-blown IDE, so that you can show off interactive development,
help() and other introspection features. IMHO much better than hiding all
that behind an IDE,

That is a damn good point Stefan. Too many noobs step passed the
introspection features of Python without knowing what happened. help,
dir, type, isinstance, id... to name a few. Heck for most things,
considering you have at least basic programming experience, the help
function is all you need to learn the language.
 
C

Chris Angelico

Heck for most things,
considering you have at least basic programming experience, the help
function is all you need to learn the language.

I know I shouldn't feed the troll, but this is more general.

You cannot learn the _language_ from help() - it's more like a
dictionary. You still need something that explains the grammar, and
you also need to have some ideas of what names to look up.

The help() function in Python is actually not as helpful as could be
desired, in many cases. I think "help()" on its own is probably a good
thing, but... I didn't know about it until I tried it right while
typing up this email. (That's probably my fault more than Python's,
though.)

help(functionname) is usually fairly helpful - but most of that is
just from the function's docstring. Unfortunately help(classname) and
help(modulename) are way too spammy to be much use. Look for instance
at help(decimal.Decimal) - quite a few dunder methods are listed,
uselessly. What does "__deepcopy__(self, memo)" do? What about
"__ge__(self, other, context=None)"? Unless you happen to know that
__ge__ is the greater-than-or-equal function, it's not going to do you
much good to see the method listed. They're just spam, forcing you to
read through more screed to figure out what's going on.

Same, and even worse, with modules - help(decimal) is pages and pages
of text, detailing the exceptions supported etc. Unlike the class's,
though, the module's docstring is actually quite helpful. (It also
hints at what the context=None arguments are on a lot of the methods.)

Please note that this is not a criticism of the decimal module
specifically; and the help() function can't really be written any
other way, short of having it emit ONLY docstrings, and then demand
that module authors maintain perfect class and module docstrings (like
that's gonna happen).

Hmm. Another feature I didn't know about help() - instead of passing
it an object, you can pass it a string. This gets around the fact that
"help(class)" doesn't work - "help('class')" does. I think I should
reword this from "possible feature request" to "does this already
exist", because it probably does... so...

Is there a less spammy documentation utility, in-built into Python?

Chris Angelico
 
M

Miki Tebeka

I've tried several things. So far vim (with line numbers) to show the code and then ipython to run it works great.

Another option I tried once was Aptana, since most people in my company know eclipse this was good for them. It has most (all?) of the features you mentioned above.
 
F

Fernando Perez

Do you use IDLE when teaching Python? If not, what is the tool of
choice?

I'm obviously biased (I started IPython years ago), but I've done a lot
of teaching and I still do like the combination of IPython plus an
editor. Sometimes I use IDLE configured to only open the editor and not
the shell, but I recommend that users learn a 'real' editor for the long
run (aka emacs/vim), as it's an investment that will pay off many times
over.

But if nothing else, there's at least an OK free editor for each OS that
does work, and I keep a 'starter kit' page with those resources for my
students:

http://fperez.org/py4science/starter_kit.html

Cheers,

f
 
A

Ashton Fagg

Students may not be experienced with the command-line and may be
running Windows, Linux, or Macs.  Ideally, the tool or IDE will be
easy to install and configure (startup directory, path, associated
with a particular version of Python etc).

I tutor people (usually fellow students) in programming occasionally,
and I've always recommended a simple text editor and a command line
(this correlates with most languages, not just Python). My personal
set up (using Linux) is vim (with line numbers and syntax
highlighting) + shell, no matter which language I'm working with.
However for people I'm tutoring, particularly if they're new to
programming in general and would find vim intimidating, I recommend
gedit (for Linux) or Notepad++ (for Windows), executing/compiling from
the command line.

As long as the text editor has line numbers and syntax highlighting
it's sufficient in my book. I don't like obfuscating what's going on
in the background (i.e. interacting with the Python/C/<insert language
here> interpreter/compiler/whatever) with a fancy IDE. However that is
my personal (strong) opinion.

Hope that helps.

--
Ashton Fagg
E-mail: (e-mail address removed)
Web: http://www.fagg.id.au/~ashton/

Keep calm and call Batman.
 
R

Roy Smith

Ashton Fagg said:
As long as the text editor has line numbers and syntax highlighting
it's sufficient in my book.

I agree with the syntax highlighting. I resisted for many years, then
somebody turned me on to it a few years ago and I've been addicted ever
since.

As for line numbers, for working alone, I don't see much point. But for
any kind of interaction with other people, it's essential. It's just SO
much easier to say, "line 417" as opposed to "OK, scroll up a couple
more lines, no, no, not that far, go down a little. There! See that
print statement, now go down three lines below that, ..." By the time
the two of you are on the same page about which line of code you're
talking about, you will have forgotten what you wanted to say.
 
C

Chris Angelico

As for line numbers, for working alone, I don't see much point.  But for
any kind of interaction with other people, it's essential.  It's just SO
much easier to say, "line 417" as opposed to "OK, scroll up a couple
more lines, no, no, not that far, go down a little.  There!  See that
print statement, now go down three lines below that, ..."  By the time
the two of you are on the same page about which line of code you're
talking about, you will have forgotten what you wanted to say.

Ctrl-G in many editors will let you GOTO (sorry, I'll try to keep this
PG-13) a specific line by number. Extremely handy, especially when
you're debugging across computers - the error message comes up on your
test computer and cites the line number, and you jump to it on your
dev easily.

ChrisA
 
N

Nathan Rice

+1 for IPython/%edit using the simplest editor that supports syntax
highlighting and line numbers. I have found that
Exploring/Prototyping in the interpreter has the highest ROI of
anything I teach people.

Nathan
 
R

Raymond Hettinger

+1 for IPython/%edit using the simplest editor that supports syntax
highlighting and line numbers.  I have found that
Exploring/Prototyping in the interpreter has the highest ROI of
anything I teach people.

Thank you Nathan and all the other respondents for your thoughtful
answers.


Raymond
 
R

rusi

+1 for IPython/%edit using the simplest editor that supports syntax
highlighting and line numbers.  I have found that
Exploring/Prototyping in the interpreter has the highest ROI of
anything I teach people.

Nathan

It seems to me that we are not distinguishing different 'scales'.
For example:
In principle one can use any unit to measure length. In practice it is
inconvenient to use kilometers when microns or angstroms are more
appropriate.

Clearly there is a need, when learning a language, to explore the
basics with a minimum of interference from the environment ie
introspection features of python with as little extra interference as
possible.

As a teacher I generally demonstrate with python-mode in emacs. I
guess IDLE, ipython etc should be equivalent. But then someone in the
class comes with a 'question' of this sort:

We have this project in eclipse+python.
But the path is not being searched properly.
etc

Now for me eclipse is more of pizazz on the outside and nightmare on
the inside. [Or maybe its just that I am particularly bad at solving
these kinds of problems]. Nevertheless this scale or granularity of
work is also important in python education and is sorely
underrepresented.

Here are some of my earlier attempts to canvass for this orientation:

http://mail.python.org/pipermail/python-list/2011-May/1271749.html

http://mail.python.org/pipermail/python-list/2011-November/1283634.html
 
R

Rick Johnson

Do you use IDLE when teaching Python?
If not, what is the tool of choice?

I believe IDLE has the potential to be a very useful teaching tool and
even in it's current abysmal state, i find it to be quite useful.
Students may not be experienced with the command-line and may be
running Windows, Linux, or Macs.  Ideally, the tool or IDE will be
easy to install and configure (startup directory, path, associated
with a particular version of Python etc).

Why install an IDE when IDLE is already there? Oh, yes, IDLE SUCKS. I
know that already. But this revelation begs the question... Why has
this community allowed IDLE to rot? Why has guido NOT started a public
discussion on the matter?
Though an Emacs user myself, I've been teaching with IDLE because it's
free; it runs on multiple OSes, it has tooltips and code colorization
and easy indent/dedent/comment/uncomment commands, it has tab
completion; it allows easy editing at the interactive prompt; it has
an easy run-script command (F5); it has direct access to source code
(File OpenModule) and a class browser (Cntl+B).

Yes, IDLE has all the basic tools anyone would need. Some people
complain about a debugger, but i never use a debugger anyway. I feel
debuggers just wreaken your debugging skills.
On the downside, some python distros aren't built with the requisite
Tcl/Tk support;

And who's fault is that?
some distros like the Mac OS ship with a broken Tcl/Tk
so users have to install a fix to that as well; and IDLE sometimes
just freezes for no reason.

And who's fault is that?
 [IDLE] also doesn't have an easy way to
specify the startup directory.

Are you kidding me? That could be fixed so easily!
If your goal is to quickly get new users up and running in Python,
what IDE or editor do you recommend?

IDLE, of course. But NOT in its current state.

Why would myself (or anyone) go to the trouble of downloading third
party IDEs when IDLE is just waiting there for us to use? I for one,
like to use tools that have open source code. And what is a better
Python IDE than a Python IDE written in PYTHON? I ask ya?

Also, what is the purpose of this thread Raymond? Are you (and others)
considering removing IDLE from the source distro?

You know. Many folks in this community have known for a long time how
much i love IDLE, but at the same time how much i loath it's atrocious
code base. I also know for a fact, that many "movers and shakers"
within this community simultaneously use IDLE, and want to see IDLE
code improved. However. None of these fine folks have taken the time
to contact me privately so we can discuss such an evolution. Why is
that? It boggles the mind really.
 
C

Chris Angelico

Why install an IDE when IDLE is already there? Oh, yes, IDLE SUCKS. I
know that already. But this revelation begs the question... Why has
this community allowed IDLE to rot? Why has guido NOT started a public
discussion on the matter?

Conversely, why write an IDE into IDLE when perfectly-good IDEs
already exist? I don't use IDLE for development per se; it's for
interactive Python execution, but not editing of source files.

ChrisA
 
M

Monte Milanuk

Not a teacher here, but I'm curious why Komodo Edit never seems to get
any love in the IDE debates... a free version for personal/non-profit
use, pro versions for those that need the extra features, seems to work
fairly well but then again I'm probably not the best judge...

Thanks,

Monte
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,764
Messages
2,569,564
Members
45,040
Latest member
papereejit

Latest Threads

Top