ANN: Spyder v1.1.7 and Spyder v2.0.0beta4

19 views
Skip to first unread message

Pierre Raybaut

unread,
Oct 2, 2010, 5:38:59 AM10/2/10
to spyder
Hi all,

I am pleased to announced that Spyder v1.1.7 and Spyder v2.0.0beta4
have been released:

* Spyder v1.1.7 -- a couple of bug fixes since v1.1.6:
* Fixed PyQt compatibility issues related to QTreeWidgetItem
objects construction
* Attempt to fix Issue 318 / PyQt compatibility issues
* Fixed PyQt compatibility issue: setProperty's 2nd argument must
be a QVariant on some PyQt versions

* Spyder v2.0.0beta4 -- a lot of bugfixes since beta2, here are
some
of the recent changes:
* new: real-time code analysis (warnings, errors, todos) with a
customizable timeout (analysis was performed only when saving file)
* new in variable explorer: multiple data files may be imported at
once
* new in source editor: added shortcut to view object in object
inspector
* new in source editor: added option to insert automatically
closing parentheses, brackets and braces
* new in source editor: added option to unindent automatically
after 'else', 'elif', 'finally', etc.
* new in source editor: added option to save all files before
running script
* source editor: a lot of bugfixes regarding breakpoints, file
list management dialog, file selection combo box, ...
* fix PyQt compatibility issues (same as in v1.1.7 -- see above)
* and a lot of bugfixes: code completion, outline explorer
sorting, maximized widgets, etc.

Pierre

josef...@gmail.com

unread,
Oct 2, 2010, 9:34:52 AM10/2/10
to spyd...@googlegroups.com

I tried spyder 2.0.0beta4 with WindowsXP32, py2.5.2 Qt 4.4.1 PyQt 4.4.3

The first time I started spyder it crashed. Starting in debug mode
spyder.py -d, I get a long list of:

Traceback (most recent call last):
File "C:\Programs\Python25\lib\site-packages\spyderlib\widgets\codeeditor\code
editor.py", line 827, in viewportEvent
return super(CodeEditor, self).viewportEvent(event)
AttributeError: 'super' object has no attribute 'viewportEvent'

The editor doesn't work, I cannot edit, but both ipython and regular
shells work, doing some simple examples and with execfile(...). I
didn't try other things.

(I'm not completely sure about this one because I had lot's of other
python shells open.)
After shutting down spyder, I still had several stray python processes
open, two of kept doing a very large number of disc reads/writes
according to the windows task managers. This could also be a
consequence of the initial crash.

Josef

>
> Pierre
>
> --
> You received this message because you are subscribed to the Google Groups "spyder" group.
> To post to this group, send email to spyd...@googlegroups.com.
> To unsubscribe from this group, send email to spyderlib+...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/spyderlib?hl=en.
>
>

Pierre Raybaut

unread,
Oct 2, 2010, 10:27:39 AM10/2/10
to spyder
On Oct 2, 3:34 pm, josef.p...@gmail.com wrote:
That is quite weird because the inheritance diagram is the following:
CodeEditor (spyderlib) <-- TextEditBaseWidget (spyderlib) <--
QPlainTextEdit (Qt) <-- QAbstractScrollArea (Qt)
The last one (QAbstractScrollArea) has a method named
'viewportEvent'...

Are you sure that every single previous Spyder version has been
removed on your machine?

If that's not it, could you please try and replace the line:
return super(CodeEditor, self).viewportEvent(event)
by the following line:
TextEditBaseWidget.viewportEvent(self, event)
or, if it still does not work, by the following two lines:
from PyQt4.QtGui import QPlainTextEdit
QPlainTextEdit.viewportEvent(self, event)

Thanks,
Pierre

josef...@gmail.com

unread,
Oct 2, 2010, 11:05:10 AM10/2/10
to spyd...@googlegroups.com

I only have one spyderlib directory in site-packages, I have previous
spyder-xxx directories but they should be on the python path.

>
> If that's not it, could you please try and replace the line:
>    return super(CodeEditor, self).viewportEvent(event)
> by the following line:
>    TextEditBaseWidget.viewportEvent(self, event)

this worked, the debug console doesn't show the error anymore and I
get the text in the texteditor.

now I get a new error:


Traceback (most recent call last):
File "C:\Programs\Python25\lib\site-packages\spyderlib\widgets\codeeditor\code

editor.py", line 792, in resizeEvent
super(CodeEditor, self).resizeEvent(event)
AttributeError: 'super' object has no attribute 'resizeEvent'

---
After "Loading editor..." I also get :

Traceback (most recent call last):

File "C:\Programs\Python25\lib\site-packages\spyderlib\widgets\editor.py", lin
e 213, in run
self.analysis_results = check(source_code, filename=self.filename)
File "C:\Programs\Python25\lib\site-packages\spyderlib\widgets\editortools.py"
, line 55, in check
pyflakes.messages.UndefinedExport,
AttributeError: 'module' object has no attribute 'UndefinedExport'

(I think I had this one also before)

Josef

josef...@gmail.com

unread,
Oct 2, 2010, 3:36:46 PM10/2/10
to spyd...@googlegroups.com

this exception goes away if I also replace the super call by

TextEditBaseWidget.resizeEvent(self, event)

Josef

josef...@gmail.com

unread,
Oct 2, 2010, 4:37:17 PM10/2/10
to spyd...@googlegroups.com

I cleared this one up, I had both pyflakes 0.3.0 and 0.4.0 on the
path, IDLE (import pyflakes) imported 0.4.0, spyder imported 0.3.0,
which didn't have 'UndefinedExport'.
After removing pyflakes 0.3.0 from my python path, I don't have any
error messages left in the debug console.

Now that spyder looks like it's working again, 2 questions:
Is it still possible to change the font in the editor and the shells,
I didn't see an option?
Is it possible to start the ipython shell without namespace pollution,
and how? e.g. no "from numpy import *", mlab, ...?

>>> len(locals().keys()) #after startup
IDLE : 5
Spyder shell: 9
ipython shell : 915 ! how does anyone know what's what under this condition ?

Thanks,

Josef

Pierre Raybaut

unread,
Oct 3, 2010, 9:53:30 AM10/3/10
to spyder
I think that these issues with 'super' are related to PyQt v4.4 which
was not dealing well with this mecanism.
I'll fix this in next release:
http://code.google.com/p/spyderlib/issues/detail?id=398

On Oct 2, 9:36 pm, josef.p...@gmail.com wrote:

Pierre Raybaut

unread,
Oct 3, 2010, 9:56:32 AM10/3/10
to spyder
On Oct 2, 10:37 pm, josef.p...@gmail.com wrote:
> On Sat, Oct 2, 2010 at 3:36 PM,  <josef.p...@gmail.com> wrote:
Of course: "Preferences" > "Console" and "Preferences" > "Editor" to
change options like font style.

> Is it possible to start the ipython shell without namespace pollution,
> and how? e.g. no "from numpy import *", mlab, ...?

Again in "Preferences" > "Console": click on tab "External modules"
and change the IPython command line options.
The namespace pollution you are referring to is due to the 'pylab'
option - removing it should help.

Pierre

josef...@gmail.com

unread,
Oct 3, 2010, 10:13:32 AM10/3/10
to spyd...@googlegroups.com
On Sun, Oct 3, 2010 at 9:56 AM, Pierre Raybaut <pierre....@gmail.com> wrote:
> On Oct 2, 10:37 pm, josef.p...@gmail.com wrote:

>> Now that spyder looks like it's working again, 2 questions:
>> Is it still possible to change the font in the editor and the shells,
>> I didn't see an option?
>
> Of course: "Preferences" > "Console" and "Preferences" > "Editor" to
> change options like font style.
>
>> Is it possible to start the ipython shell without namespace pollution,
>> and how? e.g. no "from numpy import *", mlab, ...?
>
> Again in "Preferences" > "Console": click on tab "External modules"
> and change the IPython command line options.
> The namespace pollution you are referring to is due to the 'pylab'
> option - removing it should help.

I think that I changed preferences this way in previous versions, but
in 2.0beta4 the list on the left side of the preferences window is
empty. The only options I see are on the right side for the interface.

Thanks, spyder is starting to look good again in my setup.

Josef

>
> Pierre

josef...@gmail.com

unread,
Oct 3, 2010, 10:21:21 AM10/3/10
to spyd...@googlegroups.com
On Sun, Oct 3, 2010 at 9:53 AM, Pierre Raybaut <pierre....@gmail.com> wrote:
> I think that these issues with 'super' are related to PyQt v4.4 which
> was not dealing well with this mecanism.
> I'll fix this in next release:
> http://code.google.com/p/spyderlib/issues/detail?id=398
>

If you want to increase the version of PyQt that is required for
spyder, then I could update it.
But then a version check would be useful to inform the user.

Thanks,

Josef

Pierre Raybaut

unread,
Oct 3, 2010, 10:37:51 AM10/3/10
to spyder


On Oct 3, 4:13 pm, josef.p...@gmail.com wrote:
> On Sun, Oct 3, 2010 at 9:56 AM, Pierre Raybaut <pierre.rayb...@gmail.com> wrote:
> > On Oct 2, 10:37 pm, josef.p...@gmail.com wrote:
> >> Now that spyder looks like it's working again, 2 questions:
> >> Is it still possible to change the font in the editor and the shells,
> >> I didn't see an option?
>
> > Of course: "Preferences" > "Console" and "Preferences" > "Editor" to
> > change options like font style.
>
> >> Is it possible to start the ipython shell without namespace pollution,
> >> and how? e.g. no "from numpy import *", mlab, ...?
>
> > Again in "Preferences" > "Console": click on tab "External modules"
> > and change the IPython command line options.
> > The namespace pollution you are referring to is due to the 'pylab'
> > option - removing it should help.
>
> I think that I changed preferences this way in previous versions, but
> in 2.0beta4 the list on the left side of the preferences window is
> empty. The only options I see are on the right side for the interface.

Could you send me a screenshot?
(that is not normal)
Reply all
Reply to author
Forward
0 new messages