#How do you debug issues like this?
1 messages ยท Page 1 of 1 (latest)
I'm pretty sure it's from this:
- service: system_log.write
data:
level: info
message: >
"Playing {{ show_title }} - Shield= {{ shield_id }} App_State= {{ states(shield_id) }}"
So what's the proper way to dump the states of an entity in a log?
If I remove, specifically the "states(shield_id)", then I make it further and it dies on this condition:
- conditions:
- condition: template
value_template: "{{ is_state_attr(shield_id, 'app_id', 'com.plexapp.android') }}"
use the dev tools teplate tool to make sure your templates are evaluating how you think they are
I'm just not sure how to bridge the gap between template and blueprint here, since the entities are provided from the blueprint ui
hard coding, i guess?
blueprint is still yaml script behind the scenes which you can open and view in notepad or something.
maybe when you do a states lookup, the entity needs to be in single quotes?
states('shield_id')??
it's a variable being set in a "variables:" block, so that it expands the input into a variable readable by the template
{{ states('sensor.desktop_activewindow_2') }}
!input shield_player
hrmm
where the shield player is a media_player
yeah, I'm not sure.
Like- I'm 100% sure this is all doable, I just need to figure out what the machine sees at different times and that's the hardest part, it seems
well, as I said... I have been using chatGPT to help troubleshoot my templates and scripts.,
it is not always right, but often provides a good idea to look more into
paste your code and the error and ask it to help you find the issue...
just don't put in sensative data
at best it'll help solve the issue, at worst, you'll get some good ideas to google.
haha
Lol yeah, that's my typical expectation as well. It usually gets close enough to tell you what to google
fwiw, I used chatgpt first. It had some really unhelpful responses
It's literally giving me back the same input I give it saying that it should work, so ๐คทโโ๏ธ
I asked, and it suggested that maybe the shield_id is being treated as a dictionary instead of a string or entity ID
yeah, it likely is because it's a target selector from the input
is there a way to grab the entity id off of a target selector with one entity?
I'm not sure
I personally like to reverse engineer blueprints until I have a good understanding of them, and then build a more tailored solution for my needs. more customizable and easier to troubleshoot imo.
Yeah, I hear you. It's been super hard finding exact references for things like this.
The documentation typically gives the most basic examples and everything else is figuring it out.
I had to install MQTT explorer before I was able to figure out the missing params in my payload to get device discovery to work ๐ฆ
yeah... Homeassistant is mostly researching and troubleshooting and a little bit of enjoying your automations. lol
but, I love it, and for my needs it is the best available option.
Yeah, it's super rad! I am an advocate, for sure
coming from the gamedev world, it's kind of in the "unreal" space- where it's really powerful, but the documentation might turn ppl away
I used to have smartthings... which was eh...
Then samsung bought it and it was gross.
found this and have been super happy with it
Yeah, it feels so good to actually be in control of your smart home
right?
I bought a multi relay and hooked up my dumb garage over the weekend
large learning curve, but good payout at the end
even wrote a script to hold down the button until the door is closed because one of the eyes is broken
i love the control
nice
and right now, I'm making buttons to play tv shows haha
I just got done writing a script to log the amount of youtube time on the tv, and to deny the app after a certain amount of time each day
lol
take that kids!
lol poor kids are gonna have to learn their own whiley ways to get around it now
let the arms race of figuring shit out commence ๐
love it
Anyways... gotta run. Glad you sorted out your issue. Happy automating!
i remember running a 50ft ethernet cable from my sister's room when my dad shut me off haha
lol
yeah! thanks for the help!
my dad put a bios password on our first pentium 386...
I figured out how to reset the bios via motherboard switch... ๐ฎ
that's extreme lol
he was like "wasn't there a password? what happened to the password"
before bios was smart...
anyways... later!
have a good one!