Skip to content
This repository has been archived by the owner on Oct 11, 2022. It is now read-only.

HACS Integration #31

Closed
darootler opened this issue Oct 1, 2019 · 25 comments
Closed

HACS Integration #31

darootler opened this issue Oct 1, 2019 · 25 comments
Labels
enhancement New feature or request

Comments

@darootler
Copy link

Hi!

This is not a issue, it's more an enhancement. Would it be possible to integrate your custom component into HACS?

As far i can see you only need to add a file called "hacs.json" to your repository with some content like this.

Regards
Richard

@DavidMStraub
Copy link
Owner

Hi,

cool, I was not even aware of this. In principle, I would actually like to open a PR to get this into HA itself, but I didn't have time in the last couple of months. In the meantime, HACS looks like an interesting option.

@darootler
Copy link
Author

darootler commented Oct 1, 2019

If you need some testing please let me know, looks like the effort for getting your component into HACS isn't that much.

Regards
Richard

@ltjessem
Copy link

I'd love to see it in HACS as well

@DavidMStraub DavidMStraub added the enhancement New feature or request label Nov 19, 2019
DavidMStraub added a commit that referenced this issue Nov 19, 2019
@DavidMStraub
Copy link
Owner

I added the JSON file now, I think all the other requirements were already met.

Testing is welcome! I haven't installed HACS myself yet.
However note that the changes I pushed today make the component only work with HA 0.102, which is only out as beta so far.

@anthonyangel
Copy link

Screenshot_20191119-224622

Your repo can be added to HACS without the hacs.json file - not sure if it's still needed as it's not in their integration docs. If you want to set a minimum required Home Assistant version that now goes into manifest.json

@DavidMStraub
Copy link
Owner

Cool, didn't know. I did add 0.102 to the manifest.json.

@darootler
Copy link
Author

I am not able to find Home Connect via HACS:

image
image

What i am doing wrong?

Regards
Richard

@anthonyangel
Copy link

In settings you need to add https://github.com/DavidMStraub/homeassistant-homeconnect as a custom repo

@DavidMStraub
Copy link
Owner

Right, I'll submit it as a default repo once we know it works (e.g. #37).

@darootler
Copy link
Author

Right, I'll submit it as a default repo once we know it works (e.g. #37).

I see.

It's working now with adding a custom repository.

Regards
Richard

@DavidMStraub
Copy link
Owner

Which HACS version are you using? It's not working for me yet

@darootler
Copy link
Author

Sorry, it's also not working for me. I can install it but i am receiving the following errors:

Component error: homeconnect - cannot import name 'CONF_CLIENT_ID' from 'homeassistant.const' (/usr/src/homeassistant/homeassistant/const.py)

Setup failed for homeconnect: Unable to import component

I am using HACS 0.17.3.

Regards
Richard

@DavidMStraub
Copy link
Owner

I suspect you are using HA 0.101 or earlier? The new updated integration only works with 0.102 or above (you can install homeassistant==0.102b2 with pip if you want to try the beta version).

@darootler
Copy link
Author

I am using HA 0.101.3 on Hass.io, i think i have to wait until 0.102 is available.

Regards
Richard

@holnburger
Copy link
Contributor

holnburger commented Nov 21, 2019

Im running Home Assistant 0.102.0 and HCAS 0.17.4, all updated versions to the latest release. Adding the repository of homeconnect works fine but when i try to insall it, I get the error message:
This repository version requires Home Assistant version 0.102.0

Edit: 0.102.0 was released this morning

@darootler
Copy link
Author

Im running Home Assistant 0.102.0 and HCAS 0.17.4, all updated versions to the latest release. Adding the repository of homeconnect works fine but when i try to insall it, I get the error message:
This repository version requires Home Assistant version 0.102.0

Edit: 0.102.0 was released this morning

Same here.

Regards
Richard

@holnburger
Copy link
Contributor

holnburger commented Nov 21, 2019

I just forked and and changed the dependent HA-version in the hcas.json, apperantly that's the only issue. Changed it to:

{ "name": "Home Connect", "domains": ["sensor", "binary_sensor", "switch"], "homeassistant": "0.102", "render_readme": true }

And it was working (instead of 0.102.0) - which is strange.

Edit: I created a pull request.

@DavidMStraub
Copy link
Owner

Thanks for the fix;

so is this actually working now for anyone with HA 0.102 and HA-HC 0.2.1?

For me the install silently fails and I don't know why, log:

Nov 21 22:00:25 hass hass[5469]: 2019-11-21 22:00:25 DEBUG (MainThread) [hacs.download.downloader] Donwloading https://raw.githubusercontent.com/DavidMStraub/homeassistant-homeconnect/v0.2.1/custom_components/homeconnect/.translations/en.json
Nov 21 22:00:25 hass hass[5469]: 2019-11-21 22:00:25 DEBUG (MainThread) [hacs.repository.integration.DavidMStraub.homeassistant-homeconnect] Downloading __init__.py
Nov 21 22:00:25 hass hass[5469]: 2019-11-21 22:00:25 DEBUG (MainThread) [hacs.download.downloader] Donwloading https://raw.githubusercontent.com/DavidMStraub/homeassistant-homeconnect/v0.2.1/custom_components/homeconnect/__init__.py
Nov 21 22:00:25 hass hass[5469]: 2019-11-21 22:00:25 ERROR (MainThread) [hacs.repository.integration.DavidMStraub.homeassistant-homeconnect] Download was not complete.
Nov 21 22:00:25 hass hass[5469]: 2019-11-21 22:00:25 ERROR (MainThread) [hacs.repository.integration.DavidMStraub.homeassistant-homeconnect] Download was not complete.

@DavidMStraub
Copy link
Owner

Stupid me, I didn't set 777 permissions on custom_components. So this issue can be closed no?

@darootler
Copy link
Author

For me it's working now.

Thank you!

Regard
Richard

@anthonyangel
Copy link

Working for me too, FWIW it might be worth adding your repo into the default store in https://github.com/hacs/default rather than having to add it in as a custom repo

@DavidMStraub
Copy link
Owner

Right, will do this now that I know it works. Thanks!

@darootler
Copy link
Author

Right, will do this now that I know it works. Thanks!

Is Home Connect already in the default HACS repository?

Regards
Richard

@DavidMStraub
Copy link
Owner

No, good point. I forgot that the PR wasn't merged due to a stray comma. I updated it and hope it'll be merged now.

@darootler
Copy link
Author

Nice, i think more people will start to use/support your integration if it‘s available within the default repositories.

Regards
Richard

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants