Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release v2.3.0 #163

Merged
merged 23 commits into from Oct 24, 2018
Merged

Release v2.3.0 #163

merged 23 commits into from Oct 24, 2018

Conversation

ikalchev
Copy link
Owner

Highlights:

  • Camera support
  • New HAP categories
  • Much less traffic on set_characteristic

ikalchev and others added 23 commits May 29, 2018 22:41
Reverse merge for v2.2.2 from master to dev
* NeoPixelsLightStrip

Added ability to interface with NeoPixels RGB LEDs. This will allow changing of Color, Brightness and State(On/Off) of the NeoPixels attached to the RPi.
This accessory uses all available HomeKit Lightbulb API services (Hue, Saturation, Brightness).
This commit requires the installation of rpi_ws281x library. The procedure is outlined in # https://learn.adafruit.com/neopixels-on-raspberry-pi/software.

* Added check for RGB Tuple length to prevent crash from accessing outside bounds.
The accessory should respond either with 204 (NO_CONTENT) or
with 207 and json with a specific status code. This change
returns 204 for all characteristics. Also, adding more debug logging.
We need to call end_headers to flush the headers to the stream and this is done as
part of end_response.
Look at camera_main.py for a quick start.

* First steps in supporting a camera accessory.

* Documentation; value serialization/deserialization

* Commit progress

* Various changes - iOS can negotiate sessions

Running python3 cam.py and adding the camera in the Home app - iOS
can negotiate stream config with HAP python, which then starts
ffmpeg.

Remaining issue is that the Home app gets stuck at "Loading..."

* Code structure and documentation improvements.

* Unit tests, ability to insert custom start stream command

* Address flake8 warnings, disable some

* Fix a bug in stop_stream, coding style

* flake8 is now green

* Polish camera_main.py, add test_camera.py

* Add more camera tests

* Fix lints
This change adds three methods that users can implement to
plug custom logic for starting a stream, i.e. if only
changing the start_stream_cmd does not fit.

Added more tests.
* Spelling fix - executor

* Updated changelog
Working camera #53 

Probably missing edge cases, but can start/stop stream multiple times.
* Char - ignore duplicate values (client_update_value)

* Added testcase

* Updated logbook

* Fix method name
The default Camera.start method now starts a process and
redirects stdout to subprocess.DEVNULL and stderr to a
subprocess.PIP. Also, on Camera.stop, the process is
terminated (was killed) with a timeout of 2 seconds. If
this expires, the process is killed. The stderr of the
process is logged before the terminate.

This change also documents how a camera accessory can be set up
in the README.
@codecov-io
Copy link

Codecov Report

Merging #163 into master will increase coverage by 6.05%.
The diff coverage is 74.39%.

@@            Coverage Diff             @@
##           master     #163      +/-   ##
==========================================
+ Coverage   52.08%   58.14%   +6.05%     
==========================================
  Files          15       16       +1     
  Lines        1342     1639     +297     
  Branches      138      165      +27     
==========================================
+ Hits          699      953     +254     
- Misses        628      652      +24     
- Partials       15       34      +19
Impacted Files Coverage Δ
pyhap/accessory.py 52.41% <0%> (+2.06%) ⬆️
pyhap/__init__.py 83.33% <100%> (ø) ⬆️
pyhap/util.py 76.47% <100%> (+3.74%) ⬆️
pyhap/characteristic.py 98.23% <100%> (+0.04%) ⬆️
pyhap/const.py 100% <100%> (ø) ⬆️
pyhap/accessory_driver.py 57.81% <42.85%> (+0.44%) ⬆️
pyhap/tlv.py 70.58% <77.77%> (+60.24%) ⬆️
pyhap/camera.py 79.23% <79.23%> (ø)
pyhap/hap_server.py 25.73% <9.09%> (-0.35%) ⬇️
... and 3 more

@ikalchev ikalchev merged commit 3227bde into master Oct 24, 2018
@cdce8p
Copy link
Contributor

cdce8p commented Oct 25, 2018

Something might have gone wrong with this merge, maybe squash merge instead of a normal one?
Github still shows that the master branch is 24 commits behind dev, although all files (and the release) are correct.
I believe in order to fix that, you need to merge dev into master and then master into dev again. However a new release isn't necessary since all files are correct.

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

Successfully merging this pull request may close these issues.

None yet

6 participants