delfick / photons

Python3.6+ asyncio framework for interacting with LIFX devices
https://photons.delfick.com
MIT License
73 stars 6 forks source link

Add new products to registry #128

Closed Djelibeybi closed 4 months ago

Djelibeybi commented 5 months ago

The upstream product registry just got updated with the latest outdoor and other devices so it would be super peachy keen if Photons' registry were updated accordingly.

I'd do it myself but I'm not entirely sure what LCM generation some/all of these devices are, which makes adding them somewhat problematic.

Also, there is an error with two of the product definitions for which I've opened an upstreanm issue: https://github.com/LIFX/products/issues/30 -- I have manually updated my equivalent PR for aiolifx accordingly but I can understand waiting until upstream fix the issue before merging the change.

delfick commented 5 months ago

I feel that making public photons have the lcm info despite it not actually being public info was probably not what I should have done. Lets make an LCMX and put future products under that rather than trying to make public photons actually want/need to know that level of detail.

On Thu, 4 Apr 2024, 01:43 Avi Miller, @.***> wrote:

The upstream product registry just got updated with the latest outdoor and other devices so it would be super peachy keen if Photons' registry were updated accordingly.

I'd do it myself but I'm not entirely sure what LCM generation some/all of these devices are, which makes adding them somewhat problematic.

Also, there is an error with two of the product definitions for which I've opened an upstreanm issue: LIFX/products#30 https://github.com/LIFX/products/issues/30 -- I have manually updated my equivalent PR for aiolifx accordingly but I can understand waiting until upstream fix the issue before merging the change.

— Reply to this email directly, view it on GitHub https://github.com/delfick/photons/issues/128, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAA2V5IDP5LTFL6YTSO7NULY3QPSTAVCNFSM6AAAAABFVO5OCGVHI2DSMVQWIX3LMV43ASLTON2WKOZSGIZDGMJTGM2TOMA . You are receiving this because you are subscribed to this thread.Message ID: @.***>

Djelibeybi commented 5 months ago

Sounds like a reasonable plan. Do you want to do that or should I?

Aside: is/was there a way to generate the registry automatically/programatically from the products.json file? There is for aiolifx and I could've sworn there was for Photons too, but now I can't find it, so 🤷🏻‍♂️

delfick commented 5 months ago

I'll let you create the PR :)

If I remember correctly, the way I used to generate Photons product registry required the internal project that had all the information, so public photons registry is now a manual thing

I never got around to making a products version of how public photons generates the messages.

On Thu, 4 Apr 2024, 07:21 Avi Miller, @.***> wrote:

Sounds like a reasonable plan. Do you want to do that or should I?

Aside: is/was there a way to generate the registry automatically/programatically from the products.json file? There is for aiolifx and I could've sworn there was for Photons too, but now I can't find it, so 🤷🏻‍♂️

— Reply to this email directly, view it on GitHub https://github.com/delfick/photons/issues/128#issuecomment-2035508946, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAA2V5OSLL7UVTBYMSDIT4DY3RXD5AVCNFSM6AAAAABFVO5OCGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAMZVGUYDQOJUGY . You are receiving this because you commented.Message ID: @.***>

Djelibeybi commented 5 months ago

Creating it automatically would be a lot simpler if we replaced the array key with something like the pid instead of the LCM string, but I'm unsure if that would break anything significantly.

Given the fact that new LIFX devices are coming out in a steady stream now, it makes more sense to me to spend a bit of time creating an generator script instead of manually adding the new products.

I'm happy to take a stab at that, but I already know you'll do it quicker, more elegantly and with way more Pythonic code. 😉

delfick commented 5 months ago

I reckon it'd only be quicker if I had time to make such a thing. Given I don't, I imagine your efforts would be quicker in overall terms!

On Thu, 4 Apr 2024, 07:55 Avi Miller, @.***> wrote:

Creating it automatically would be a lot simpler if we replaced the array key with something like the pid instead of the LCM string, but I'm unsure if that would break anything significantly.

Given the fact that new LIFX devices are coming out in a steady stream now, it makes more sense to me to spend a bit of time creating an generator script instead of manually adding the new products.

I'm happy to take a stab at that, but I already know you'll do it quicker, more elegantly and with way more Pythonic code. 😉

— Reply to this email directly, view it on GitHub https://github.com/delfick/photons/issues/128#issuecomment-2035574144, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAA2V5PQGRR3GJAWY6QTQ33Y3R3E3AVCNFSM6AAAAABFVO5OCGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAMZVGU3TIMJUGQ . You are receiving this because you commented.Message ID: @.***>

Djelibeybi commented 5 months ago

Fair enough. I'll give it a whirl over the next couple of days as time permits.

Djelibeybi commented 4 months ago

~Fair enough. I'll give it a whirl over the next couple of days as time permits.~

This week was and next week will be a write-off because of various physical health issues and such, so I'm not going to get to this for a few weeks at least.

delfick commented 4 months ago

all good, this project lives in a state of negative time pressure

On Wed, 10 Apr 2024, 22:11 Avi Miller, @.***> wrote:

Fair enough. I'll give it a whirl over the next couple of days as time permits.

This week was and next week will be a write-off because of various physical health issues and such, so I'm not going to get to this for a few weeks at least.

— Reply to this email directly, view it on GitHub https://github.com/delfick/photons/issues/128#issuecomment-2047381784, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAA2V5LHZB7LXW4TZHBJW5TY4UUAHAVCNFSM6AAAAABFVO5OCGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANBXGM4DCNZYGQ . You are receiving this because you commented.Message ID: @.***>

Djelibeybi commented 4 months ago

all good, this project lives in a state of negative time pressure

If it weren't for last minute panic, I'd never get anything done.