1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-24 21:06:19 +00:00
Files
core/tests/components
Paulus Schoutsen db0efc647d New component: Python Script (#7950)
* Add initial version

* Fix requirements

* Prefer logging over printing

* Set executor thread name on >Py36 only

* Add tests

* Lint

* Add restrictedpython to test dependencies

* Create python_script.py

From doc:
```
However, an empty dict ({}) is treated as is. If you want to specify a list that can contain anything, specify it as dict:
>>> schema = Schema({}, extra=ALLOW_EXTRA)  # don't do this
>>> try:
...   schema({'extra': 1})
...   raise AssertionError('MultipleInvalid not raised')
... except MultipleInvalid as e:
...   exc = e
>>> str(exc) == "not a valid value"
True
>>> schema({})
{}
>>> schema = Schema(dict)  # do this instead
>>> schema({})
{}
>>> schema({'extra': 1})
{'extra': 1}

```
2017-06-09 12:38:40 +02:00
..
2017-06-03 18:51:29 -07:00
2017-06-04 22:55:06 -07:00
2017-05-19 07:37:39 -07:00
2017-05-13 21:25:54 -07:00
2016-03-09 10:25:50 +01:00
2017-05-11 09:04:17 -07:00
2017-05-19 07:37:39 -07:00
2017-05-12 20:14:17 -07:00
2017-05-19 07:37:39 -07:00
2017-03-04 15:10:36 -08:00
2017-04-11 09:23:41 -07:00
2017-03-30 00:50:53 -07:00
2017-04-29 22:04:49 -07:00