Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Socket error on client ***, disconnecting while trying to subscribe through robot framework #1070

Open
aswathykrishnan92 opened this issue Dec 5, 2018 · 1 comment

Comments

@aswathykrishnan92
Copy link

aswathykrishnan92 commented Dec 5, 2018

So. I have brought up a mosquitto broker using mosquitto -v. I have subscribed to topic MQTTTest2 and published for which I am getting the publish message correctly.

I try to replicate this via robot framework. I am able to publish a message just fine. But when I try to subscribe to the topic, I am getting a socket exception

1544001640: Sending PINGRESP to mosqsub|12144-BLRKEC334
1544001654: New connection from 127.0.0.1 on port 1883.
1544001654: New client connected from 127.0.0.1 as `g:qmePxeTV?=tmm7_?22Y9nZD2
aoGIQk[M[FhiQnB>v\A8\[Z64AF>\tbPx3K (c1, k60).
1544001654: No will message specified.
1544001654: Sending CONNACK to `g:qmePxeTV?=tmm7_?22Y9nZD2A?aoGIQk[M[FhiQnB>v\
\[Z64AF>\tbPx3K (0, 0)
1544001654: Received PUBLISH from `g:qmePxeTV?=tmm7_?22Y9nZD2A?aoGIQk[M[FhiQnB
\A8\[Z64AF>\tbPx3K (d0, q2, r0, m1, 'MQTTTest2', ... (11 bytes))
1544001654: Sending PUBREC to `g:qmePxeTV?=tmm7_?22Y9nZD2A?aoGIQk[M[FhiQnB>v\A
[Z64AF>\tbPx3K (Mid: 1)
1544001654: Received PUBREL from `g:qmePxeTV?=tmm7_?22Y9nZD2A?aoGIQk[M[FhiQnB>
A8\[Z64AF>\tbPx3K (Mid: 1)
1544001654: Sending PUBCOMP to `g:qmePxeTV?=tmm7_?22Y9nZD2A?aoGIQk[M[FhiQnB>v\
\[Z64AF>\tbPx3K (Mid: 1)
1544001654: Sending PUBLISH to mosqsub|12144-BLRKEC334 (d0, q0, r0, m0, 'MQTTT
t2', ... (11 bytes))
1544001654: Sending PUBLISH to mosqsub|1540-BLRKEC3344 (d0, q0, r0, m0, 'MQTTT
t2', ... (11 bytes))
1544001654: Received DISCONNECT from `g:qmePxeTV?=tmm7_?22Y9nZD2A?aoGIQk[M[Fhi
B>v\A8\[Z64AF>\tbPx3K
1544001654: Client `g:qmePxeTV?=tmm7_?22Y9nZD2A?aoGIQk[M[FhiQnB>v\A8\[Z64AF>\t
x3K disconnected.
1544001654: New connection from 127.0.0.1 on port 1883.
1544001654: New client connected from 127.0.0.1 as 1589-BLRKEC3344 (c1, k60).
1544001654: No will message specified.
1544001654: Sending CONNACK to 1589-BLRKEC3344 (0, 0)
1544001654: Received SUBSCRIBE from 1589-BLRKEC3344
1544001654:     MQTTTest2 (QoS 2)
1544001654: 1589-BLRKEC3344 2 MQTTTest2
1544001654: Sending SUBACK to 1589-BLRKEC3344
1544001656: Socket error on client 1589-BLRKEC3344, disconnecting.

Below is the code I used:

Publish
    Connect     127.0.0.1
    Publish     topic=MQTTTest2   message=test message
    [Teardown]  Disconnect`
Subsribe and Validate
    Connect                 127.0.0.1  client_id=1589-BLRKEC3344
    Subscribe and Validate  topic=MQTTTest2    qos=1   payload=test
    [Teardown]              Disconnect`

The publish part is working fine and I am able to see the message in cmd window. But the subscribe part gives socket exception. Please not that I have given the clientID randomly with refererance to the Ping request from the other subscribers already started. I tried with and without client id. I am having the same issue. Please help me out?

@ralight
Copy link
Contributor

ralight commented Dec 20, 2018

From what I can tell, you're saying that mosquitto_sub and mosquitto_pub work ok, but the robot framework has problems, is that correct? If so, you might be better off asking for support there instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants