[IPython-dev] Should we disable autocall by default from now on?
ellisonbg at gmail.com
Wed Nov 30 17:40:57 EST 2011
LOL, I just had a research student come to my office hours with a
notebook. She has been working in Python/IPython for 10 weeks now.
In her notebook she had a line:
Which worked due to autocall. But she had absolutely no idea why this
worked (isn't it similar to "print 10"). In her mind, IPython=Python.
My options at that point:
* Explain the whole autocall thing to her. No way, her cognitive load
was already maxed out trying to understand the physics and code.
* Silently let it be. No way, then she think that this is vald Python
syntax and will start using everywhere even in library code.
* Have her change it, but don't tell her exactly why. This is what I
did, but she is still left with the vague sense that this syntax also
works in *Python* but is not the best way of doing things.
I maintain that the autocall syntax is confusing unless you take the
time to really understand what is going on. And if you have done
that, you are not a beginner. This confusion exists even without the
potential pitfalls related to properties and attribute access. Add
those pitfalls and you have significant potential for confusion.
On Wed, Nov 30, 2011 at 1:50 PM, Robert Kern <robert.kern at gmail.com> wrote:
> On 11/30/11 8:12 PM, MinRK wrote:
>> On Wed, Nov 30, 2011 at 11:56, Fernando Perez <fperez.net at gmail.com
>> <mailto:fperez.net at gmail.com>> wrote:
>> On Wed, Nov 30, 2011 at 11:45 AM, Aaron Meurer <asmeurer at gmail.com
>> <mailto:asmeurer at gmail.com>> wrote:
>> > So personally, I don't think autocall is friendly to beginner users
>> > even as it is now, for the simple reason that it changes the syntax of
>> > Python.
>> Yes, there seems to be consensus that autocall should be an expert
>> tool, and therefore it would be OK to make the default be off. The
>> defaults should be chosen to make ipython as beginner-friendly as
>> possible (while still being more useful than the >>> shell). Experts
>> are expected to tweak their config to suit their personal preferences
>> (e.g., I'll always keep autocall on in 'smart' mode).
>> I think it's exactly the opposite. autocall is very much a beginner tool, for
>> users who have not yet
>> committed Python's syntax to memory. When they make simple typos, autocall
>> helps remind them by saying,
>> "I know what you meant, but here's how you should do it in the future".
> But that's not really what the feature does, or what it was intended to do. It
> was added solely for the experienced user named Fernando who liked to type
> things fast without needing to use the shift keys. It was not a do-what-I-mean
> to correct newbie errors. There is certainly nothing in the message that implies
> that you *should* type things differently.
> Robert Kern
> "I have come to believe that the whole world is an enigma, a harmless enigma
> that is made terrible by our own mad attempt to interpret it as though it had
> an underlying truth."
> -- Umberto Eco
> IPython-dev mailing list
> IPython-dev at scipy.org
Brian E. Granger
Cal Poly State University, San Luis Obispo
bgranger at calpoly.edu and ellisonbg at gmail.com
More information about the IPython-dev