-
-
Notifications
You must be signed in to change notification settings - Fork 31.7k
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
Point add redirect uri #101967
Closed
Closed
Point add redirect uri #101967
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wait, why doesn't this implement an OAuth flow?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes but not using home-assistant's oauth.
I've been trying to implement using the guidelines but I don't quite understand all parts and have not found an integration that does it by the book either.
The userbase for Point is quite small, perhaps it is better to pull this integration and use hacs instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are many integrations doing oauth flows? They all use the same constructs.
The thing is, the redirect URL should not even be a question... With the default flows, it will handle that for the user.
I do not understand what the latter reasoning has to do with anything? Even as a HACS integration, one should be using the right constructs, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you please name a few for reference.
The reasoning is that I don't feel I have the time to keep up with the high code quality standards. I did another PR #100843 but that was rejected due to 1. I updated the yaml 2. Once I've rewritten the flow to not use yaml the pr should be split up, this is the first stage of the split.
I feel that I've already spent too much time on this, implementing "the right" oauth flow will take me another 6-8 hours which I don't have atm. Either accept this pr (with guidelines on how to make it appropriate) or pull support for Point (the integration is currently broken as Minut have change the oauth flow).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Search for
AbstractOAuth2FlowHandler
usage in config_flow.py files across our codebase, we currently have 26 integrations implementing it.Some ones that have been implemented fairly recently (and thus had recent reviews) are Twitch, Fitbit and YouTube.
This has nothing to do with coding standards. 🤷
I really want to help, but let me be very clear: These kinds of statements don't help and are not a factor in merging PRs. If anything, they make me not wanting to help out and I don't see how this would be fruitful in any way.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking upstream at the minute point docs, they implement a really standard OAuth2 flow, which we fully support out of the box. The amount of code used by this integration can be reduced quite a bit and simplified.
Should not take more than 1-2 hours to fix/adjust I think (including import of existing configuration).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds great, I'll have a look at it!