Skip to content

Conversation

lobeck
Copy link

@lobeck lobeck commented Jul 27, 2018

This is a basic accessory discovering lightbulbs connected to a Hue Bridge and exposes them to HomeKit.

@codecov-io
Copy link

codecov-io commented Jul 27, 2018

Codecov Report

Merging #142 into dev will not change coverage.
The diff coverage is n/a.

@@ Coverage Diff @@ ## dev #142 +/- ## ======================================= Coverage 52.08% 52.08% ======================================= Files 15 15 Lines 1342 1342 Branches 138 138 ======================================= Hits 699 699 Misses 628 628 Partials 15 15
Copy link
Owner

@ikalchev ikalchev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi and thanks for the contrib. Also sorry for the delay! Can you leave just the accessory in this file so that users can just use the main.py and import this module?

from pyhap.accessory_driver import AccessoryDriver
from pyhap.const import CATEGORY_LIGHTBULB

logging.basicConfig(level=logging.INFO)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe leave this to the module that starts HAP, e.g. the main.py

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you decide to remove it, can you use logger = logging.getLogger(__name__)


self.id = id

def __setstate__(self, state):
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This method is not needed now (if you don't plan to pickle the accessory)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants