Custom_updater and tracker-card not reporting correctly

Tryed that, getting all sorts of errors in log…

Unable to install package pyupdate==0.2.15: The directory '/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Command "/usr/local/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-677xonoc/pyupdate/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-9nrl3tcs/install-record.txt --single-version-externally-managed --prefix  --compile --user --prefix=" failed with error code 1 in /tmp/pip-install-677xonoc/pyupdate/

I’m running homeassistant in docker

with that configuration, you are not tracking any cards. https://github.com/custom-components/custom_updater/wiki/Installation#configuration-option-track

The file needs to exist for this to work… most (if not all of these files does not exist).
Please read the configuration note for that option https://github.com/custom-components/custom_updater/wiki/Installation#configuration-option-card_urls

If you run this in Docker there is not much you can do, this component rely on pyupdate to work, restarts usually work :man_shrugging:

Gonna try few more restarts… It did work till 2.7.0 version, now I’m getting those error’s and can’t sort it out…
In the meantime I have changed configuration and commented those cards

custom_updater:  
  track:
    - components
    - cards

  # card_urls: 
    # - https://raw.githubusercontent.com/kuuji/button-card/0.0.2/tracker.json
    # - https://raw.githubusercontent.com/kalkih/mini-media-player/master/tracker.json
    # - https://raw.githubusercontent.com/kalkih/mini-graph-card/master/tracker.json
    # - https://raw.githubusercontent.com/rdehuyss/homeassistant-lovelace-google-calendar-card/master/custom_updater.json

the files exist, but with a .js instead of the full .json. I tried with just the .js but it seemed the break the component completely

Hmmm… the component works when I put version 2.7.0, no matter how I update (from tracker card, or manualy from github), it just stops working after restart.

Not initializing custom_updater because could not install requirement pyupdate==0.2.15
Setup failed for custom_updater: Could not install all requirements.

 Unable to install package pyupdate==0.2.15: The directory '/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
    The directory '/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
    Command "/usr/local/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-fn1w8dw4/pyupdate/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-83zuxu41/install-record.txt --single-version-externally-managed --prefix  --compile --user --prefix=" failed with error code 1 in /tmp/pip-install-fn1w8dw4/pyupdate/

half of my cards aren’t displayed, not to cross post, here’s my post at the issue tracker:

which is solved now… missed the .js extension for these cards while copying config strings from another card… sorry

There is a BIG difference between .js and .json (They are not the same at all.)
only use the setting card_urls if the developer of that specific card has created a “tracking file” for it.

That was from before I moved it to pyupdate, which image are you using for docker?

I’m on latest 0.79.3 homeassistant.

The error looks like a permission error when installing package with pip… that is weird that you have that in a docker setup, and it should also affect other components as well…
Do you have any other custom_components installed?

Only one more - variable.py

That one does not use an external lib, so not really comparable :confused:

Can you add an issue here:
https://github.com/custom-components/custom_updater/issues
So can test on Docker and follow up there

Shure, no problem. Thank you.

That seems rather stange then because some of those cards have .js extension but have got .json in the instructions on GitHub. see below example.

and the raw file for the card is in fact a .js So I dont know what is going on

And for that card, it looks OK, but you had 5 more in the list (I tested all of them now, and it’s only one that do not give a 404 error) :slight_smile:

Ok, so I guess the authors of those other cards have mistakes in their Git instructions…? Other people seem to be using them ok.

the mini media player:

vertical style card:

button card:
image

so… all these instructions point to a .json when in actual fact the file is a .js. Are other people using the tracker for these cards successfully?

I am.

Here is my config yaml entries (I use some same and some different to you)

# Custom Component Updater
custom_updater:
  show_installable: false
  hide_sensor: false
  track:
    - components
    - cards
    - python_scripts
  component_urls:
    - https://raw.githubusercontent.com/pnbruckner/homeassistant-config/master/custom_components.json
  card_urls:
    - https://raw.githubusercontent.com/kalkih/mini-media-player/master/tracker.json

Then in lovelace yaml:

title: Home
resources:
  - url: /local/tracker-card.js?v=0.1.5
    type: js
  - url: /local/custom-lovelace/upcoming-media-card/upcoming-media-card.js?v=0.2.1
    type: js
  - url: /local/custom_ui/dark-sky-weather-card.js?v=1
    type: js
  - url: /local/mini-media-player.js?ver=0.8.3
    type: module
  - url: /local/column-card.js?ver=7221e1
    type: js
views:

Note the above resources in Lovelace is right at the top of the yaml file.

Then I show the custom tracker with:

          - type: custom:tracker-card
            title: Custom Card Updates
            trackers:
              - sensor.custom_card_tracker
              - sensor.custom_component_tracker

and it looks like this:
image

1 Like

I have the same code except that the type is ‘module’ as per the instructions for the latest version on his Git

I think you might want to check that. I see type js here for the custom tracker card https://github.com/custom-cards/tracker-card
(Also - mine is working!)

sorry, I meant underneath the mini_media_player entry, but I didn’t look properly and you actually have module as well

The URL’s are getting the version data from a JSON file - you can plug the URL into a web browser and you will see that.
The Lovelace is running a javascript (js) file.
So the version information that is available comes from json and the installed info is in the ?v= info… that’s how it populates the tracker card.