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

Error: no JSON at incomin... #84

Open
jensrossbach opened this issue Dec 15, 2019 · 18 comments
Open

Error: no JSON at incomin... #84

jensrossbach opened this issue Dec 15, 2019 · 18 comments

Comments

@jensrossbach
Copy link

I'm using alexa-remote2 Echo node to activate Bluetooth connection to my soundbar upon a certain trigger (in my case when Echo starts playing music). This worked fine in the beginning but suddenly stopped working and I get an error message "Error: no JSON at incomin..." (cannot see whole message as it is cut at the end).

I'm using proxy authentication with seems to be fine. The error is available in the latest version (3.7.0).

@jensrossbach
Copy link
Author

Additional information: When I restart my flows, everything works again for some time, but then some time later, the error reappears.

@bwims
Copy link

bwims commented Jan 24, 2020

I have found that this error occurs for me when I send multiple instances of the same command, so that, e.g. I try to disconnect bluetooth when it is already disconnected. Is it possible you are doing this under certain conditions?

@jensrossbach
Copy link
Author

@bwims yes that could be the case (however I have no proof for this). Still I would consider this a bug.

@bwims
Copy link

bwims commented Feb 20, 2020

I use the RBE node to block repeated commands unless the payload changes.

@jensrossbach
Copy link
Author

I've meanwhile changed my flow to avoid sending the same command subsequently to the alexa nodes but the error still occurs. Seems to be less often now but still happening.

@Myzhar
Copy link

Myzhar commented Apr 30, 2020

Have you found a solution to this problem? I continue to have random "NO JSON" error

This is the flow that I'm testing:
Screenshot from 2020-04-30 14-54-56

Often the last node gets the NO JSON error, but sometimes it happens also for the others

@bwims
Copy link

bwims commented Apr 30, 2020 via email

@Myzhar
Copy link

Myzhar commented Apr 30, 2020

Please update the issue if you find something new

@bwims
Copy link

bwims commented Apr 30, 2020 via email

@tekybrit
Copy link

tekybrit commented May 1, 2020

I have not seen this error since I inserted a delay node to limit the message rate.
This leaves Alexa enough time to complete one message before she gets the next message.
In my use case, limiting the message rate to one every 3 seconds works fine.

@jensrossbach
Copy link
Author

I don’t think that there are so high frequent requests to the echo nodes in my flow. I’m just switching on Bluetooth connection when the echo starts playing music and switching off Bluetooth connection one minute after the echo stops playing music. Still I get this error from time to time.

@Myzhar
Copy link

Myzhar commented May 1, 2020

I tried suddenly with delays, but they are not useful. What instead helped me is using a catch node that catches the error and triggers the node again after a little delay.
I add a catch node for each Amazon node.

@jensrossbach
Copy link
Author

If this actually helps, then it should be implemented in the nodes themselves as a recovery mechanism.

@586837r
Copy link
Owner

586837r commented May 3, 2020

Amazon sends a "Rate exceeded: Too many requests." in Myzhars flow. I'm thinking about a way to handle this generally. (And to have more helpful errors.)
Also keep in mind that if possible you can also send a command sequence at once with the Node option instead of chaining them.

@Myzhar
Copy link

Myzhar commented May 3, 2020

@586837r this is interesting. I will investigate how to do it

@nicedevil007
Copy link

What is the actual status of this issue? I still get this error.
@Myzhar How did you solve this with the catch node?

In my case I just want to set the volume to a special amount.

If the error was triggered I can't get anything beside the error itself. So how did you reenter the given value until it is sent successfully?

@obaldius
Copy link

obaldius commented Nov 17, 2020

What has solved the problem to me is using de Node tool whithin the Alexa Routine Node instead of branching the flow in Node Red itself. You can choose between Serial or Parallel execution whithin that action

@obaldius
Copy link

obaldius commented Nov 18, 2020

I must add, I believe it's just a "Too Many Requests" error. If you chain several Alexa nodes in serial execution, putting a delay of 1.5 - 2 seconds between them should solve the issue. Putting them in parallel greatly increases the risk of such error. For parallel request, better use the Node setting whithin the Routine Node

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

7 participants