I am looking to implement JSON-RPC using the python twisted framework. I've installed the latest version of txJSON-RPC (v0.3.1) and simplejson (v2.3.2) and am trying the json examples with twisted v12.0.0 for Python 2.7.
The server from this StackOverflow post Python Twisted JSON RPC compiles and runs, but the client errors out:
error [Failure instance: Traceback (failure with no frames): <class
'twisted.internet.error.ConnectionRefusedError'>: Connection was refused by other side:
10061: No connection could be made because the target machine actively refused it..
]
Which, from the look of it, means that the server isn't actually running. However, after executing the server, you can connect to the port via telnet.
I also tried the examples included in the /examples directory in the txJSON-RPC tarball, but those didn't run correctly either.
Any ideas about where I can find up-to-date information on how to successfully run a JSON-RPC server with Twisted?
Related
I am trying to connect to a socket.io server. According to the socket.io documentation (version compatibility),"the client and the server must use compatible versions for everything to work", else we get an error like this one here.Problem is, I dont know where to look for server's Engine.io/java/python protocol version on an open webpage Demo.tv. I can run pip freeze to get my socketio and engineio version, but I dont know if I have a webpage open, where do I get protocol versions of the server. example image
We are trying to use the Robot Framework together with a Python Remote Server, so that libraries can be used, that are lying on a different machine.
Lets call the machine on which runs the Python Remote Server A giving me library libA, and the machine which calls libA using the Python Remote Server B. I need this settings, as only machine A has internet connection. Both machines are Windows 10 machines.
I was already successully calling a method in libA from the machine B and everything works as expected if I was logging in to machine B manually and start the on A manually.
Now, I was trying to do the same thing using jenkins, which a special jenkins User and I have connectivity problems. (So it shouldn't be a firewall issue)
Getting keyword names from library 'Remote' failed:
Calling dynamic method 'get_keyword_names' failed:
Connecting remote server at http://192.168.0.1:8270 failed:
[WinError 10061] No connection could be established,
as target computer refuses connection
Does anyone knows, what might be the problem?
How to communicate with a signalr websocket without having to use node.js or other non-Python dependencies?
For example, how to connect to the following websocket:
https://github.com/ericsomdahl/python-bittrex/issues/57#issuecomment-343772197
Running the code from the above example results in:
OSError: Missing Node.js runtime. Node is required. Please read the cfscrape
README's Dependencies section: https://github.com/Anorov/cloudflare-scrape#dependencies.
Likewise the following sample application from python's signalr-client has many non python dependencies:
https://github.com/TargetProcess/signalr-client-py#sample-application
How to connect and communicate with signalr websockets without needing to install any non python dependencies?
The sample application you linked to is a sample signalr server so that the python-client has something to talk to - if you have a signalr service already, you do not need to build or run that (.net) app to use the python signalr-client client in your python programs. See the requirements file: https://github.com/TargetProcess/signalr-client-py/blob/develop/requirements . Python only!
I've set up Apache Mesos 0.21.2 on a virtual machine. The installation was performed by downloading the sources, compiling it and applying make install.
On another virtual machine I've copied the build directory in order to use it as a slave system.
I wanted to start with a small 'hello world' framework as showed in http://jamesporter.me/2014/11/15/hello-mesos.html
however, when I'm executing the python framework with
python hello_mesos.py
I get the following log:
I1227 19:16:02.790803 1678 sched.cpp:137] Version: 0.21.1
2015-12-27 19:16:02,790:1678(0x7f6b1e3de700):ZOO_INFO#log_env#712: Client
environment:zookeeper.version=zookeeper C client 3.4.5
...
2015-12-27
19:17:09,526:1678(0x7f6b1bf7e700):ZOO_ERROR#handle_socket_error_msg#1697:
Socket [127.0.0.1:2181] zk retcode=-4, errno=111(Connection refused): server
refused to accept the client
What can be the source that triggers this error? Is there any other way to get more information?
Thank you in advance for any hints and
with best regards
I'd recommend that you use a recent Mesos version, 0.21.2 is quite old as 0.26.0 is out. There are also precompiled packages available.
Concerning your actual problem, it appears that either
ZooKeeper is not started on the host you're trying to execute your framework on
If you're trying to reach ZK from another host, you need to set the actual IP
I am running on Windows 8.1. I have installed Python 2.7.2, Zope interface 4.1.1 and Twisted 64bits.
When I use twisted, I get a really awkard error.
I have always used twisted and never got this error.
I get this after writing from twisted.internet import reactor, protocol
socket.error: [Errno 10060] A connection attempt failed because the connected pa
rty did not properly respond after a period of time, or established connection f
ailed because connected host has failed to respond
The error is saying the server you are trying to connect to did not respond. You are either not correcting to the right server, or the server is not set up to reply as you are wanting it to. Another possibility is that you do not have the appropriate ports open to make the connection.