Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7553241
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T10:59:38+00:00 2026-05-30T10:59:38+00:00

Several times I’ve seen mention that for asynchronous ping is good to use twisted.

  • 0

Several times I’ve seen mention that for asynchronous ping is good to use twisted.

I written implementation on threads (like Ping a site in Python?)

But on ~200 threads i have crush

On page http://twistedmatrix.com/trac/wiki/ProjectsUsingTwisted i find
txNetTools – Ping, traceroute, icmp, etc., implemented in Twisted, and a library for those who want to build their own network tools.

Has anyone used this library?

I tried to use it ping.py:

Traceback (most recent call last):
  File "ping.py", line 23, in <module>
    class Pinger(ICMP):
NameError: name 'ICMP' is not defined

if change:

 class Pinger(**ICMP**):

to

class Pinger():

Traceback (most recent call last):
  File "ping.py", line 54, in <module>
    reactor.listenICMP(0, Pinger())
  File "./txnet/reactor.py", line 21, in listenICMP
    p.startListening()
  File "/usr/local/lib/python2.7/dist-packages/twisted/internet/udp.py", line 102, in startListening
    self._connectToProtocol()
  File "/usr/local/lib/python2.7/dist-packages/twisted/internet/udp.py", line 123, in _connectToProtocol
    self.protocol.makeConnection(self)
AttributeError: Pinger instance has no attribute 'makeConnection'

Maybe I’m doing something wrong or not understand?

P.S. twisted 12.0

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T10:59:40+00:00Added an answer on May 30, 2026 at 10:59 am

    If you are running sandbox/ping.py, then the exception you report doesn’t make sense. That file has this import near the beginning:

    from txnet.icmp import ICMP, Packet, ECHO_REQUEST
    

    This defines the ICMP name. The Pinger class comes later, extending it. I can successfully run this demo program (though it fails with an unrecognized message type when handling the response on my sytem).

    Perhaps you have an old version of the code, or have modified it somehow, or are running a different ping.py?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Several times I've seen ReSharper generate code that looks like this: delegate void myHandler(int
I've seen these several times but I can't figure out how to use them.
Several times I see ^L in (mostly Emacs Lisp) source codes that looks like
Several times now I've been faced with plans from a team that wants to
Several times, while perusing the Boost library's documentation, I've run across return values that
Several times in my career, I have worked in a software group that determined
Several times I heard that PHP hosting is much cheaper than ASP.NET one. I
Several times while debugging a VB.Net program I have found that continuation lines are
I've been told several times that I should consider splitting parts of my app
Several times I've read that unpack() is faster than substr() , especially as the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.