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

Add service to update core location #24328

Merged
merged 2 commits into from
Jun 7, 2019
Merged

Conversation

balloob
Copy link
Member

@balloob balloob commented Jun 5, 2019

Description:

Add a service to update the location of Home Assistant in the core config. This will make it easier to use Home Assistant in RVs.

Checklist:

  • The code change is tested and works locally.
  • Local tests pass with tox. Your PR cannot be merged unless tests pass
  • There is no commented out code in this PR.
  • I have followed the development checklist

If the code does not interact with devices:

  • Tests have been added to verify that the new code works.

@ghost
Copy link

ghost commented Jun 5, 2019

Hey there @home-assistant/core, mind taking a look at this pull request as its been labeled with a integration (homeassistant) you are listed as a codeowner for? Thanks!

This is a automatic comment generated by codeowners-mention to help ensure issues and pull requests are seen by the right people.

"""Test setting the location."""
await async_setup_component(hass, 'homeassistant', {})
events = async_capture_events(hass, EVENT_CORE_CONFIG_UPDATE)
assert hass.config.latitude != 10
Copy link
Member

Choose a reason for hiding this comment

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

I'm confused on why you're asserting it's not 10 and 20... shouldn't this either assert it's some other value than what is being set OR assert that it's NOT 30 and 40?

Copy link
Member Author

Choose a reason for hiding this comment

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

You are right, I should have done not 30 and 40, just to make sure my update works.

@andrewsayre andrewsayre merged commit 7c5da67 into dev Jun 7, 2019
@delete-merged-branch delete-merged-branch bot deleted the update-core-config-service branch June 7, 2019 14:09
@balloob balloob mentioned this pull request Jun 26, 2019
@gordonthree
Copy link

Description:

Add a service to update the location of Home Assistant in the core config. This will make it easier to use Home Assistant in RVs.

Hi @balloob ... thanks a lot for this update! I'm using HA in an RV as well. I'm wondering, can set_location be expanded to allow setting the time zone and elevation as well?

@frenck
Copy link
Member

frenck commented Jul 10, 2019

Thank you for reaching out. We use GitHub for tracking issues, not for providing support.

If you are in need of support, you should try our Community Forum or join our Discord chat server.

You are more likely to get the answer you are looking for in those places.

Thanks! 👍

@home-assistant home-assistant locked and limited conversation to collaborators Jul 10, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants