Closed jackjonez666 closed 1 year ago
Same for my R2M station.
I can confirm the issue. The process that was up for > 30 days cannot receive messages from MQTT
ERROR Failed to connect to MQTT: bad username or password
I am in the same situation. Ecoflow has made some changes. I must once again immerse myself in examining API calls with greater depth and detail 🤦🏻♂️ I will review it when I have sufficient time available.
I experience the same issue. I wonder what they changed as the oauth 2.0 still is successful.
You can get it back working by adding the following client id to MQTT:
ANDROID_UUID.randomUUID().toString().toUpperCase(Locale.ROOT)_userId
You can get it back working by adding the following client id to MQTT:
ANDROID_UUID.randomUUID().toString().toUpperCase(Locale.ROOT)_userId
it's either not working or I'm trying in the wrong place.
self.client = mqtt.Client(client_id=str(uuid.uuid4()).upper()) #this leads to the same results
Have you checked the solution on your own?
You can get it back working by adding the following client id to MQTT:
ANDROID_UUID.randomUUID().toString().toUpperCase(Locale.ROOT)_userId
Unfortunately, It does not work for me as well. I tried to add my user ID:
2023-03-15 18:28:43,804 INFO Connecting to MQTT Broker mqtt.ecoflow.com:8883 using client id 19858457-7D10-491E-BBB4-00F8E5F500BE_XXXXXXXXXXXXXXXXXXX
2023-03-15 18:28:44,574 ERROR Failed to connect to MQTT: bad username or password
The most interesting thing is that the mobile app on iOS is still working even though it wasn't updated at any recent time.
Here is one package doing a similar connection, which seems to have been fixed:
https://github.com/mmiller7/ecoflow-withoutflow/commit/3c81886e2a311c7ff076ccbee1829e36759d0c9d
OK. It works when generated this way: clientid ="ANDROID" + str(uuid.uuid4()).upper() + "_" + self.user_id log.info(f"Connecting to MQTT Broker with client_id: {client_id}") self.client = mqtt.Client(client_id=client_id)
I can confirm the above works for me. Commenting out line 97 and replacing it with the above. Two caveats though. Need to add the uuid package. Also, the 'user_id' is in fact the value from the bearer token stage, on line 44. So I added the user_id to the EcoflowAuthentication & EcoflowMQTT classes. I'd fork the code but my version is a little bastardised to take values from the Smart Home Panel as well as my Delta Pro. In all honesty I should just run the same container with two configs for that lol
Thanks, I'll implement the fix later today.
I can confirm the above works for me. Commenting out line 97 and replacing it with the above. Two caveats though. Need to add the uuid package. Also, the 'user_id' is in fact the value from the bearer token stage, on line 44. So I added the user_id to the EcoflowAuthentication & EcoflowMQTT classes. I'd fork the code but my version is a little bastardised to take values from the Smart Home Panel as well as my Delta Pro. In all honesty I should just run the same container with two configs for that lol
Here we go) I'm doing exactly the same for Smart Home Panel. I still didn't commit the code to my fork as I need to clean it up and refactor a bit.
Thanks, I'll implement the fix later today.
Great work. Slava Ukraïni! 🇺🇦
🇺🇦
Heroyam Slava!
Thanks for this! The new release is ready.
Oops, it seems that I have created a new bug (
Finally, it works. Thanks again.
It seems something changed within the Ecoflow web architecture (needed to relogin with the phone etc) and since some hours, the tool is failing (wrong username/password).