-
Notifications
You must be signed in to change notification settings - Fork 636
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
Fixed size json payload & other WS bugfixes #1843
Conversation
If anyone can test the tree itself (i.e. checkout the mcspr:web/fixed-size-json-v5), that would be greatly appreciated. Some notes about the ws module, as the main changes are there... The goal is to chain send_callback_f funcs so that it firstly bulks up some known constants in a single object root and sends it (...Visible is an obvious one, since it only depends on the module being present). But, after that, callbacks need to be called separately again. Some state / stage var can control this, maybe... And the final one sending sensor data. |
This PR fixes my problems!! well done @mcspr |
I'm still facing this #1731 because I don't get |
Great. Need to also check Windows / Chrome situation, if queuing does work properly with delayed acks (...and the main reason single big json was used in the first place) OT: I think we determined in the #1822 that indexing in the hwl sensor needs to be customizable, nothing in the web specifically. That way, it will also not be there in mqtt reports, thingspeak etc. And I kind of missed whether you wanted to add that yourself or not 🤔 |
I tested it using mac os and chrome |
Note-to-self: One alternative is to use custom linked list class. |
Congratulations @mcspr, awesome PR!! |
@mcspr does this solve the double authentication request for credentials on Safari? |
@ruimarinho nothing about the auth was changed here. do you mean that it is showing auth pop-up twice? |
@mcspr indeed, that. For some reason I made the connection between the WS connection and the double digest auth, but I haven't looked at the code yet. Maybe we can remove the script call to /auth and just depend on session cookie to pass on the auth header? |
Probably, yes. It is pretty basic right now, |
Resolve #1731 (?), #1823 (original question), #1824, #1831
cc @gernst48 @tonilopezmr @Interpyme @ruimarinho
I'll clean it up later from some experimental leftovers and fix some dumb behaviour (like, not immediately sending sensor readouts)
POW runs this reasonably well. Refresh does not crash 🤷♂
(but I could not make it crash even with old builds. must be something related to OS / browser / network conditions)
And probably try again to rethink how to push static data before everything else, to reduce total number of messages (although, it is smaller than before #1387 / 1.13.3)
Keeping ArduinoJson 5 for now.