8000 Fix netgear NoneType and discovery by starkillerOG · Pull Request #57904 · home-assistant/core · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Fix netgear NoneType and discovery #57904

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

Merged
merged 1 commit into from
Oct 18, 2021

Conversation

starkillerOG
Copy link
Contributor

Breaking change

Proposed change

If an communication error occurs with the netgear router, the upstream lib throws an error in the log and returns None.
This None value caused an error in the HomeAssistant integration. This PR catches the None type properly.

Some routers do not appropriatly supply the modelname in the SSDP discovery infromation ModelNumber tag, therefore also check the ModelName tag. (Some other routers do ModelName not properly and have ModelNumber correctly).

Type of change

  • Dependency upgrade
  • Bugfix (non-breaking change which fixes an issue)
  • New integration (thank you!)
  • New feature (which adds functionality to an existing integration)
  • Breaking change (fix/feature causing existing functionality to break)
  • Code quality improvements to existing code or addition of tests

Additional information

Checklist

  • The code change is tested and works locally.
  • Local tests pass. Your PR cannot be merged unless tests pass
  • There is no commented out code in this PR.
  • I have followed the development checklist
  • The code has been formatted using Black (black --fast homeassistant tests)
  • Tests have been added to verify that the new code works.

If user exposed functionality or configuration variables are added/changed:

If the code communicates with devices, web services, or third-party tools:

  • The manifest file has all fields filled out correctly.
    Updated and included derived files by running: python3 -m script.hassfest.
  • New or updated dependencies have been added to requirements_all.txt.
    Updated by running python3 -m script.gen_requirements_all.
  • For the updated dependencies - a link to the changelog, or at minimum a diff between library versions is added to the PR description.
  • Untested files have been added to .coveragerc.

The integration reached or maintains the following Integration Quality Scale:

  • No score or internal
  • 🥈 Silver
  • 🥇 Gold
  • 🏆 Platinum

To help with the load of incoming pull requests:

@probot-home-assistant
Copy link

Hey there @hacf-fr, @Quentame, mind taking a look at this pull request as it has been labeled with an integration (netgear) you are listed as a code owner for? Thanks!
(message by CodeOwnersMention)

@starkillerOG
Copy link
Contributor Author

ready to be merged as soon as the tests pass

@MartinHjelmare MartinHjelmare changed the title fix netgear NoneType and discovery Fix netgear NoneType and discovery Oct 17, 2021
Copy link
Member
@MartinHjelmare MartinHjelmare left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

@MartinHjelmare
Copy link
Member

Will this apply cleanly to rc branch without merge conflicts? Then we could tag it for a patch release.

@starkillerOG
Copy link
Contributor Author

@MartinHjelmare Yes it schould merge cleanly.
Would be greath if it could be in the next patch release.

@MartinHjelmare MartinHjelmare added this to the 2021.10.7 milestone Oct 18, 2021
@MartinHjelmare MartinHjelmare merged commit 04f51e5 into home-assistant:dev Oct 18, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Oct 19, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bugfix by-code-owner cherry-picked cla-signed Hacktoberfest integration: netgear small-pr PRs with less than 30 lines. smash Indicator this PR is close to finish for merging or closing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants
0