Closed maxileith closed 11 months ago
I assume that's the same issue as reported in https://github.com/sebbo2002/pyatv-mqtt-bridge/issues/285. I assume the output you posted above is complete? I would like to solve this as in https://github.com/sebbo2002/pyatv-mqtt-bridge/issues/285#issuecomment-1797978006 and not based on the current state. This should prevent broken states from being created. Thanks for posting such an event, I wasn't able to reproduce this, please give me some days to fix this.
Hi @sebbo2002,
thanks for the fast reply. The output that I have posted above is a complete JSON response from atvscript
. Looking forward to your solution to that problem :)
No problem. Another question: Is the volume
field included in atvscript playing
? Or does it only appear when changing the volume?
volume
does not appear in atvscript playing
. It does only appear when changing the volume.
Though, I cannot speak for HDMI CEC because my HiFi setup is a bit oldschool. For testing, I selected a HomePod Mini as the default speaker. But I suppose reporting the volume will be the same for HDMI CEC devices.
Yes, I would just assume that too. Thank you, I'll let you know when I have something.
:tada: This issue has been resolved in version 7.2.1-develop.1 :tada:
The release is available on:
v7.2.1-develop.1
Your semantic-release bot :package::rocket:
@maxileith Hey, can you check if 7.2.1-develop.1
works for you? Thank you.
It works. Thanks for the fast fix!
:tada: This issue has been resolved in version 7.2.1 :tada:
The release is available on:
Your semantic-release bot :package::rocket:
Hi,
I think I found a major bug in this otherwise awesome library.
The current state of a device was not taken into consideration when generating the updated state after receiving an update from
atvscript
. This way, attributes that are not reported in that specific result ofatvscript
, default tonull
, which is unwanted since in reality they are still unchanged and notnull
.E.g. when changing the volume, all attributes beside the volume are set to
null
, since the volume attribute is the only one reported by atvscript when changing the volume:All attributes beside
volume
will default tonull
resulting in a wrong state and unnecessary event listener triggers:https://github.com/sebbo2002/node-pyatv/blob/65cbc62b8e65e85c6f82a0474d4dfb91c6663eeb/src/lib/tools.ts#L239C4-L239C4
About this Pull Request
Pull Request Checklist
npm run lint
to double checknpm run test
to run the unit tests andnpm run coverage
to generate a coverage report