Re: A mistake which almost went me mad

2016-03-10 Thread Rick Johnson
On Thursday, March 10, 2016 at 12:13:39 AM UTC-6, Rustom Mody wrote: > As usual Rick I find myself agreeing with your direction [also it seems > Random832's direction] Somehow i missed Random's remark... Hmm, he does have a good idea! Introducing a new "import statement" would not break anything

Re: A mistake which almost went me mad

2016-03-09 Thread Rustom Mody
On Wednesday, March 9, 2016 at 10:04:35 PM UTC+5:30, Rick Johnson wrote: > On Thursday, March 3, 2016 at 4:22:07 AM UTC-6, ast wrote: > > Hello > > > > This has to be told > > > > I created a file pickle.py in order to test some files > > read/write with objects and put it in a directory > > whic

Re: A mistake which almost went me mad

2016-03-09 Thread Rick Johnson
On Thursday, March 3, 2016 at 4:22:07 AM UTC-6, ast wrote: > Hello > > This has to be told > > I created a file pickle.py in order to test some files > read/write with objects and put it in a directory > which is on my python path. > > Then the nightmare began > > - Idle no longer works, windo

Re: A mistake which almost went me mad

2016-03-07 Thread Chris Angelico
On Tue, Mar 8, 2016 at 3:19 AM, Ian Kelly wrote: > On Thu, Mar 3, 2016 at 11:50 AM, Tim Chase > wrote: >> I think that relative imports should ameliorate this, as I usually >> hit it when I'm using smtplib which in turn imports "email" (and, in >> 2.x when it found my local email.py would crash a

Re: A mistake which almost went me mad

2016-03-07 Thread Random832
On Mon, Mar 7, 2016, at 11:19, Ian Kelly wrote: > Relative imports only work inside packages. You can't use a relative > import to import one top-level module from another. > > Besides, the relative import doesn't help to disambiguate in this > case. The absolute path of the stdlib email module is

Re: A mistake which almost went me mad

2016-03-07 Thread Ian Kelly
On Thu, Mar 3, 2016 at 11:50 AM, Tim Chase wrote: > I think that relative imports should ameliorate this, as I usually > hit it when I'm using smtplib which in turn imports "email" (and, in > 2.x when it found my local email.py would crash and burn). If it used > a relative import that forced it t

Re: A mistake which almost went me mad

2016-03-03 Thread Gregory Ewing
Tim Golden wrote: A few teachers recently were discussing this on Twitter. One suggested that his pupils always add their initials to whatever filename they use. Works well until Lawrence Ian Bernstein writes his own module called "url"... -- Greg -- https://mail.python.org/mailman/listinfo/py

Re: A mistake which almost went me mad

2016-03-03 Thread Tim Chase
On 2016-03-03 16:29, Oscar Benjamin wrote: > On 3 March 2016 at 11:48, Tim Chase > wrote: > > On 2016-03-03 10:43, Nick Sarbicki wrote: > >> The number of times I've had to correct a student for naming > >> their script "turtle.py". > >> > >> And the number of times I've caught myself doing it...

Re: A mistake which almost went me mad

2016-03-03 Thread Rob Gaddi
Oscar Benjamin wrote: > On 3 March 2016 at 11:48, Tim Chase wrote: >> On 2016-03-03 10:43, Nick Sarbicki wrote: >>> The number of times I've had to correct a student for naming their >>> script "turtle.py". >>> >>> And the number of times I've caught myself doing it... >> >> I'm surprised at the

Re: A mistake which almost went me mad

2016-03-03 Thread Oscar Benjamin
On 3 March 2016 at 11:48, Tim Chase wrote: > On 2016-03-03 10:43, Nick Sarbicki wrote: >> The number of times I've had to correct a student for naming their >> script "turtle.py". >> >> And the number of times I've caught myself doing it... > > I'm surprised at the number of times I find myself cr

Re: A mistake which almost went me mad

2016-03-03 Thread Tim Chase
On 2016-03-03 10:43, Nick Sarbicki wrote: > The number of times I've had to correct a student for naming their > script "turtle.py". > > And the number of times I've caught myself doing it... I'm surprised at the number of times I find myself creating an "email.py" DESPITE KNOWING BETTER EVERY SI

Re: A mistake which almost went me mad

2016-03-03 Thread Steven D'Aprano
On Thu, 3 Mar 2016 09:21 pm, ast wrote: > Hello > > This has to be told > > I created a file pickle.py in order to test some files > read/write with objects and put it in a directory > which is on my python path. [...] > I uninstalled python34 and reinstalled it, same problem > I uninstalled

Re: A mistake which almost went me mad

2016-03-03 Thread Tim Golden
On 03/03/2016 10:43, Nick Sarbicki wrote: > On Thu, Mar 3, 2016 at 10:26 AM ast wrote: > >> Hello >> >> This has to be told >> >> I created a file pickle.py >> > > You could stop there. > > The number of times I've had to correct a student for naming their script > "turtle.py". A few teachers

Re: A mistake which almost went me mad

2016-03-03 Thread Nick Sarbicki
On Thu, Mar 3, 2016 at 10:26 AM ast wrote: > Hello > > This has to be told > > I created a file pickle.py > You could stop there. The number of times I've had to correct a student for naming their script "turtle.py". And the number of times I've caught myself doing it... ...

Re: A mistake which almost went me mad

2016-03-03 Thread Chris Angelico
On Thu, Mar 3, 2016 at 9:21 PM, ast wrote: > - python -m pip list doesnt work, crash with an error message related to > pickle At this point, you could have come to this list, asking for help - and posting the *entire* traceback. It may have mentioned a file name, which would give a strong clue;

A mistake which almost went me mad

2016-03-03 Thread ast
Hello This has to be told I created a file pickle.py in order to test some files read/write with objects and put it in a directory which is on my python path. Then the nightmare began - Idle no longer works, window no longer opens when double clicked, no errors messsages - python -m pip l