Comments (13)
Opened PR: #108
from homebridge-hatch-baby-rest.
I am on my phone currently but I just opened a PR to address this issue. It should be noted I have very little context 😅 and working off some assumptions but the maintainer should get the idea and be able to edit as needed.
from homebridge-hatch-baby-rest.
The fix from #108 has been released in 4.0.1
. Please let me know if this resolves your issues @parsap
from homebridge-hatch-baby-rest.
@dgreif major thanks for this and the ring fix last weekend - you are the best of the best of the best!
from homebridge-hatch-baby-rest.
Confirmed fixed!
from homebridge-hatch-baby-rest.
Same error on my instance. Looks like the OAuth flow is failing. Guessing their API is either down or it changed...
from homebridge-hatch-baby-rest.
Looks like the following header needs to be added to each request.
USER_AGENT: "hatch_rest_api"
from homebridge-hatch-baby-rest.
… well actually… let me try to understand this a bit more
from homebridge-hatch-baby-rest.
Yes, that is correct. All api requests now require the above mentioned header, including the login request.
from homebridge-hatch-baby-rest.
@brentleeper nice discovery! Hopefully the fix is just as simple as adding that header to the requests made by this plugin.
I'd do a PR myself, but I'm not at all familiar with developing these plugins or even the language used here.
from homebridge-hatch-baby-rest.
The fix from #108 has been released in
4.0.1
. Please let me know if this resolves your issues @parsap
I can personally confirm 4.0.1 is working again on my install.
Thanks again for quickly publishing this update! Couldn't live without it.
from homebridge-hatch-baby-rest.
So just to be clear - the 500s were due to a bug on our end; now fixed. The user-agent is a bit of a red herring: it could have been set to "bobs-your-uncle" and that would have avoided the bug.
The bug manifested because we are implementing some rate-limiting. Someone mentioned being in a infinite loop of 500s - there are quite a few people using this library in an infinite loop of 200s (successful logins). There are clients out there sending tens of thousands of login attempts per day. This is one of the things that prompted us to implement rate limiting!
We meant to look over the project and submit some pull requests to fix the infinite-login-loop problem, but we just haven't had the time. It would be great if someone could figure it out. The login tokens are valid for years. But be aware that as soon as we get this code spruced up the infinite login loops will be getting 429 responses, regardless of user-agent.
from homebridge-hatch-baby-rest.
Thanks for the heads up @kenwdelong, and sorry for the infinite loop login attempts! I didn't realize that was happening and haven't seen anything like that on my end, but I would gladly accept some PRs if you find the offending code.
from homebridge-hatch-baby-rest.
Related Issues (20)
- Error connecting to API (403 Forbidden) HOT 2
- No Volume Control HOT 1
- Consider switching sound selector device type HOT 1
- Restore 2 Support HOT 14
- Only on/off switch appearing for Rest+ HOT 2
- Tapping on the Brightness Switch Does Not Set Brightness to 0
- Use Lightbulb instead of speaker to allow Homekit control HOT 1
- Rest+ Homekit Display HOT 1
- Only getting on/off on Rest Gen2 HOT 9
- I have had this pop up in and out again, I think the issue is if there is ANY interruption to the AWS back end a new token is issued. HOT 1
- Plugin crash after latest Rest updates HOT 3
- Ignore `alexa` device type
- 4.3.1 removes Hatch Rest+ Gen 1 and 2 devices HOT 5
- 4.3.2 Breaks Rest2 support HOT 4
- 4.3.1 and up Break Rest+ HOT 2
- Added to homekit but buttons do nothing (rest+ 2nd gen) HOT 2
- Issue installing on Synology DSM7 package, continues to fail HOT 2
- Command for touch ring favorites on Hatch Rest bluetooth? HOT 4
- Doesnt Show Devices - restoreIot HOT 13
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from homebridge-hatch-baby-rest.