cybozu / passh

Parallel SSH for cluster of hosts based on Python3 asyncio.
8 stars 2 forks source link

TypeError: signal handler must be signal.SIG_IGN, signal.SIG_DFL, or a callable object #2

Open ghost opened 8 years ago

ghost commented 8 years ago

Hi,

I tried passh again and it worked. However, an exception was raised:

$ passh dbox ls /
[dbox] bin
[dbox] boot
[dbox] dev
[dbox] etc
[dbox] home
[dbox] initrd.img
[dbox] initrd.img.old
[dbox] lib
[dbox] lib64
[dbox] lost+found
[dbox] media
[dbox] mnt
[dbox] opt
[dbox] proc
[dbox] root
[dbox] run
[dbox] sbin
[dbox] srv
[dbox] sys
[dbox] tmp
[dbox] usr
[dbox] var
[dbox] vmlinuz
[dbox] vmlinuz.old
Exception ignored in: <bound method BaseEventLoop.__del__ of <_UnixSelectorEventLoop running=False closed=True debug=False>>
Traceback (most recent call last):
  File "/usr/lib/python3.5/asyncio/base_events.py", line 431, in __del__
  File "/usr/lib/python3.5/asyncio/unix_events.py", line 58, in close
  File "/usr/lib/python3.5/asyncio/unix_events.py", line 139, in remove_signal_handler
  File "/usr/lib/python3.5/signal.py", line 47, in signal
TypeError: signal handler must be signal.SIG_IGN, signal.SIG_DFL, or a callable object

Operating system: Arch Linux passh version: master branch Mon Oct 24 00:27:12 EDT 2016 Python version: 3.5.2

ymmt2005 commented 8 years ago

Thank you for the report. I will investigate it later on.

ghost commented 8 years ago

Thank you!

ymmt2005 commented 8 years ago

Failed to reproduce on Ubuntu 16.04:

$ pip3 show passh
---
Metadata-Version: 2.0
Name: passh
Version: 1.0.2
Summary: Python3 asyncio library to run SSH in parallel
Home-page: https://github.com/cybozu/passh
Author: Yamamoto, Hirotaka
Author-email: ymmt2005@gmail.com
Installer: pip
License: MIT
Location: /home/ymmt/.local/lib/python3.5/site-packages
Requires: 
Classifiers:
  Development Status :: 5 - Production/Stable
  Intended Audience :: Developers
  Intended Audience :: System Administrators
  License :: OSI Approved :: MIT License
  Programming Language :: Python :: 3.4
  Programming Language :: Python :: 3 :: Only
  Topic :: Software Development :: Libraries
  Topic :: System :: Networking
Entry-points:
  [console_scripts]
  passh = passh:main
You are using pip version 8.1.1, however version 8.1.2 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.

ymmt@xenial:~$ passh localhost ls
[localhost] build
[localhost] infra
[localhost] tools
[localhost] vm-master-image
ymmt2005 commented 8 years ago

@Asher256 Guess you are running an old version of passh. Could you please confirm that the code has this fix? https://github.com/cybozu/passh/commit/6ff60ccef56ecdd65ea4080d03946e3f96794fac