[Eric] Can not run Python scripts and empty Shell - Eric3

Chip Webber chipwebber at gmail.com
Fri Apr 20 20:24:37 BST 2007


Detlev,
Thanks for the help, you're advice got me started in the right direction.
Everything is now working beautifully, although I can't say what exactly I
did to fix it.  I can't even reproduce the bad state in which I had the
problem. 

I am running Eric3 on a Virtual Machine using VMWare (the host OS is winXP).
It looks like the Debugger wouldn't start due to an odd interactions in
network settings and the Virtual Machine (VMWare).  

Can't wait to get started :)
-- Chip

Since I wrote most of this email before I solved the problem, I'm going to
post it to the list for reference :)



> Detlev wrote:
> please open the preferences dialog, Debugger - Python page and check
> the a custom Python interpreter is selected. If this is the case and
> a non existing path is given, startup of the debugger will occur.
> Please select Standard and try again.

I am using Debug Client Type = Standard.  So debugger still doesn't start :(

I noticed the following message in the console a little while after starting
Eric3 from the console, confirming that the Debugger is not loading:

Traceback (most recent call last):
  File
"/usr/lib/python2.4/site-packages/eric3/DebugClients/Python/DebugClient.py",
line 55, in ?
    debugClient.main()
  File
"/usr/lib/python2.4/site-packages/eric3/DebugClients/Python/DebugClientBase.
py", line 1825, in main
    self.connectDebugger(port, remoteAddress, redirect)
  File
"/usr/lib/python2.4/site-packages/eric3/DebugClients/Python/DebugClientBase.
py", line 928, in connectDebugger
    sock.connect((DebugAddress,port))
  File "<string>", line 1, in connect
socket.error: (110, 'Connection timed out')

After examining DebugClientBase.py, I'm wondering if it may be related to
the network setup... I'm running on a Virtual machine (VMWare) and there are
several options on handling the network configuration.  I did the following
and rebooted:
   * Disabled Firewall
   * Assigned a hostname to the device (before it was default localhost)

Then the Debugger loaded!!  What's odd is that after I changed everything
back to how it was before (broken) it still works.  So I can not get back to
the non-working state.  I'm chalking it up to a glitch in the VMWare
handling the network connections or maybe the restart got the machine out of
a bad state.

-- On Friday, April 20, 2007 12:50 PM 
-- Detlev Offenbach wrote:
> Hi,
> 
> please open the preferences dialog, Debugger - Python page and check
> the a custom Python interpreter is selected. If this is the case and
> a non existing path is given, startup of the debugger will occur.
> Please select Standard and try again.
> 
> The observed traceback is a follow on problem that is caused by the
> missing feedback of the Python debugger. That can be changed by
> changing line 104 of Shell.py to read
> 
> self.history = QStringList()
> 
> Regards,
> Detlev
> 
> On Donnerstag, 19. April 2007, Chip Webber wrote:
>> Hello,
>> After hearing so many wonderful things about Eric, I've decided to
>> give it a try.   However, I can't get the Shell inside Eric to work,
>> or any python scripts to run.  For sanity check I've run through the
>> tutorials and docs, but I'm stuck. 
>> 
>> Starting eric3 fives the following warnings:
>> Warning: translation file 'qt_en_US.UTF-8'could not be loaded.
>> Using default.
>> Warning: translation file 'eric3_en_US.UTF-8'could not be loaded.
>> Using default.
>> Warning: translation file 'qscintilla_en_US.UTF-8'could not be
>> loaded. Using default. 
>> 
>> When Eric3 opens the Shell window is completely blank, there is no
>> python version information or '>>>' (start->Python has no effect). 
>> On a simple hello world script the Debug -> Run script does nothing.
>> Trying to execute 'print "hello"' in the Shell gives the following
>> errors in stderr: 
>> 
>> Traceback (most recent call last):
>>   File
>>    
>>  
>>    
>>  
>> "/usr/lib/python2.4/site-packages/eric3/ViewManager/ViewManager.py",
>>     line 3817, in editorCommand
>>   self.ui.getShell().editorCommand(cmd) File
>>     "/usr/lib/python2.4/site-packages/eric3/QScintilla/Shell.py",
>> line 577, in editorCommand self.supportedEditorCommands[cmd](cmd)
>> File "/usr/lib/python2.4/site-packages/eric3/QScintilla/Shell.py",
>> line 714, in handleQScintillaNewline self.executeCommand(buf) File
>> "/usr/lib/python2.4/site-packages/eric3/QScintilla/Shell.py", line
>> 881, in executeCommand if len(self.history) ==
>> self.maxHistoryEntries:      
>> TypeError: len() of unsized object
>> 
>> It looks like Eric can't talk to the python Shell to execute
>> commands. I've poked around in Shell.py, but haven't been able to do
>> any good. 
>> 
>> I'm on Fedora Core 6 which provides a pre-compiled version of
>> Eric3.9.1 and supporting applications, so I'm rather surprised it
>> doesn't work right out of the box. 
>> 
>> Using:
>> Eric 3.9.1 (also tried 3.9.4)
>> Python 2.4.3
>> PyQt-3.17
>> Qt-3.3.7
>> PyQt-Qscintilla-3.17
>> Qscintilla-1.7
>> SIP 4.4.5 (also tried SIP 4.6)
>> 
>> Any Ideas??  I don't mind compiling newer versions of tools, but so
>> far it hasn't done any good :(  Being relatively new to Qt, PyQt,
>> etc. I still don't have a good understanding of how all the required
>> packages are related... 
>> 
>> Thanks,
>> Chip
>> 
>> 
>> _______________________________________________
>> Eric mailing list
>> Eric at riverbankcomputing.com
>> http://www.riverbankcomputing.com/mailman/listinfo/eric



More information about the Eric mailing list