Google Cast error - Unable to find a view with path xxxx

My problem is still that we need to authorize through cast.home-assistant.io, which is a manual process. I really hope that it can be automated somehow, so we just have to call the ‘cast.show_lovelace_view’ and the path needed.

I’ve never needed to do that

Then I need your expertise :+1:… I Simply can’t get it working without.

So without doing anything you can just go to the develop tool, services and select the ‘cast.show_lovelace_view’ and then call the entity of your nest hub using the View either by name or number?

This one here works with iOS or anything from Lovelace:

              - type: custom:button-card
                icon: mdi:home-assistant
                name: System
                tap_action:
                  action: call-service
                  service: script.casthomeassistant
              - type: custom:button-card
                icon: mdi:weather-cloudy
                name: Weather
                tap_action:
                  action: call-service
                  service: script.castweather

Script looks like this:


casthomeassistant:
  alias: Cast Home Assistant
  sequence:
  - data:
      entity_id: media_player.lounge_room_tv
      view_path: home_assistant
    service: cast.show_lovelace_view
castweather:
  alias: Cast Weather
  sequence:
  - data:
      entity_id: media_player.lounge_room_tv
      view_path: weather
    service: cast.show_lovelace_view

Other way is (only works on a cast device like chrome) You have to select the device and then you can cast to it:

          - type: entities
            title: Chromecast Control
            show_header_toggle: false
            entities:
              - type: cast
                name: System
                view: "home_assistant"
                hide_if_unavailable: false
              - type: cast
                name: Weather
                view: "weather"
                hide_if_unavailable: false

So I was excited to get home and try your approach and… voila, it worked on the very first try.
Unfortunately I kept it running over night, and this morning when I wanted to try again - same script, it “failed”. It shows the Home Assistant luvs Nabu Casa and then it says ‘Connected’. While that might be true, it still doesn’t show the lovelace view I want to cast.
So once again I have to open a Browser, head to cast.home-assistant.io and authorize and cast a lovelace view. When that is done, then I can fire your script and it will work. Also with different views - probably until the authorization is “expired” :frowning:

I was having the same problems. I gave up using the cast.show_lovelace_view service. Instead I use CATT : Using CATT and it has been working just great.

1 Like

It can take 30 seconds after it shows connected to cast the card… Just leave it there and wait a bit.

I have now waited for more than one hour and it still shows the luv screen and ‘Connected’.
So there must be something else wrong.

Do I need to set up some auth_trust to leave out the authorization process with cast.home-assistant.io, could that be it or don’t you have that in your conf?

I don’t have anything in my config.

Damn :frowning:

Then I’m lost…

Try using a path number rather than a a name like mentioned in this post above Google Cast error - Unable to find a view with path xxxx

It stopped altogether for me, I simply see “Connected” and nothing else.

anyone else having this issue?

I rebooted both the hub and the server.

@Maxi1134 I can confirm this has also happened to my system. I am using the Nabu-Casa generated URL.

I would also like to add that i am now using version 0.106.2. Same issue.

Same results for me, while using Nabu Casa, but having your own reverse proxy doesn’t make any difference either. Casted through front-end and through https://cast.home-assistant.io/ gives the same result.

I am only able to fire up “HOME” which doesn’t reflect the HOME i built earlier. Any other page (even with numbers in path/url) ends up with “Error: Unable to find a view with path X”.

1 Like

I have the same issue since upgrading. Google home hub says Connected, but never progresses past this. Cast can no longer access my views (cast.nabucasa page or Dev/Services) other than a ‘home’ one that looks like an ‘all entities’ page that’s not an actual view I have configured myself. Using Nabu Casa URL for access.

The (only) view being casted looks very much like the deprecated “states” view - found in your.ha.io.url/states: https://github.com/home-assistant/home-assistant-polymer/issues/4459

That would explain why the so-called home being casted is totally different than the home you have built.

i use Duckdsn, i just have old home. I have wiped with old snapshot and i have always the problem. It’s https://cast.home-assistant.io problem.

Just bumping the thread for posterity.

I have the exact same issue.

Can only cast default_view from the service.

Only see HOME using https://cast.home-assistant.io/

All other views give the “Error: unable to finve view …” When called by service.

currently running version 0.104.3

Suggest you all post here https://github.com/home-assistant/home-assistant-polymer/issues/4614

This has also stopped working for me… not sure when.

1 Like

So i actually got a bit further. A friend of mine just got his first Google Nest Hub, so I was thinking that I would give the cast function another shot, on a fairly new installation of Home Assistant. The installation is pretty similiar to mine. Same hardware and same version.

I opened up the Services and made a service call and boom, same issue. Says Connected and nothing happens. Hmm, I then tried using the media_player.turn_off so that the stream stopped and tried the cast.lovelace again. Bing, there we go, it connected straight away. Without using the cast.home-assistant.io. What the heck? I’ve been trying that for weeks now. What is the difference here?

Finally it came to my mind, that we didn’t set up the Nabu Casa subscription yet, but we went with the DuckDns.org option. So when accessing Home Assistant on the local lan, we had to access the site with https://192.xxx.xxx.xxx.

I didn’t set up that part in my home, since I didn’t want to open any ports in my Firewall in the first place. I’ve used the Nabu Casa subscription from almost the beginning. Unfortunately, that doesn’t help me with the lan when I access my Home Assistant instance. It will still be http://192.xxx.xxx.xxx.
So whenever I try to fire the cast.lovelace from http, then it won’t work, unless I authorize via the cast.home-assistant.io page. But if I head directly to the Nabu Casa Remote page, then I can do it without. Unfortunately that doesn’t help me me much when I try to automate this.

Question is, can I somehow get the certificate stored locally that is also being used via Nabu Casa, or will I have to use DuckDns or create a self-signed certificate to get this https working on my lan as well?