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

Fix outdated api url in noaa_tides #39370

Merged
merged 3 commits into from
Sep 1, 2020

Conversation

jdelaney72
Copy link
Contributor

Proposed change

The external web service used by the noaa_tides platform moved its
api to a new url. The pypi package used to fetch data (py_noaa) still
points to the old/broken url. It is outdated and has been
replaced - no further development is planned.

I've updated the sensor to use the replacement package
(noaa-coops==0.1.8). The new package uses a Station class to fetch
tide data so I changed setup_platform to create a station instance
and changed the sensor's update function to use the station class
to get data.

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

Example entry for configuration.yaml:

# Example configuration.yaml
sensor:
  - platform: noaa_tides
    station_id: 8721164

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.
  • 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:

@homeassistant
Copy link
Contributor

Hi @jdelaney72,

It seems you haven't yet signed a CLA. Please do so here.

Once you do that we will be able to review and accept this pull request.

Thanks!

@jdelaney72 jdelaney72 marked this pull request as ready for review August 28, 2020 23:01
Copy link
Member

@frenck frenck left a comment

Choose a reason for hiding this comment

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

Thank you for your contribution thus far! 🎖 Since this is a significant contribution, we would appreciate you'd added yourself to the list of code owners for this integration. ❤️

Please, add your GitHub username to the manifest.json of this integration.

For more information about "code owners", see: Architecture Decision Record 0008: Code owners.

@frenck
Copy link
Member

frenck commented Sep 1, 2020

Awesome, thanks @jdelaney72!

Great first-time contribution! 👍

@frenck frenck merged commit 762d735 into home-assistant:dev Sep 1, 2020
leikoilja pushed a commit to leikoilja/core that referenced this pull request Sep 6, 2020
* Fix outdated dependency in noaa_tides

* Catch exceptions when instantiating new Station

* Add myself to codeowners
@jdelaney72 jdelaney72 deleted the fix-noaa-tides-url branch March 11, 2021 01:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

noaa sensor timeout
4 participants