Commit graph

246 commits

Author SHA1 Message Date
Robbie Trencheny
a5f144cb7c HTML5 notify actions (#2855)
* Add action and callback support to html5 (#2855).

Remove registrations from the callback view since we always get the latest anyway.

We dont put an audience in the claims so we will never hit this error.

Bring tests back up to where they were before callbacks.

Only import jwt where necessary

Fix bracket spacing errors

Fix JWT decode check for loop

Remove stale comment.

Add tests for the callback system.

Shorten line

Disable pylint broad-except and change e to jwt_decode_error.

Verify expiration

Remove duplicate jwt.exceptions.DecodeError

Catch no keys matched and return False

* Switch to using registrations for callbackview instead of json_path

* Only check for URL and such if the data object actually exists

* raise instead of return

* cleanup decode_jwt

* Clean up JWT errors

* Correctly set status_code to 401

* Improve JWT by adding target to claims and attempting to check the given target for a decode match first, as well as pass the target through in the event payload.

* Add tag support and fix formatting issues

* Pass through any keys that dont apply to the payload into the notification.data dictionary

* Remove stale print

* Pass back the data dictionary if it exists

* Actually put the default url even if a notify payload dictionary doesnt exist

* pylint, flake8

* Add subscription validation

* Add validation for the callback event payload and use constants where possible

* Use HTTP_UNAUTHORIZED instead of 401

* Change callback dictionary to dict instead of cv.match_all

* Fix up tests and make subscription required

* Whoops, that test was supposed to fail

* Use the result of CALLBACK_EVENT_PAYLOAD_SCHEMA as event_payload

* Add a test for html5 callback decode_jwt where the device has been renamed since notification has been sent.

* Remove the loop through logic, assume that target is always in JWT

* Always return something instead of possibly None.

* Update frontend
2016-08-17 22:34:12 -07:00
Paulus Schoutsen
dc68f61261 Html5 push notifications notify platform (#2807)
* Initial work to add Chrome Push Notification support

* Remove push.js from home-assistant since it is now in Polymer

* Chrome->HTML5, general cleanup/fixes

* Make html5 generic, move manifest.json into frontend so that we can dynamically add the gcm_sender_id

* Pylint, flake8, pydocstyle frontend init

* HTML5 push fixes

* Update polymer

* Remove crypto req

* Add notify default platform.

* Fix HTML5 push

* Registration fixes

* Linting fix

* pep257 fix

* Add tests

* pep257 fix

* Update frontend
2016-08-14 01:10:07 -07:00
Paulus Schoutsen
f845893f8f Update frontend 2016-08-13 10:21:54 -07:00
Paulus Schoutsen
0b404cc0be Update frontend 2016-08-13 09:41:23 -07:00
Paulus Schoutsen
492ade7b1a Update frontend 2016-08-09 20:12:20 -07:00
Paulus Schoutsen
dd0b9f2f36 Update frontend 2016-08-08 00:41:32 -07:00
Paulus Schoutsen
b9b1d95514 Tweak panel parameters (#2746) 2016-08-07 21:56:17 -07:00
Paulus Schoutsen
792154a6a7 Update frontend 2016-08-03 08:22:47 -07:00
Paulus Schoutsen
1856e0110b Update frontend 2016-07-31 19:07:06 -07:00
Paulus Schoutsen
c39c10a088 update frontend 2016-07-31 16:39:07 -07:00
Paulus Schoutsen
f4d6ce08e4 Update frontend 2016-07-31 14:47:01 -07:00
Paulus Schoutsen
89ec39f629 Update frontend 2016-07-31 00:43:28 -07:00
Paulus Schoutsen
55624bcff9 Add custom panel example using React (#2651) 2016-07-29 00:49:58 -07:00
Paulus Schoutsen
ec8802ec44 Update frontend 2016-07-28 09:22:15 -07:00
Paulus Schoutsen
1620680127 Use local timezone for log and history dates (#2622)
* Use local timezone for log and history dates

* home-assistant-js fix

* Submodule updates not included so travis can build

* Separate Date and DateTime http validators

* Include submodule reference

* Update frontend
2016-07-27 20:43:46 -07:00
Paulus Schoutsen
487f3b2951 Update frontend 2016-07-23 10:19:26 -07:00
Paulus Schoutsen
a513e1cc35 Update frontend 2016-07-21 08:41:48 -07:00
Paulus Schoutsen
2ea2a62d45 Update service worker 2016-07-20 23:40:40 -07:00
Paulus Schoutsen
59029f2830 Update frontend 2016-07-19 23:36:52 -07:00
Paulus Schoutsen
7c431911d1 Update frontend 2016-07-19 02:37:22 -07:00
Paulus Schoutsen
5001c9729f Update frontend 2016-07-18 21:29:50 -07:00
Paulus Schoutsen
541fffc7fa Update frontend 2016-07-17 23:23:31 -07:00
Paulus Schoutsen
925a623445 Build frontend 2016-07-16 23:24:17 -07:00
Paulus Schoutsen
22b4aebeb3 Add support for dynamic frontend panels 2016-07-16 23:21:34 -07:00
Paulus Schoutsen
7cff107c17 Update frontend 2016-07-16 02:15:46 -07:00
Paulus Schoutsen
e38b7d97d2 Update frontend 2016-07-13 23:05:40 -07:00
Paulus Schoutsen
49b595e32e Update frontend 2016-07-13 19:05:25 -07:00
Paulus Schoutsen
af736a3e71 Update frontend (temp map solution) 2016-07-13 08:32:13 -07:00
Paulus Schoutsen
8fcfb9136c Update frontend 2016-07-12 09:16:21 -07:00
Paulus Schoutsen
6d60287455 Update frontend 2016-07-12 00:10:05 -07:00
Paulus Schoutsen
6cb91e66c8 Update frontend 2016-07-11 22:07:34 -07:00
Paulus Schoutsen
c5b2df01d9 Update frontend 2016-07-04 10:40:43 -07:00
Paulus Schoutsen
cbb897b2cf Update frontend 2016-06-24 22:34:55 -07:00
Paulus Schoutsen
2036c44364 Hotfix 21 2 (#2302)
* Update frontend

Conflicts:
	homeassistant/components/frontend/version.py
	homeassistant/components/frontend/www_static/core.js.gz
	homeassistant/components/frontend/www_static/frontend.html
	homeassistant/components/frontend/www_static/frontend.html.gz
	homeassistant/components/frontend/www_static/home-assistant-polymer
	homeassistant/components/frontend/www_static/service_worker.js
	homeassistant/components/frontend/www_static/service_worker.js.gz

* Add a default OPTIONS handler for wsgi (#2301)

When a browser makes a CORS request, it often makes a 'preflight'
options request in order to make sure the resource is valid, and that
it has the right CORS access. This adds a default OPTIONS handler for
all views. If a view needs to customize the OPTIONS handler for some
reason, it's free to, but this way CORS will work.

* Version bump to 0.21.2
2016-06-14 19:54:09 -07:00
Paulus Schoutsen
5c87883c86 Update frontend 2016-06-12 00:04:37 -07:00
Paulus Schoutsen
81f8764bb8 Update frontend 2016-06-01 23:47:31 -07:00
Paulus Schoutsen
8494ac7cef Update frontend 2016-05-29 09:50:30 -07:00
Paulus Schoutsen
05b2559df8 Update frontend 2016-05-28 23:28:57 -07:00
Paulus Schoutsen
70b74da3eb Update frontend 2016-05-28 18:38:46 -07:00
Paulus Schoutsen
9e0b107991 Update frontend 2016-05-28 11:32:35 -07:00
Paulus Schoutsen
e10b00f341 Update frontend 2016-05-27 21:45:38 -07:00
Paulus Schoutsen
cd87c40bbf Update frontend 2016-05-27 01:29:48 -07:00
Paulus Schoutsen
ab60b32326 Update frontend 2016-05-21 14:06:07 -07:00
Paulus Schoutsen
8a16a7d943 Update frontend 2016-05-07 10:10:09 -07:00
Paulus Schoutsen
67f3fcc5cf Update frontend 2016-05-06 23:35:15 -07:00
Paulus Schoutsen
588a0cc947 Update frontend 2016-04-28 16:32:25 +02:00
Paulus Schoutsen
3e0f64e4f6 Update frontend 2016-04-20 18:13:25 -07:00
Paulus Schoutsen
4abbbf0f50 Merge remote-tracking branch 'origin/master' into dev
Conflicts:
	homeassistant/bootstrap.py
	homeassistant/components/frontend/version.py
	homeassistant/const.py
2016-04-19 22:53:26 -07:00
Paulus Schoutsen
bdc39ff905 Update frontend 2016-04-19 21:39:44 -07:00
Paulus Schoutsen
1cfbeabaec Update frontend 2016-04-16 10:05:29 -07:00