Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #7205 > unrolled thread

Paramiko Threading Error

Started bymud <jenmud@gmail.com>
First post2011-06-07 19:25 -0700
Last post2011-06-14 17:52 -0700
Articles 3 — 2 participants

Back to article view | Back to comp.lang.python


Contents

  Paramiko Threading Error mud <jenmud@gmail.com> - 2011-06-07 19:25 -0700
    Re: Paramiko Threading Error David <71david@libero.it> - 2011-06-09 19:47 +0200
      Re: Paramiko Threading Error mud <jenmud@gmail.com> - 2011-06-14 17:52 -0700

#7205 — Paramiko Threading Error

Frommud <jenmud@gmail.com>
Date2011-06-07 19:25 -0700
SubjectParamiko Threading Error
Message-ID<ab491c86-597d-4e5f-8fc9-e192369a8a3a@17g2000prr.googlegroups.com>
Hi All,

Does anybody know what the following error means with paramiko, and
how to fix it.

I don't know what is causing it and why. I have updated paramiko to
version 1.7.7.1 (George) but still has the same issue.

Also I can not reproduce the problem and therefore debugging is harder
for me.


Exception in thread Thread-4 (most likely raised during interpreter
shutdown):
Traceback (most recent call last):
  File "/usr/lib64/python2.6/threading.py", line 532, in
__bootstrap_inner
  File "/usr/lib/python2.6/site-packages/paramiko/transport.py", line
1574, in run
<type 'exceptions.AttributeError'>: 'NoneType' object has no attribute
'error'

[toc] | [next] | [standalone]


#7310

FromDavid <71david@libero.it>
Date2011-06-09 19:47 +0200
Message-ID<jvc90cjf6ces.19cbv2fiwddd0$.dlg@40tude.net>
In reply to#7205
Il Tue, 7 Jun 2011 19:25:43 -0700 (PDT), mud ha scritto:

> Hi All,
> 
> Does anybody know what the following error means with paramiko, and
> how to fix it.
> 
> I don't know what is causing it and why. I have updated paramiko to
> version 1.7.7.1 (George) but still has the same issue.
> 
> Also I can not reproduce the problem and therefore debugging is harder
> for me.
> 
> 
> Exception in thread Thread-4 (most likely raised during interpreter
> shutdown):
> Traceback (most recent call last):
>   File "/usr/lib64/python2.6/threading.py", line 532, in
> __bootstrap_inner
>   File "/usr/lib/python2.6/site-packages/paramiko/transport.py", line
> 1574, in run
> <type 'exceptions.AttributeError'>: 'NoneType' object has no attribute
> 'error'

if I remember rightly, I got that kind of error when I tried to use a
transport without setting up the paramiko's logging subsystem.
Try to put in head of your code the line:

pk.util.log_to_file("log file name.txt")

D.

[toc] | [prev] | [next] | [standalone]


#7658

Frommud <jenmud@gmail.com>
Date2011-06-14 17:52 -0700
Message-ID<4e61e685-4ce8-460f-bfd4-e04b32dd9f92@z4g2000prk.googlegroups.com>
In reply to#7310
On Jun 10, 3:47 am, David <71da...@libero.it> wrote:
> Il Tue, 7 Jun 2011 19:25:43 -0700 (PDT), mud ha scritto:
>
>
>
>
>
>
>
>
>
> > Hi All,
>
> > Does anybody know what the following error means with paramiko, and
> > how to fix it.
>
> > I don't know what is causing it and why. I have updated paramiko to
> > version 1.7.7.1 (George) but still has the same issue.
>
> > Also I can not reproduce the problem and therefore debugging is harder
> > for me.
>
> > Exception in thread Thread-4 (most likely raised during interpreter
> > shutdown):
> > Traceback (most recent call last):
> >   File "/usr/lib64/python2.6/threading.py", line 532, in
> > __bootstrap_inner
> >   File "/usr/lib/python2.6/site-packages/paramiko/transport.py", line
> > 1574, in run
> > <type 'exceptions.AttributeError'>: 'NoneType' object has no attribute
> > 'error'
>
> if I remember rightly, I got that kind of error when I tried to use a
> transport without setting up the paramiko's logging subsystem.
> Try to put in head of your code the line:
>
> pk.util.log_to_file("log file name.txt")
>
> D.

Hi David,

I have tried that already because I though that the logging might
indicate what the issue is.

What I have found is that paramiko seems to be using threading which
is not %100 thread safe in python. So it seems that when the script
exits, the interpreter is failing to close the threads running and
therefor giving the exception.

What I have tried now is to go through all the connections objects
that I have opened, close them first if they are open before the
script exists. It appears to be working so far but only time will
tell.

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web