mirror of
https://github.com/PiBrewing/craftbeerpi4.git
synced 2024-11-21 22:48:16 +01:00
config added
This commit is contained in:
parent
05e9000c43
commit
83696fb556
59 changed files with 1592 additions and 331 deletions
12
.idea/dataSources.local.xml
Normal file
12
.idea/dataSources.local.xml
Normal file
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="dataSourceStorageLocal">
|
||||
<data-source name="craftbeerpi.db" uuid="5067e7fe-480d-4433-bc40-f2d1c38362a2">
|
||||
<database-info product="SQLite" version="3.16.1" jdbc-version="2.1" driver-name="SQLiteJDBC" driver-version="native" />
|
||||
<case-sensitivity plain-identifiers="mixed" quoted-identifiers="mixed" />
|
||||
<secret-storage>master_key</secret-storage>
|
||||
<auth-required>false</auth-required>
|
||||
<introspection-schemas>*:main</introspection-schemas>
|
||||
</data-source>
|
||||
</component>
|
||||
</project>
|
14
.idea/dataSources.xml
Normal file
14
.idea/dataSources.xml
Normal file
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="DataSourceManagerImpl" format="xml" multifile-model="true">
|
||||
<data-source source="LOCAL" name="craftbeerpi.db" uuid="5067e7fe-480d-4433-bc40-f2d1c38362a2">
|
||||
<driver-ref>sqlite.xerial</driver-ref>
|
||||
<synchronize>true</synchronize>
|
||||
<jdbc-driver>org.sqlite.JDBC</jdbc-driver>
|
||||
<jdbc-url>jdbc:sqlite:$PROJECT_DIR$/craftbeerpi.db</jdbc-url>
|
||||
<driver-properties>
|
||||
<property name="enable_load_extension" value="true" />
|
||||
</driver-properties>
|
||||
</data-source>
|
||||
</component>
|
||||
</project>
|
317
.idea/dataSources/5067e7fe-480d-4433-bc40-f2d1c38362a2.xml
Normal file
317
.idea/dataSources/5067e7fe-480d-4433-bc40-f2d1c38362a2.xml
Normal file
|
@ -0,0 +1,317 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<dataSource name="craftbeerpi.db">
|
||||
<database-model serializer="dbm" rdbms="SQLITE" format-version="4.1">
|
||||
<root id="1"/>
|
||||
<schema id="2" parent="1" name="main">
|
||||
<Current>1</Current>
|
||||
<Visible>1</Visible>
|
||||
</schema>
|
||||
<table id="3" parent="2" name="actor"/>
|
||||
<table id="4" parent="2" name="config"/>
|
||||
<table id="5" parent="2" name="dashboard"/>
|
||||
<table id="6" parent="2" name="dashboard_content"/>
|
||||
<table id="7" parent="2" name="kettle"/>
|
||||
<table id="8" parent="2" name="sensor"/>
|
||||
<table id="9" parent="2" name="sqlite_master"/>
|
||||
<table id="10" parent="2" name="step"/>
|
||||
<table id="11" parent="2" name="tank"/>
|
||||
<table id="12" parent="2" name="translation"/>
|
||||
<column id="13" parent="3" name="id">
|
||||
<DataType>INTEGER|0</DataType>
|
||||
<NotNull>1</NotNull>
|
||||
</column>
|
||||
<column id="14" parent="3" name="name">
|
||||
<Position>1</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<column id="15" parent="3" name="type">
|
||||
<Position>2</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<column id="16" parent="3" name="config">
|
||||
<Position>3</Position>
|
||||
<DataType>VARCHAR(3000)|0</DataType>
|
||||
</column>
|
||||
<key id="17" parent="3">
|
||||
<ColNames>id</ColNames>
|
||||
<Primary>1</Primary>
|
||||
</key>
|
||||
<column id="18" parent="4" name="name">
|
||||
<DataType>VARCHAR(50)|0</DataType>
|
||||
<NotNull>1</NotNull>
|
||||
</column>
|
||||
<column id="19" parent="4" name="value">
|
||||
<Position>1</Position>
|
||||
<DataType>VARCHAR(255)|0</DataType>
|
||||
</column>
|
||||
<column id="20" parent="4" name="type">
|
||||
<Position>2</Position>
|
||||
<DataType>VARCHAR(50)|0</DataType>
|
||||
</column>
|
||||
<column id="21" parent="4" name="description">
|
||||
<Position>3</Position>
|
||||
<DataType>VARCHAR(255)|0</DataType>
|
||||
</column>
|
||||
<column id="22" parent="4" name="options">
|
||||
<Position>4</Position>
|
||||
<DataType>VARCHAR(255)|0</DataType>
|
||||
</column>
|
||||
<index id="23" parent="4" name="sqlite_autoindex_config_1">
|
||||
<ColNames>name</ColNames>
|
||||
<Unique>1</Unique>
|
||||
</index>
|
||||
<key id="24" parent="4">
|
||||
<ColNames>name</ColNames>
|
||||
<Primary>1</Primary>
|
||||
<UnderlyingIndexName>sqlite_autoindex_config_1</UnderlyingIndexName>
|
||||
</key>
|
||||
<column id="25" parent="5" name="id">
|
||||
<DataType>INTEGER|0</DataType>
|
||||
<NotNull>1</NotNull>
|
||||
</column>
|
||||
<column id="26" parent="5" name="name">
|
||||
<Position>1</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<key id="27" parent="5">
|
||||
<ColNames>id</ColNames>
|
||||
<Primary>1</Primary>
|
||||
</key>
|
||||
<column id="28" parent="6" name="id">
|
||||
<DataType>INTEGER|0</DataType>
|
||||
<NotNull>1</NotNull>
|
||||
</column>
|
||||
<column id="29" parent="6" name="dbid">
|
||||
<Position>1</Position>
|
||||
<DataType>INTEGER(80)|0</DataType>
|
||||
</column>
|
||||
<column id="30" parent="6" name="element_id">
|
||||
<Position>2</Position>
|
||||
<DataType>INTEGER|0</DataType>
|
||||
</column>
|
||||
<column id="31" parent="6" name="type">
|
||||
<Position>3</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<column id="32" parent="6" name="x">
|
||||
<Position>4</Position>
|
||||
<DataType>INTEGER(5)|0</DataType>
|
||||
</column>
|
||||
<column id="33" parent="6" name="y">
|
||||
<Position>5</Position>
|
||||
<DataType>INTEGER(5)|0</DataType>
|
||||
</column>
|
||||
<column id="34" parent="6" name="config">
|
||||
<Position>6</Position>
|
||||
<DataType>VARCHAR(3000)|0</DataType>
|
||||
</column>
|
||||
<key id="35" parent="6">
|
||||
<ColNames>id</ColNames>
|
||||
<Primary>1</Primary>
|
||||
</key>
|
||||
<column id="36" parent="7" name="id">
|
||||
<DataType>INTEGER|0</DataType>
|
||||
<NotNull>1</NotNull>
|
||||
</column>
|
||||
<column id="37" parent="7" name="name">
|
||||
<Position>1</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<column id="38" parent="7" name="sensor">
|
||||
<Position>2</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<column id="39" parent="7" name="heater">
|
||||
<Position>3</Position>
|
||||
<DataType>VARCHAR(10)|0</DataType>
|
||||
</column>
|
||||
<column id="40" parent="7" name="automatic">
|
||||
<Position>4</Position>
|
||||
<DataType>VARCHAR(255)|0</DataType>
|
||||
</column>
|
||||
<column id="41" parent="7" name="logic">
|
||||
<Position>5</Position>
|
||||
<DataType>VARCHAR(50)|0</DataType>
|
||||
</column>
|
||||
<column id="42" parent="7" name="config">
|
||||
<Position>6</Position>
|
||||
<DataType>VARCHAR(1000)|0</DataType>
|
||||
</column>
|
||||
<column id="43" parent="7" name="agitator">
|
||||
<Position>7</Position>
|
||||
<DataType>VARCHAR(10)|0</DataType>
|
||||
</column>
|
||||
<column id="44" parent="7" name="target_temp">
|
||||
<Position>8</Position>
|
||||
<DataType>INTEGER|0</DataType>
|
||||
</column>
|
||||
<column id="45" parent="7" name="height">
|
||||
<Position>9</Position>
|
||||
<DataType>INTEGER|0</DataType>
|
||||
</column>
|
||||
<column id="46" parent="7" name="diameter">
|
||||
<Position>10</Position>
|
||||
<DataType>INTEGER|0</DataType>
|
||||
</column>
|
||||
<key id="47" parent="7">
|
||||
<ColNames>id</ColNames>
|
||||
<Primary>1</Primary>
|
||||
</key>
|
||||
<column id="48" parent="8" name="id">
|
||||
<DataType>INTEGER|0</DataType>
|
||||
<NotNull>1</NotNull>
|
||||
</column>
|
||||
<column id="49" parent="8" name="name">
|
||||
<Position>1</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<column id="50" parent="8" name="type">
|
||||
<Position>2</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<column id="51" parent="8" name="config">
|
||||
<Position>3</Position>
|
||||
<DataType>VARCHAR(3000)|0</DataType>
|
||||
</column>
|
||||
<key id="52" parent="8">
|
||||
<ColNames>id</ColNames>
|
||||
<Primary>1</Primary>
|
||||
</key>
|
||||
<column id="53" parent="9" name="type">
|
||||
<DataType>text|0</DataType>
|
||||
</column>
|
||||
<column id="54" parent="9" name="name">
|
||||
<Position>1</Position>
|
||||
<DataType>text|0</DataType>
|
||||
</column>
|
||||
<column id="55" parent="9" name="tbl_name">
|
||||
<Position>2</Position>
|
||||
<DataType>text|0</DataType>
|
||||
</column>
|
||||
<column id="56" parent="9" name="rootpage">
|
||||
<Position>3</Position>
|
||||
<DataType>integer|0</DataType>
|
||||
</column>
|
||||
<column id="57" parent="9" name="sql">
|
||||
<Position>4</Position>
|
||||
<DataType>text|0</DataType>
|
||||
</column>
|
||||
<column id="58" parent="10" name="id">
|
||||
<DataType>INTEGER|0</DataType>
|
||||
<NotNull>1</NotNull>
|
||||
</column>
|
||||
<column id="59" parent="10" name="order">
|
||||
<Position>1</Position>
|
||||
<DataType>INTEGER|0</DataType>
|
||||
</column>
|
||||
<column id="60" parent="10" name="name">
|
||||
<Position>2</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<column id="61" parent="10" name="type">
|
||||
<Position>3</Position>
|
||||
<DataType>VARCHAR(100)|0</DataType>
|
||||
</column>
|
||||
<column id="62" parent="10" name="stepstate">
|
||||
<Position>4</Position>
|
||||
<DataType>VARCHAR(255)|0</DataType>
|
||||
</column>
|
||||
<column id="63" parent="10" name="state">
|
||||
<Position>5</Position>
|
||||
<DataType>VARCHAR(1)|0</DataType>
|
||||
</column>
|
||||
<column id="64" parent="10" name="start">
|
||||
<Position>6</Position>
|
||||
<DataType>INTEGER|0</DataType>
|
||||
</column>
|
||||
<column id="65" parent="10" name="end">
|
||||
<Position>7</Position>
|
||||
<DataType>INTEGER|0</DataType>
|
||||
</column>
|
||||
<column id="66" parent="10" name="config">
|
||||
<Position>8</Position>
|
||||
<DataType>VARCHAR(255)|0</DataType>
|
||||
</column>
|
||||
<column id="67" parent="10" name="kettleid">
|
||||
<Position>9</Position>
|
||||
<DataType>INTEGER|0</DataType>
|
||||
</column>
|
||||
<key id="68" parent="10">
|
||||
<ColNames>id</ColNames>
|
||||
<Primary>1</Primary>
|
||||
</key>
|
||||
<column id="69" parent="11" name="id">
|
||||
<DataType>INTEGER|0</DataType>
|
||||
<NotNull>1</NotNull>
|
||||
</column>
|
||||
<column id="70" parent="11" name="name">
|
||||
<Position>1</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<column id="71" parent="11" name="brewname">
|
||||
<Position>2</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<column id="72" parent="11" name="sensor">
|
||||
<Position>3</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<column id="73" parent="11" name="sensor2">
|
||||
<Position>4</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<column id="74" parent="11" name="sensor3">
|
||||
<Position>5</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
</column>
|
||||
<column id="75" parent="11" name="heater">
|
||||
<Position>6</Position>
|
||||
<DataType>VARCHAR(10)|0</DataType>
|
||||
</column>
|
||||
<column id="76" parent="11" name="logic">
|
||||
<Position>7</Position>
|
||||
<DataType>VARCHAR(50)|0</DataType>
|
||||
</column>
|
||||
<column id="77" parent="11" name="config">
|
||||
<Position>8</Position>
|
||||
<DataType>VARCHAR(1000)|0</DataType>
|
||||
</column>
|
||||
<column id="78" parent="11" name="cooler">
|
||||
<Position>9</Position>
|
||||
<DataType>VARCHAR(10)|0</DataType>
|
||||
</column>
|
||||
<column id="79" parent="11" name="target_temp">
|
||||
<Position>10</Position>
|
||||
<DataType>INTEGER|0</DataType>
|
||||
</column>
|
||||
<key id="80" parent="11">
|
||||
<ColNames>id</ColNames>
|
||||
<Primary>1</Primary>
|
||||
</key>
|
||||
<column id="81" parent="12" name="language_code">
|
||||
<DataType>VARCHAR(3)|0</DataType>
|
||||
<NotNull>1</NotNull>
|
||||
</column>
|
||||
<column id="82" parent="12" name="key">
|
||||
<Position>1</Position>
|
||||
<DataType>VARCHAR(80)|0</DataType>
|
||||
<NotNull>1</NotNull>
|
||||
</column>
|
||||
<column id="83" parent="12" name="text">
|
||||
<Position>2</Position>
|
||||
<DataType>VARCHAR(100)|0</DataType>
|
||||
<NotNull>1</NotNull>
|
||||
</column>
|
||||
<index id="84" parent="12" name="sqlite_autoindex_translation_1">
|
||||
<ColNames>language_code
|
||||
key</ColNames>
|
||||
<Unique>1</Unique>
|
||||
</index>
|
||||
<key id="85" parent="12">
|
||||
<ColNames>language_code
|
||||
key</ColNames>
|
||||
<Primary>1</Primary>
|
||||
<UnderlyingIndexName>sqlite_autoindex_translation_1</UnderlyingIndexName>
|
||||
</key>
|
||||
</database-model>
|
||||
</dataSource>
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -1,7 +1,37 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="1a245e6a-2e43-4348-8759-dc1b63a4c9c8" name="Default" comment="" />
|
||||
<list default="true" id="1a245e6a-2e43-4348-8759-dc1b63a4c9c8" name="Default" comment="">
|
||||
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/config/config.yaml" />
|
||||
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/core/api/extension.py" />
|
||||
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/core/extension/dummy/config.yaml" />
|
||||
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/core/helper/utils.py" />
|
||||
<change type="DELETED" beforePath="$PROJECT_DIR$/logs/first_logfile2.log.2018-11-01_17-21" afterPath="" />
|
||||
<change type="DELETED" beforePath="$PROJECT_DIR$/logs/first_logfile2.log.2018-11-01_17-23" afterPath="" />
|
||||
<change type="DELETED" beforePath="$PROJECT_DIR$/logs/first_logfile2.log.2018-11-01_17-24" afterPath="" />
|
||||
<change type="DELETED" beforePath="$PROJECT_DIR$/logs/first_logfile2.log.2018-11-01_17-27" afterPath="" />
|
||||
<change type="DELETED" beforePath="$PROJECT_DIR$/logs/first_logfile2.log.2018-11-01_17-32" afterPath="" />
|
||||
<change type="MOVED" beforePath="$PROJECT_DIR$/core/cbpi.py" afterPath="$PROJECT_DIR$/core/craftbeerpi.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/craftbeerpi.db" afterPath="$PROJECT_DIR$/craftbeerpi.db" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/api/actor.py" afterPath="$PROJECT_DIR$/core/api/actor.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/api/sensor.py" afterPath="$PROJECT_DIR$/core/api/sensor.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/controller/actor_controller.py" afterPath="$PROJECT_DIR$/core/controller/actor_controller.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/controller/crud_controller.py" afterPath="$PROJECT_DIR$/core/controller/crud_controller.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/controller/sensor_controller.py" afterPath="$PROJECT_DIR$/core/controller/sensor_controller.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/controller/system_controller.py" afterPath="$PROJECT_DIR$/core/controller/system_controller.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/database/model.py" afterPath="$PROJECT_DIR$/core/database/model.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/database/orm_framework.py" afterPath="$PROJECT_DIR$/core/database/orm_framework.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/extension/dummy/__init__.py" afterPath="$PROJECT_DIR$/core/extension/dummy/__init__.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/http_endpoints/http_api.py" afterPath="$PROJECT_DIR$/core/http_endpoints/http_api.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/http_endpoints/http_login.py" afterPath="$PROJECT_DIR$/core/http_endpoints/http_login.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/mqtt/mqtt.py" afterPath="$PROJECT_DIR$/core/mqtt/mqtt.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/plugin.py" afterPath="$PROJECT_DIR$/core/plugin.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/core/websocket.py" afterPath="$PROJECT_DIR$/core/websocket.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/logs/first_logfile2.log" afterPath="$PROJECT_DIR$/logs/first_logfile2.log" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/run.py" afterPath="$PROJECT_DIR$/run.py" />
|
||||
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/tests/test_app.py" afterPath="$PROJECT_DIR$/tests/test_app.py" />
|
||||
</list>
|
||||
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
|
||||
<option name="TRACKING_ENABLED" value="true" />
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
|
@ -10,28 +40,151 @@
|
|||
<option name="LAST_RESOLUTION" value="IGNORE" />
|
||||
</component>
|
||||
<component name="CoverageDataManager">
|
||||
<SUITE FILE_PATH="coverage/craftbeerpi4$run.coverage" NAME="run Coverage Results" MODIFIED="1541098167062" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$" />
|
||||
<SUITE FILE_PATH="coverage/craftbeerpi4$run.coverage" NAME="run Coverage Results" MODIFIED="1541103448346" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="coverage.py" COVERAGE_BY_TEST_ENABLED="true" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$" />
|
||||
</component>
|
||||
<component name="DatabaseView">
|
||||
<option name="SHOW_INTERMEDIATE" value="true" />
|
||||
<option name="GROUP_SCHEMA" value="true" />
|
||||
<option name="GROUP_CONTENTS" value="false" />
|
||||
<option name="SORT_POSITIONED" value="false" />
|
||||
<option name="SHOW_TABLE_DETAILS" value="true" />
|
||||
<option name="SHOW_EMPTY_GROUPS" value="false" />
|
||||
<option name="AUTO_SCROLL_FROM_SOURCE" value="false" />
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" />
|
||||
<option name="myItemType" value="com.intellij.database.view.DatabaseStructure$Root" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi.db" />
|
||||
<option name="myItemType" value="com.intellij.database.view.DbNodeDescriptor" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" />
|
||||
<option name="myItemType" value="com.intellij.database.view.DatabaseStructure$Root" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi.db" />
|
||||
<option name="myItemType" value="com.intellij.database.view.DbNodeDescriptor" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="main" />
|
||||
<option name="myItemType" value="com.intellij.database.view.DbNodeDescriptor" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
</component>
|
||||
<component name="ExecutionTargetManager" SELECTED_TARGET="default_target" />
|
||||
<component name="FileEditorManager">
|
||||
<leaf>
|
||||
<file leaf-file-name="requirements.txt" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/requirements.txt">
|
||||
<file leaf-file-name="http_login.py" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/core/http_endpoints/http_login.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="375">
|
||||
<caret line="25" column="14" lean-forward="false" selection-start-line="25" selection-start-column="14" selection-end-line="25" selection-end-column="14" />
|
||||
<folding>
|
||||
<element signature="e#0#14#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="config.yaml" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/config/config.yaml">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<caret line="0" column="12" lean-forward="false" selection-start-line="0" selection-start-column="12" selection-end-line="0" selection-end-column="12" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="run.py" pinned="false" current-in-tab="true">
|
||||
<entry file="file://$PROJECT_DIR$/run.py">
|
||||
<file leaf-file-name="utils.py" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/core/helper/utils.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="105">
|
||||
<caret line="7" column="15" lean-forward="true" selection-start-line="7" selection-start-column="15" selection-end-line="7" selection-end-column="15" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="__init__.py" pinned="false" current-in-tab="true">
|
||||
<entry file="file://$PROJECT_DIR$/core/extension/dummy/__init__.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="135">
|
||||
<caret line="9" column="17" lean-forward="false" selection-start-line="9" selection-start-column="17" selection-end-line="9" selection-end-column="17" />
|
||||
<folding>
|
||||
<element signature="e#0#42#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="actor.py" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/core/api/actor.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="105">
|
||||
<caret line="7" column="12" lean-forward="false" selection-start-line="7" selection-start-column="12" selection-end-line="7" selection-end-column="12" />
|
||||
<folding>
|
||||
<element signature="e#1#15#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="extension.py" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/core/api/extension.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<folding>
|
||||
<element signature="e#0#16#0" expanded="true" />
|
||||
<element signature="e#0#14#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="sensor.py" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/core/api/sensor.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="195">
|
||||
<caret line="13" column="12" lean-forward="true" selection-start-line="13" selection-start-column="12" selection-end-line="13" selection-end-column="12" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="config.yaml" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/core/extension/dummy/config.yaml">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="12" lean-forward="false" selection-start-line="0" selection-start-column="12" selection-end-line="0" selection-end-column="12" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="actor_controller.py" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/core/controller/actor_controller.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="260">
|
||||
<caret line="33" column="27" lean-forward="false" selection-start-line="33" selection-start-column="27" selection-end-line="33" selection-end-column="27" />
|
||||
<folding>
|
||||
<element signature="e#0#23#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
</file>
|
||||
<file leaf-file-name="craftbeerpi.py" pinned="false" current-in-tab="false">
|
||||
<entry file="file://$PROJECT_DIR$/core/craftbeerpi.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="141">
|
||||
<caret line="21" column="0" lean-forward="false" selection-start-line="21" selection-start-column="0" selection-end-line="23" selection-end-column="0" />
|
||||
<folding>
|
||||
<element signature="e#0#14#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
|
@ -39,9 +192,87 @@
|
|||
</file>
|
||||
</leaf>
|
||||
</component>
|
||||
<component name="FileTemplateManagerImpl">
|
||||
<option name="RECENT_TEMPLATES">
|
||||
<list>
|
||||
<option value="Python Script" />
|
||||
</list>
|
||||
</option>
|
||||
</component>
|
||||
<component name="FindInProjectRecents">
|
||||
<findStrings>
|
||||
<find>7//</find>
|
||||
<find>7/</find>
|
||||
<find>7</find>
|
||||
<find>/</find>
|
||||
<find>///</find>
|
||||
<find>///7</find>
|
||||
<find>///77</find>
|
||||
<find>///777</find>
|
||||
<find>///7777</find>
|
||||
<find>///7777/</find>
|
||||
<find>///7777//</find>
|
||||
<find>///7777///</find>
|
||||
<find>///7777///7</find>
|
||||
<find>///7777///7|</find>
|
||||
<find>///7777///7||</find>
|
||||
<find>///7777///7|||</find>
|
||||
<find>///7777///7|||6</find>
|
||||
<find>\n\n</find>
|
||||
<find>\n\n</find>
|
||||
<find>cpre</find>
|
||||
<find>cpr</find>
|
||||
<find>cp</find>
|
||||
<find>c</find>
|
||||
<find>co</find>
|
||||
<find>core</find>
|
||||
<find>.core</find>
|
||||
<find>from.cbpi.</find>
|
||||
<find>pr</find>
|
||||
<find>p</find>
|
||||
<find>print</find>
|
||||
</findStrings>
|
||||
<replaceStrings>
|
||||
<replace />
|
||||
<replace>.cbpi</replace>
|
||||
<replace>from core.</replace>
|
||||
</replaceStrings>
|
||||
<dirStrings>
|
||||
<dir>$PROJECT_DIR$</dir>
|
||||
<dir>$PROJECT_DIR$/core</dir>
|
||||
</dirStrings>
|
||||
</component>
|
||||
<component name="Git.Settings">
|
||||
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
|
||||
</component>
|
||||
<component name="IdeDocumentHistory">
|
||||
<option name="CHANGED_PATHS">
|
||||
<list>
|
||||
<option value="$PROJECT_DIR$/run.py" />
|
||||
<option value="$PROJECT_DIR$/core/cbpi.py" />
|
||||
<option value="$PROJECT_DIR$/core/database/model.py" />
|
||||
<option value="$PROJECT_DIR$/core/craftbeerpi.py" />
|
||||
<option value="$PROJECT_DIR$/core/controller/sensor_controller.py" />
|
||||
<option value="$PROJECT_DIR$/core/controller/crud_controller.py" />
|
||||
<option value="$PROJECT_DIR$/core/controller/actor_controller.py" />
|
||||
<option value="$PROJECT_DIR$/core/controller/system_controller.py" />
|
||||
<option value="$PROJECT_DIR$/core/http_endpoints/http_api.py" />
|
||||
<option value="$PROJECT_DIR$/core/mqtt/mqtt.py" />
|
||||
<option value="$PROJECT_DIR$/core/plugin.py" />
|
||||
<option value="$PROJECT_DIR$/core/websocket.py" />
|
||||
<option value="$PROJECT_DIR$/core/database/orm_framework.py" />
|
||||
<option value="$PROJECT_DIR$/core/helper/utils.py" />
|
||||
<option value="$PROJECT_DIR$/core/http_endpoints/http_login.py" />
|
||||
<option value="$PROJECT_DIR$/config/config.yaml" />
|
||||
<option value="$PROJECT_DIR$/core/extension/dummy/config.yaml" />
|
||||
<option value="$PROJECT_DIR$/core/extension/dummy/__init__.py" />
|
||||
<option value="$PROJECT_DIR$/core/api/extension.py" />
|
||||
<option value="$PROJECT_DIR$/core/api/actor.py" />
|
||||
<option value="$PROJECT_DIR$/core/api/cbpiactor.py" />
|
||||
<option value="$PROJECT_DIR$/core/api/sensor.py" />
|
||||
</list>
|
||||
</option>
|
||||
</component>
|
||||
<component name="JsBuildToolGruntFileManager" detection-done="true" sorting="DEFINITION_ORDER" />
|
||||
<component name="JsBuildToolPackageJson" detection-done="true" sorting="DEFINITION_ORDER" />
|
||||
<component name="JsGulpfileManager">
|
||||
|
@ -83,6 +314,128 @@
|
|||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="core" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="core" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="plugin.py" />
|
||||
<option name="myItemType" value="com.jetbrains.python.projectView.PyFileNode" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="core" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi.py" />
|
||||
<option name="myItemType" value="com.jetbrains.python.projectView.PyFileNode" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="core" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="extension" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="core" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="extension" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="dummy" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="core" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="api" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
<PATH>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="craftbeerpi4" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
<PATH_ELEMENT>
|
||||
<option name="myItemId" value="config" />
|
||||
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
|
||||
</PATH_ELEMENT>
|
||||
</PATH>
|
||||
</subPane>
|
||||
</pane>
|
||||
</panes>
|
||||
|
@ -92,6 +445,8 @@
|
|||
<property name="nodejs_interpreter_path" value="/usr/local/bin/node" />
|
||||
<property name="WebServerToolWindowFactoryState" value="false" />
|
||||
<property name="last_opened_file_path" value="$PROJECT_DIR$" />
|
||||
<property name="run.code.analysis.last.selected.profile" value="aDefault" />
|
||||
<property name="com.intellij.database.dataSource.DataSourceTemplate" value="Sqlite (Xerial)" />
|
||||
</component>
|
||||
<component name="RunDashboard">
|
||||
<option name="ruleStates">
|
||||
|
@ -292,27 +647,49 @@
|
|||
</component>
|
||||
<component name="ToolWindowManager">
|
||||
<frame x="55" y="40" width="1767" height="968" extended-state="0" />
|
||||
<editor active="true" />
|
||||
<layout>
|
||||
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.24957556" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
|
||||
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="true" content_ui="tabs" />
|
||||
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Run" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.32925472" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.3303671" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Python Console" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32925472" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.24957556" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
|
||||
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.21335597" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32925472" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.24957556" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.39933258" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="true" content_ui="tabs" />
|
||||
<window_info id="Data View" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" />
|
||||
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
||||
</layout>
|
||||
<layout-to-restore>
|
||||
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="10" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="8" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="true" content_ui="tabs" />
|
||||
<window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="9" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.32925472" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Python Console" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32925472" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.24957556" sideWeight="0.5" order="1" side_tool="false" content_ui="combo" />
|
||||
<window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="combo" />
|
||||
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.24957556" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
|
||||
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="true" content_ui="tabs" />
|
||||
<window_info id="Data View" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
|
||||
</layout-to-restore>
|
||||
</component>
|
||||
<component name="TypeScriptGeneratedFilesManager">
|
||||
<option name="processedProjectFiles" value="true" />
|
||||
|
@ -333,12 +710,266 @@
|
|||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/controller/step_controller.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/database/__init__.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/eventbus.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="-641">
|
||||
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/run.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="30">
|
||||
<caret line="2" column="20" lean-forward="false" selection-start-line="2" selection-start-column="20" selection-end-line="2" selection-end-column="20" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$APPLICATION_CONFIG_DIR$/consoles/db/5067e7fe-480d-4433-bc40-f2d1c38362a2/console.sql">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="dbDummy://dbtable:/a57e2371/5067e7fe-480d-4433-bc40-f2d1c38362a2/main.actor">
|
||||
<provider editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
<provider selected="true" editor-type-id="com.intellij.database.editor.DatabaseTableFileEditorProvider">
|
||||
<state>
|
||||
<filtering enabled="true" />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/database/model.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="180">
|
||||
<caret line="12" column="32" lean-forward="true" selection-start-line="12" selection-start-column="32" selection-end-line="12" selection-end-column="32" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/controller/crud_controller.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="105">
|
||||
<caret line="7" column="24" lean-forward="false" selection-start-line="7" selection-start-column="24" selection-end-line="7" selection-end-column="24" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/controller/fermentation_controller.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/controller/system_controller.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="135">
|
||||
<caret line="9" column="27" lean-forward="false" selection-start-line="9" selection-start-column="27" selection-end-line="9" selection-end-column="27" />
|
||||
<folding>
|
||||
<element signature="e#0#23#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/helper/__init__.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/helper/jsondump.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<folding>
|
||||
<element signature="e#0#16#0" expanded="true" />
|
||||
<element signature="e#0#11#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/http_endpoints/http_api.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="180">
|
||||
<caret line="12" column="23" lean-forward="false" selection-start-line="12" selection-start-column="23" selection-end-line="12" selection-end-column="23" />
|
||||
<folding>
|
||||
<element signature="e#0#14#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/mqtt/mqtt.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="540">
|
||||
<caret line="36" column="24" lean-forward="false" selection-start-line="36" selection-start-column="24" selection-end-line="36" selection-end-column="24" />
|
||||
<folding>
|
||||
<element signature="e#0#50#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/plugin.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="180">
|
||||
<caret line="12" column="11" lean-forward="true" selection-start-line="12" selection-start-column="11" selection-end-line="12" selection-end-column="11" />
|
||||
<folding>
|
||||
<element signature="e#0#25#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/websocket.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="105">
|
||||
<caret line="13" column="27" lean-forward="false" selection-start-line="13" selection-start-column="27" selection-end-line="13" selection-end-column="27" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/database/orm_framework.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="178">
|
||||
<caret line="39" column="25" lean-forward="false" selection-start-line="39" selection-start-column="25" selection-end-line="39" selection-end-column="25" />
|
||||
<folding>
|
||||
<element signature="e#0#11#0" expanded="true" />
|
||||
<marker date="1541102185698" expanded="true" signature="757:803" ph="..." />
|
||||
<marker date="1541102185698" expanded="true" signature="944:1121" ph="..." />
|
||||
<marker date="1541102185698" expanded="true" signature="1414:1447" ph="SELECT * FRO... missing_value" />
|
||||
<marker date="1541102185698" expanded="true" signature="1551:1565" ph="SELECT * FRO... missing_value" />
|
||||
<marker date="1541102185698" expanded="true" signature="2139:2168" ph="SELECT * FRO... missing_value" />
|
||||
<marker date="1541102185698" expanded="true" signature="2537:2564" ph="DELETE FROM " />
|
||||
<marker date="1541102185698" expanded="true" signature="2865:2903" ph="INSERT INTO missing_value... " />
|
||||
<marker date="1541102185698" expanded="true" signature="3495:3526" ph="INSERT INTO missing_value... " />
|
||||
<marker date="1541102185698" expanded="true" signature="4306:4335" ph="UPDATE missi... " />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/controller/sensor_controller.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="240">
|
||||
<caret line="16" column="20" lean-forward="false" selection-start-line="16" selection-start-column="20" selection-end-line="16" selection-end-column="20" />
|
||||
<folding>
|
||||
<element signature="e#0#14#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/controller/actor_controller.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="260">
|
||||
<caret line="33" column="27" lean-forward="false" selection-start-line="33" selection-start-column="27" selection-end-line="33" selection-end-column="27" />
|
||||
<folding>
|
||||
<element signature="e#0#23#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/config/config.yaml">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="12" lean-forward="false" selection-start-line="0" selection-start-column="12" selection-end-line="0" selection-end-column="12" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/helper/utils.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="105">
|
||||
<caret line="7" column="15" lean-forward="true" selection-start-line="7" selection-start-column="15" selection-end-line="7" selection-end-column="15" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/http_endpoints/http_login.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="375">
|
||||
<caret line="25" column="14" lean-forward="false" selection-start-line="25" selection-start-column="14" selection-end-line="25" selection-end-column="14" />
|
||||
<folding>
|
||||
<element signature="e#0#14#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/craftbeerpi.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="141">
|
||||
<caret line="21" column="0" lean-forward="false" selection-start-line="21" selection-start-column="0" selection-end-line="23" selection-end-column="0" />
|
||||
<folding>
|
||||
<element signature="e#0#14#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/extension/dummy/config.yaml">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="12" lean-forward="false" selection-start-line="0" selection-start-column="12" selection-end-line="0" selection-end-column="12" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/api/actor.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="105">
|
||||
<caret line="7" column="12" lean-forward="false" selection-start-line="7" selection-start-column="12" selection-end-line="7" selection-end-column="12" />
|
||||
<folding>
|
||||
<element signature="e#1#15#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/api/extension.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="0">
|
||||
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
|
||||
<folding>
|
||||
<element signature="e#0#14#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/api/sensor.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="195">
|
||||
<caret line="13" column="12" lean-forward="true" selection-start-line="13" selection-start-column="12" selection-end-line="13" selection-end-column="12" />
|
||||
<folding />
|
||||
</state>
|
||||
</provider>
|
||||
</entry>
|
||||
<entry file="file://$PROJECT_DIR$/core/extension/dummy/__init__.py">
|
||||
<provider selected="true" editor-type-id="text-editor">
|
||||
<state relative-caret-position="135">
|
||||
<caret line="9" column="17" lean-forward="false" selection-start-line="9" selection-start-column="17" selection-end-line="9" selection-end-column="17" />
|
||||
<folding>
|
||||
<element signature="e#0#42#0" expanded="true" />
|
||||
</folding>
|
||||
</state>
|
||||
</provider>
|
||||
|
|
1
config/config.yaml
Normal file
1
config/config.yaml
Normal file
|
@ -0,0 +1 @@
|
|||
name: Manuel
|
Binary file not shown.
BIN
core/__pycache__/craftbeerpi.cpython-36.pyc
Normal file
BIN
core/__pycache__/craftbeerpi.cpython-36.pyc
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -1,8 +1,13 @@
|
|||
|
||||
import logging
|
||||
|
||||
class Actor():
|
||||
from core.api.extension import CBPiExtension
|
||||
from core.helper.utils import load_config as load
|
||||
logger = logging.getLogger(__file__)
|
||||
|
||||
def __init__(self):
|
||||
class CBPiActor(CBPiExtension):
|
||||
|
||||
def __init__(self, cbpi):
|
||||
self.id = "";
|
||||
self.name = ""
|
||||
|
||||
|
|
16
core/api/extension.py
Normal file
16
core/api/extension.py
Normal file
|
@ -0,0 +1,16 @@
|
|||
import logging
|
||||
|
||||
from core.helper.utils import load_config as load
|
||||
logger = logging.getLogger(__file__)
|
||||
logging.basicConfig(level=logging.INFO)
|
||||
|
||||
class CBPiExtension():
|
||||
|
||||
def load_config(self):
|
||||
|
||||
|
||||
path = os.path.dirname(sys.modules[self.__class__.__module__].__file__)
|
||||
try:
|
||||
return load("%s/config.yaml" % path)
|
||||
except:
|
||||
logger.warning("Faild to load config %s/config.yaml" % path)
|
|
@ -1,4 +1,7 @@
|
|||
class Sensor():
|
||||
from core.api.extension import CBPiExtension
|
||||
|
||||
|
||||
class CBPiSensor(CBPiExtension):
|
||||
|
||||
def __init__(self):
|
||||
self.id = "";
|
||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -8,12 +8,29 @@ from core.http_endpoints.http_api import HttpAPI
|
|||
from core.plugin import PluginAPI
|
||||
|
||||
|
||||
class ActorController(HttpAPI, CRUDController, PluginAPI):
|
||||
class ActorHttp(HttpAPI):
|
||||
|
||||
@request_mapping(path="/hallo", auth_required=False)
|
||||
async def hello_world(self, request) -> web.Response:
|
||||
print("HALLO")
|
||||
return web.Response(status=200, text="OK")
|
||||
|
||||
@request_mapping(path="/{id}/on", auth_required=False)
|
||||
async def http_on(self, request) -> web.Response:
|
||||
"""
|
||||
|
||||
:param request:
|
||||
:return:
|
||||
"""
|
||||
self.cbpi.bus.fire(event="actor/1/on", id=1, power=99)
|
||||
return web.Response(status=204)
|
||||
|
||||
|
||||
|
||||
class ActorController(ActorHttp, CRUDController, PluginAPI):
|
||||
|
||||
model = ActorModel
|
||||
|
||||
|
||||
def __init__(self, cbpi):
|
||||
super(ActorController, self).__init__(cbpi)
|
||||
self.cbpi = cbpi
|
||||
|
@ -23,7 +40,6 @@ class ActorController(HttpAPI, CRUDController, PluginAPI):
|
|||
self.types = {}
|
||||
self.actors = {}
|
||||
|
||||
|
||||
async def init(self):
|
||||
|
||||
await super(ActorController, self).init()
|
||||
|
@ -38,33 +54,27 @@ class ActorController(HttpAPI, CRUDController, PluginAPI):
|
|||
print("CACHE", self.cache)
|
||||
print("ACTORS", self.actors)
|
||||
|
||||
@request_mapping(path="/{id}/on",auth_required=False)
|
||||
async def http_on(self, request) -> web.Response:
|
||||
self.cbpi.bus.fire(event="actor/1/on", id=1, power=99)
|
||||
return web.Response(status=204)
|
||||
|
||||
|
||||
@on_event(topic="actor/+/on")
|
||||
def on(self, id, power=100) -> None:
|
||||
def on(self, id, power=100, **kwargs) -> None:
|
||||
print("ON-------------", id, power)
|
||||
if id in self.actors:
|
||||
i = self.actors[id]
|
||||
i.on(power)
|
||||
|
||||
@on_event(topic="actor/+/on")
|
||||
def on2(self, id, **kwargs) -> None:
|
||||
@on_event(topic="actor/+/off")
|
||||
def off(self, id, **kwargs) -> None:
|
||||
"""
|
||||
|
||||
:param id:
|
||||
:param kwargs:
|
||||
"""
|
||||
print("POWERED ON", id, kwargs)
|
||||
|
||||
|
||||
|
||||
def register(self, name, clazz) -> None:
|
||||
'''
|
||||
Register a new actor type
|
||||
:param name: actor name
|
||||
:param clazz: actor class
|
||||
:return: None
|
||||
'''
|
||||
self._parse_props(clazz)
|
||||
self.types[name] = clazz
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -4,8 +4,8 @@ class CRUDController(object):
|
|||
cache = {}
|
||||
caching = True
|
||||
|
||||
def __init__(self, core):
|
||||
self.cbpi = core
|
||||
def __init__(self, cbpi):
|
||||
self.cbpi = cbpi
|
||||
self.cache = {}
|
||||
|
||||
async def init(self):
|
||||
|
@ -54,7 +54,7 @@ class CRUDController(object):
|
|||
except:
|
||||
pass
|
||||
m = await self.model.update(**data)
|
||||
#self.core.push_ws("UPDATE_%s" % self.key, m)
|
||||
#self.cbpi.push_ws("UPDATE_%s" % self.key, m)
|
||||
|
||||
await self._post_update_callback(m)
|
||||
if self.caching is True:
|
||||
|
@ -77,10 +77,10 @@ class CRUDController(object):
|
|||
except Exception as e:
|
||||
pass
|
||||
|
||||
#self.core.push("DELETE_%s" % self.key, id)
|
||||
#self.cbpi.push("DELETE_%s" % self.key, id)
|
||||
|
||||
async def delete_all(self):
|
||||
self.model.delete_all()
|
||||
if self.caching is True:
|
||||
self.cache = {}
|
||||
#self.core.push_ws("DELETE_ALL_%s" % self.key, None)
|
||||
#self.cbpi.push_ws("DELETE_ALL_%s" % self.key, None)
|
|
@ -13,9 +13,9 @@ class SensorController(CRUDController, HttpAPI):
|
|||
|
||||
model = SensorModel
|
||||
|
||||
def __init__(self, core):
|
||||
self.core = core
|
||||
self.core.register(self, "/sensor")
|
||||
def __init__(self, cbpi):
|
||||
self.cbpi = cbpi
|
||||
self.cbpi.register(self, "/sensor")
|
||||
self.service = self
|
||||
|
||||
self.sensors = {"S1": "S1", "S2": "S2"}
|
||||
|
|
|
@ -7,14 +7,14 @@ from core.api.decorator import request_mapping
|
|||
class SystemController():
|
||||
name = "Manuel"
|
||||
|
||||
def __init__(self, core):
|
||||
self.core = core
|
||||
self.service = core.actor
|
||||
self.core.register(self, "/system")
|
||||
def __init__(self, cbpi):
|
||||
self.cbpi = cbpi
|
||||
self.service = cbpi.actor
|
||||
self.cbpi.register(self, "/system")
|
||||
|
||||
@request_mapping("/jobs", method="GET", name="get_jobs", auth_required=True)
|
||||
def get_all_jobs(self, request):
|
||||
scheduler = get_scheduler_from_app(self.core.app)
|
||||
scheduler = get_scheduler_from_app(self.cbpi.app)
|
||||
print(scheduler.active_count, scheduler.pending_limit)
|
||||
for j in scheduler:
|
||||
print(j)
|
||||
|
|
|
@ -12,13 +12,11 @@ from aiohttp_swagger import setup_swagger
|
|||
from aiojobs.aiohttp import setup, get_scheduler_from_app
|
||||
|
||||
from core.controller.actor_controller import ActorController
|
||||
from core.controller.sensor_controller import SensorController
|
||||
from core.controller.system_controller import SystemController
|
||||
from core.database.model import DBModel
|
||||
from core.eventbus import EventBus
|
||||
|
||||
|
||||
from core.http_endpoints.http_login import Login
|
||||
from core.controller.sensor_controller import SensorController
|
||||
from core.websocket import WebSocket
|
||||
|
||||
logger = logging.getLogger(__file__)
|
||||
|
@ -26,7 +24,6 @@ logging.basicConfig(level=logging.INFO)
|
|||
|
||||
|
||||
class CraftBeerPi():
|
||||
|
||||
def __init__(self):
|
||||
|
||||
logger.info("Init CraftBeerPI")
|
||||
|
@ -44,7 +41,7 @@ class CraftBeerPi():
|
|||
|
||||
def register_events(self, obj):
|
||||
|
||||
for method in [getattr(obj, f) for f in dir(obj) if callable(getattr(obj, f)) and hasattr(getattr(obj, f),"eventbus")]:
|
||||
for method in [getattr(obj, f) for f in dir(obj) if callable(getattr(obj, f)) and hasattr(getattr(obj, f), "eventbus")]:
|
||||
print(method.__getattribute__("topic"), method)
|
||||
|
||||
doc = None
|
||||
|
@ -53,14 +50,13 @@ class CraftBeerPi():
|
|||
doc["topic"] = method.__getattribute__("topic")
|
||||
self.bus.register(method.__getattribute__("topic"), method, doc)
|
||||
|
||||
|
||||
def register_background_task(self, obj):
|
||||
for method in [getattr(obj, f) for f in dir(obj) if callable(getattr(obj, f)) and hasattr(getattr(obj, f), "background_task")]:
|
||||
name = method.__getattribute__("name")
|
||||
interval = method.__getattribute__("interval")
|
||||
|
||||
async def job_loop(app, name, interval, method):
|
||||
logger.info("Start Background Task %s Interval %s Method %s" % (name,interval, method))
|
||||
logger.info("Start Background Task %s Interval %s Method %s" % (name, interval, method))
|
||||
while True:
|
||||
logger.info("Execute Task %s - interval(%s second(s)" % (name, interval))
|
||||
await asyncio.sleep(interval)
|
||||
|
@ -70,16 +66,13 @@ class CraftBeerPi():
|
|||
scheduler = get_scheduler_from_app(self.app)
|
||||
await scheduler.spawn(job_loop(self.app, name, interval, method))
|
||||
|
||||
|
||||
self.app.on_startup.append(spawn_job)
|
||||
|
||||
|
||||
|
||||
def register_ws(self, obj):
|
||||
if self.ws is None:
|
||||
return
|
||||
|
||||
for method in [getattr(obj, f) for f in dir(obj) if callable(getattr(obj, f)) and hasattr(getattr(obj, f),"ws")]:
|
||||
for method in [getattr(obj, f) for f in dir(obj) if callable(getattr(obj, f)) and hasattr(getattr(obj, f), "ws")]:
|
||||
self.ws.add_callback(method, method.__getattribute__("key"))
|
||||
|
||||
def register(self, obj, subapp=None):
|
||||
|
@ -88,13 +81,13 @@ class CraftBeerPi():
|
|||
self.register_ws(obj)
|
||||
self.register_background_task(obj)
|
||||
|
||||
|
||||
def register_http_endpoints(self, obj, subapp=None):
|
||||
routes = []
|
||||
for method in [getattr(obj, f) for f in dir(obj) if callable(getattr(obj, f)) and hasattr(getattr(obj, f), "route")]:
|
||||
|
||||
http_method = method.__getattribute__("method")
|
||||
path = method.__getattribute__("path")
|
||||
class_name = method.__self__.__class__.__name__
|
||||
logger.info("Register Endpoint : %s.%s %s %s%s " % (class_name, method.__name__, http_method, subapp, path))
|
||||
|
||||
def add_post():
|
||||
routes.append(web.post(method.__getattribute__("path"), method))
|
||||
|
@ -107,6 +100,7 @@ class CraftBeerPi():
|
|||
|
||||
def add_put():
|
||||
routes.append(web.put(path, method))
|
||||
|
||||
switcher = {
|
||||
"POST": add_post,
|
||||
"GET": add_get,
|
||||
|
@ -131,7 +125,6 @@ class CraftBeerPi():
|
|||
my_module = importlib.import_module(extension)
|
||||
my_module.setup(self)
|
||||
|
||||
|
||||
def start(self):
|
||||
|
||||
async def init_database(app):
|
||||
|
@ -140,13 +133,8 @@ class CraftBeerPi():
|
|||
async def init_controller(app):
|
||||
await self.actor.init()
|
||||
|
||||
|
||||
|
||||
|
||||
self.app.on_startup.append(init_database)
|
||||
self.app.on_startup.append(self._load_extensions)
|
||||
self.app.on_startup.append(init_controller)
|
||||
setup_swagger(self.app)
|
||||
web.run_app(self.app)
|
||||
|
||||
|
Binary file not shown.
BIN
core/database/__pycache__/orm_framework.cpython-36.pyc
Normal file
BIN
core/database/__pycache__/orm_framework.cpython-36.pyc
Normal file
Binary file not shown.
|
@ -1,156 +1,13 @@
|
|||
import json
|
||||
|
||||
import aiosqlite
|
||||
|
||||
TEST_DB = "./craftbeerpi.db"
|
||||
|
||||
|
||||
|
||||
class DBModel(object):
|
||||
|
||||
__priamry_key__ = "id"
|
||||
__as_array__ = False
|
||||
__order_by__ = None
|
||||
__json_fields__ = []
|
||||
|
||||
def __init__(self, args):
|
||||
|
||||
self.__setattr__(self.__priamry_key__, args[self.__priamry_key__])
|
||||
for f in self.__fields__:
|
||||
if f in self.__json_fields__:
|
||||
if args[f] is not None:
|
||||
|
||||
if isinstance(args[f], dict) or isinstance(args[f], list):
|
||||
self.__setattr__(f, args[f])
|
||||
else:
|
||||
self.__setattr__(f, json.loads(args[f]))
|
||||
else:
|
||||
self.__setattr__(f, None)
|
||||
else:
|
||||
print(f,args[f])
|
||||
self.__setattr__(f, args[f])
|
||||
|
||||
@classmethod
|
||||
async def test_connection(self):
|
||||
|
||||
print("CREATE DATABSE")
|
||||
async with aiosqlite.connect(TEST_DB) as db:
|
||||
print("DB OK")
|
||||
assert isinstance(db, aiosqlite.Connection)
|
||||
qry = open('./core/sql/create_table_user.sql', 'r').read()
|
||||
cursor = await db.executescript(qry)
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@classmethod
|
||||
async def get_all(cls):
|
||||
print("GET ALL")
|
||||
if cls.__as_array__ is True:
|
||||
result = []
|
||||
else:
|
||||
result = {}
|
||||
async with aiosqlite.connect(TEST_DB) as db:
|
||||
|
||||
if cls.__order_by__ is not None:
|
||||
sql = "SELECT * FROM %s ORDER BY %s.'%s'" % (cls.__table_name__,cls.__table_name__,cls.__order_by__)
|
||||
else:
|
||||
sql = "SELECT * FROM %s" % cls.__table_name__
|
||||
|
||||
db.row_factory = aiosqlite.Row
|
||||
async with db.execute(sql) as cursor:
|
||||
async for row in cursor:
|
||||
if cls.__as_array__ is True:
|
||||
result.append(cls(row))
|
||||
else:
|
||||
result[row[0]] = cls(row)
|
||||
await cursor.close()
|
||||
|
||||
return result
|
||||
|
||||
@classmethod
|
||||
async def get_one(cls, id):
|
||||
async with aiosqlite.connect(TEST_DB) as db:
|
||||
db.row_factory = aiosqlite.Row
|
||||
async with db.execute("SELECT * FROM %s WHERE %s = ?" % (cls.__table_name__, cls.__priamry_key__), (id,)) as cursor:
|
||||
row = await cursor.fetchone()
|
||||
if row is not None:
|
||||
return cls(row)
|
||||
else:
|
||||
return None
|
||||
|
||||
@classmethod
|
||||
async def delete(cls, id):
|
||||
async with aiosqlite.connect(TEST_DB) as db:
|
||||
await db.execute("DELETE FROM %s WHERE %s = ? " % (cls.__table_name__, cls.__priamry_key__), (id,))
|
||||
await db.commit()
|
||||
|
||||
@classmethod
|
||||
async def insert(cls, **kwargs):
|
||||
|
||||
async with aiosqlite.connect(TEST_DB) as db:
|
||||
if cls.__priamry_key__ is not None and cls.__priamry_key__ in kwargs:
|
||||
query = "INSERT INTO %s (%s, %s) VALUES (?, %s)" % (
|
||||
cls.__table_name__,
|
||||
cls.__priamry_key__,
|
||||
', '.join("'%s'" % str(x) for x in cls.__fields__),
|
||||
', '.join(['?'] * len(cls.__fields__)))
|
||||
data = ()
|
||||
data = data + (kwargs.get(cls.__priamry_key__),)
|
||||
for f in cls.__fields__:
|
||||
if f in cls.__json_fields__:
|
||||
data = data + (json.dumps(kwargs.get(f)),)
|
||||
else:
|
||||
data = data + (kwargs.get(f),)
|
||||
else:
|
||||
|
||||
query = 'INSERT INTO %s (%s) VALUES (%s)' % (
|
||||
cls.__table_name__,
|
||||
', '.join("'%s'" % str(x) for x in cls.__fields__),
|
||||
', '.join(['?'] * len(cls.__fields__)))
|
||||
|
||||
data = ()
|
||||
for f in cls.__fields__:
|
||||
if f in cls.__json_fields__:
|
||||
data = data + (json.dumps(kwargs.get(f)),)
|
||||
else:
|
||||
data = data + (kwargs.get(f),)
|
||||
|
||||
print(query, data)
|
||||
cursor = await db.execute(query, data)
|
||||
await db.commit()
|
||||
|
||||
i = cursor.lastrowid
|
||||
kwargs["id"] = i
|
||||
|
||||
return cls(kwargs)
|
||||
|
||||
@classmethod
|
||||
async def update(cls, **kwargs):
|
||||
async with aiosqlite.connect(TEST_DB) as db:
|
||||
query = 'UPDATE %s SET %s WHERE %s = ?' % (cls.__table_name__, ', '.join("'%s' = ?" % str(x) for x in cls.__fields__), cls.__priamry_key__)
|
||||
|
||||
data = ()
|
||||
for f in cls.__fields__:
|
||||
if f in cls.__json_fields__:
|
||||
data = data + (json.dumps(kwargs.get(f)),)
|
||||
else:
|
||||
data = data + (kwargs.get(f),)
|
||||
|
||||
data = data + (kwargs.get(cls.__priamry_key__),)
|
||||
cursor = await db.execute(query, data)
|
||||
await db.commit()
|
||||
return cls(kwargs)
|
||||
from core.database.orm_framework import DBModel
|
||||
|
||||
|
||||
class ActorModel(DBModel):
|
||||
__fields__ = ["name","type","config"]
|
||||
__fields__ = ["name", "type", "config"]
|
||||
__table_name__ = "actor"
|
||||
__json_fields__ = ["config"]
|
||||
|
||||
|
||||
class SensorModel(DBModel):
|
||||
__fields__ = ["name","type", "config"]
|
||||
__fields__ = ["name", "type", "config"]
|
||||
__table_name__ = "sensor"
|
||||
__json_fields__ = ["config"]
|
||||
__json_fields__ = ["config"]
|
||||
|
|
|
@ -0,0 +1,142 @@
|
|||
import json
|
||||
|
||||
import aiosqlite
|
||||
|
||||
# Thats the name of the database file
|
||||
TEST_DB = "./craftbeerpi.db"
|
||||
|
||||
|
||||
|
||||
class DBModel(object):
|
||||
__priamry_key__ = "id"
|
||||
__as_array__ = False
|
||||
__order_by__ = None
|
||||
__json_fields__ = []
|
||||
|
||||
def __init__(self, args):
|
||||
|
||||
self.__setattr__(self.__priamry_key__, args[self.__priamry_key__])
|
||||
for f in self.__fields__:
|
||||
if f in self.__json_fields__:
|
||||
if args[f] is not None:
|
||||
|
||||
if isinstance(args[f], dict) or isinstance(args[f], list):
|
||||
self.__setattr__(f, args[f])
|
||||
else:
|
||||
self.__setattr__(f, json.loads(args[f]))
|
||||
else:
|
||||
self.__setattr__(f, None)
|
||||
else:
|
||||
|
||||
self.__setattr__(f, args[f])
|
||||
|
||||
@classmethod
|
||||
async def test_connection(self):
|
||||
|
||||
print("CREATE DATABSE")
|
||||
async with aiosqlite.connect(TEST_DB) as db:
|
||||
|
||||
assert isinstance(db, aiosqlite.Connection)
|
||||
qry = open('./core/sql/create_table_user.sql', 'r').read()
|
||||
cursor = await db.executescript(qry)
|
||||
|
||||
@classmethod
|
||||
async def get_all(cls):
|
||||
print("GET ALL")
|
||||
if cls.__as_array__ is True:
|
||||
result = []
|
||||
else:
|
||||
result = {}
|
||||
async with aiosqlite.connect(TEST_DB) as db:
|
||||
|
||||
if cls.__order_by__ is not None:
|
||||
sql = "SELECT * FROM %s ORDER BY %s.'%s'" % (cls.__table_name__, cls.__table_name__, cls.__order_by__)
|
||||
else:
|
||||
sql = "SELECT * FROM %s" % cls.__table_name__
|
||||
|
||||
db.row_factory = aiosqlite.Row
|
||||
async with db.execute(sql) as cursor:
|
||||
async for row in cursor:
|
||||
if cls.__as_array__ is True:
|
||||
result.append(cls(row))
|
||||
else:
|
||||
result[row[0]] = cls(row)
|
||||
await cursor.close()
|
||||
|
||||
return result
|
||||
|
||||
@classmethod
|
||||
async def get_one(cls, id):
|
||||
async with aiosqlite.connect(TEST_DB) as db:
|
||||
db.row_factory = aiosqlite.Row
|
||||
async with db.execute("SELECT * FROM %s WHERE %s = ?" % (cls.__table_name__, cls.__priamry_key__), (id,)) as cursor:
|
||||
row = await cursor.fetchone()
|
||||
if row is not None:
|
||||
return cls(row)
|
||||
else:
|
||||
return None
|
||||
|
||||
@classmethod
|
||||
async def delete(cls, id):
|
||||
async with aiosqlite.connect(TEST_DB) as db:
|
||||
await db.execute("DELETE FROM %s WHERE %s = ? " % (cls.__table_name__, cls.__priamry_key__), (id,))
|
||||
await db.commit()
|
||||
|
||||
@classmethod
|
||||
async def insert(cls, **kwargs):
|
||||
|
||||
async with aiosqlite.connect(TEST_DB) as db:
|
||||
if cls.__priamry_key__ is not None and cls.__priamry_key__ in kwargs:
|
||||
query = "INSERT INTO %s (%s, %s) VALUES (?, %s)" % (
|
||||
cls.__table_name__,
|
||||
cls.__priamry_key__,
|
||||
', '.join("'%s'" % str(x) for x in cls.__fields__),
|
||||
', '.join(['?'] * len(cls.__fields__)))
|
||||
data = ()
|
||||
data = data + (kwargs.get(cls.__priamry_key__),)
|
||||
for f in cls.__fields__:
|
||||
if f in cls.__json_fields__:
|
||||
data = data + (json.dumps(kwargs.get(f)),)
|
||||
else:
|
||||
data = data + (kwargs.get(f),)
|
||||
else:
|
||||
|
||||
query = 'INSERT INTO %s (%s) VALUES (%s)' % (
|
||||
cls.__table_name__,
|
||||
', '.join("'%s'" % str(x) for x in cls.__fields__),
|
||||
', '.join(['?'] * len(cls.__fields__)))
|
||||
|
||||
data = ()
|
||||
for f in cls.__fields__:
|
||||
if f in cls.__json_fields__:
|
||||
data = data + (json.dumps(kwargs.get(f)),)
|
||||
else:
|
||||
data = data + (kwargs.get(f),)
|
||||
|
||||
print(query, data)
|
||||
cursor = await db.execute(query, data)
|
||||
await db.commit()
|
||||
|
||||
i = cursor.lastrowid
|
||||
kwargs["id"] = i
|
||||
|
||||
return cls(kwargs)
|
||||
|
||||
@classmethod
|
||||
async def update(cls, **kwargs):
|
||||
async with aiosqlite.connect(TEST_DB) as db:
|
||||
query = 'UPDATE %s SET %s WHERE %s = ?' % (cls.__table_name__, ', '.join("'%s' = ?" % str(x) for x in cls.__fields__), cls.__priamry_key__)
|
||||
|
||||
data = ()
|
||||
for f in cls.__fields__:
|
||||
if f in cls.__json_fields__:
|
||||
data = data + (json.dumps(kwargs.get(f)),)
|
||||
else:
|
||||
data = data + (kwargs.get(f),)
|
||||
|
||||
data = data + (kwargs.get(cls.__priamry_key__),)
|
||||
cursor = await db.execute(query, data)
|
||||
await db.commit()
|
||||
return cls(kwargs)
|
||||
|
||||
|
|
@ -1,14 +1,13 @@
|
|||
from core.database.model import ActorModel
|
||||
from core.api.decorator import action, background_task
|
||||
from core.api.property import Property
|
||||
print("##################")
|
||||
|
||||
from core.api.actor import Actor
|
||||
|
||||
from core.api.actor import CBPiActor
|
||||
import logging
|
||||
|
||||
|
||||
class MyActor(Actor):
|
||||
|
||||
class MyActor(CBPiActor):
|
||||
|
||||
name = Property.Number(label="Test")
|
||||
name1 = Property.Text(label="Test")
|
||||
|
@ -20,7 +19,7 @@ class MyActor(Actor):
|
|||
|
||||
@action(key="name", parameters={})
|
||||
def myAction(self):
|
||||
print("HALLO")
|
||||
pass
|
||||
|
||||
def state(self):
|
||||
super().state()
|
||||
|
@ -31,13 +30,18 @@ class MyActor(Actor):
|
|||
def on(self, power=100):
|
||||
super().on(power)
|
||||
|
||||
def __init__(self):
|
||||
pass
|
||||
def __init__(self,cbpi=None):
|
||||
|
||||
def __init__(self, core=None):
|
||||
self.logger = logging.getLogger(__name__)
|
||||
self.logger.info("WOOHOO MY ACTOR")
|
||||
self.core = None
|
||||
if cbpi is None:
|
||||
return
|
||||
|
||||
self.cfg = self.load_config()
|
||||
print(self.cfg)
|
||||
self.logger = logging.getLogger(__file__)
|
||||
logging.basicConfig(level=logging.INFO)
|
||||
|
||||
self.logger.info("########WOOHOO MY ACTOR")
|
||||
self.cbpi = cbpi
|
||||
|
||||
|
||||
def setup(cbpi):
|
||||
|
|
Binary file not shown.
1
core/extension/dummy/config.yaml
Normal file
1
core/extension/dummy/config.yaml
Normal file
|
@ -0,0 +1 @@
|
|||
name: Maneul
|
Binary file not shown.
BIN
core/helper/__pycache__/utils.cpython-36.pyc
Normal file
BIN
core/helper/__pycache__/utils.cpython-36.pyc
Normal file
Binary file not shown.
8
core/helper/utils.py
Normal file
8
core/helper/utils.py
Normal file
|
@ -0,0 +1,8 @@
|
|||
import yaml
|
||||
|
||||
|
||||
def load_config(fname):
|
||||
with open(fname, 'rt') as f:
|
||||
data = yaml.load(f)
|
||||
# TODO: add config validation
|
||||
return data
|
Binary file not shown.
Binary file not shown.
|
@ -7,10 +7,10 @@ from core.helper.jsondump import json_dumps
|
|||
|
||||
class HttpAPI():
|
||||
|
||||
def __init__(self, core):
|
||||
def __init__(self,cbpi):
|
||||
self.logger = logging.getLogger(__name__)
|
||||
self.logger.info("WOOHOO MY ACTOR")
|
||||
self.cbpi = core
|
||||
self.cbpi =cbpi
|
||||
|
||||
@request_mapping(path="/", auth_required=False)
|
||||
async def http_get_all(self, request):
|
||||
|
|
|
@ -1,21 +1,31 @@
|
|||
import pathlib
|
||||
|
||||
from aiohttp import web
|
||||
from aiohttp_auth import auth
|
||||
|
||||
from core.api.decorator import request_mapping
|
||||
from core.helper.utils import load_config
|
||||
|
||||
|
||||
class Login():
|
||||
|
||||
def __init__(self, core):
|
||||
core.app.router.add_route('POST', '/login', self.login_view)
|
||||
core.app.router.add_route('GET', '/logout', self.logout_view)
|
||||
def __init__(self,cbpi):
|
||||
self.cbpi = cbpi
|
||||
self.cbpi.register(self)
|
||||
cfg = load_config(str(pathlib.Path('.') / 'config' / 'config.yaml'))
|
||||
|
||||
print("######", cfg)
|
||||
self.db = {'user': 'password', 'super_user': 'super_password'}
|
||||
|
||||
@auth.auth_required
|
||||
@request_mapping(path="/logout", name="Logout", method="GET", auth_required=True)
|
||||
async def logout_view(self, request):
|
||||
await auth.forget(request)
|
||||
return web.Response(body='OK'.encode('utf-8'))
|
||||
|
||||
@request_mapping(path="/login",name="Login", method="POST", auth_required=False)
|
||||
async def login_view(self, request):
|
||||
params = await request.post()
|
||||
print("HALLO LOGIN")
|
||||
|
||||
print(params.get('username', None), params.get('password', None))
|
||||
user = params.get('username', None)
|
||||
if (user in self.db and
|
||||
|
|
|
@ -8,7 +8,7 @@ from core.mqtt_matcher import MQTTMatcher
|
|||
|
||||
|
||||
class MQTT():
|
||||
def __init__(self, core):
|
||||
def __init__(self,cbpi):
|
||||
|
||||
self.config = {
|
||||
'listeners': {
|
||||
|
@ -30,16 +30,16 @@ class MQTT():
|
|||
},
|
||||
'auth': {
|
||||
'allow-anonymous': True,
|
||||
'password-file': '/Users/manuelfritsch/github/aio_sample/core/user.txt'
|
||||
'password-file': '/Users/manuelfritsch/github/aio_sample.cbpi/user.txt'
|
||||
}
|
||||
}
|
||||
|
||||
self.core = core
|
||||
self.cbpi = cbpi
|
||||
self.broker = Broker(self.config, plugin_namespace="hbmqtt.broker.plugins")
|
||||
self.client = MQTTClient()
|
||||
self.matcher = MQTTMatcher()
|
||||
self.mqtt_methods = {"test": self.ok_msg, "$SYS/broker/#": self.sysmsg}
|
||||
self.core.app.on_startup.append(self.start_broker)
|
||||
self.cbpi.app.on_startup.append(self.start_broker)
|
||||
self.count = 0
|
||||
|
||||
def sysmsg(self, msg):
|
||||
|
@ -52,7 +52,7 @@ class MQTT():
|
|||
|
||||
def publish(self, topic, message):
|
||||
print("PUSH NOW", topic)
|
||||
self.core.app.loop.create_task(self.client.publish(topic, str.encode(message), QOS_0))
|
||||
self.cbpi.app.loop.create_task(self.client.publish(topic, str.encode(message), QOS_0))
|
||||
|
||||
def register_callback(self, func: Callable, topic) -> None:
|
||||
|
||||
|
|
|
@ -4,7 +4,15 @@ from core.api.property import Property
|
|||
|
||||
|
||||
class PluginAPI():
|
||||
|
||||
def register(self, name, clazz) -> None:
|
||||
'''
|
||||
Register a new actor type
|
||||
:param name: actor name
|
||||
:param clazz: actor class
|
||||
:return: None
|
||||
'''
|
||||
self._parse_props(clazz)
|
||||
self.types[name] = clazz
|
||||
|
||||
def _parse_props(self, cls):
|
||||
|
||||
|
@ -12,7 +20,6 @@ class PluginAPI():
|
|||
|
||||
result = {"name": name, "class": cls, "properties": [], "actions": []}
|
||||
|
||||
|
||||
tmpObj = cls()
|
||||
members = [attr for attr in dir(tmpObj) if not callable(getattr(tmpObj, attr)) and not attr.startswith("__")]
|
||||
for m in members:
|
||||
|
@ -39,8 +46,8 @@ class PluginAPI():
|
|||
result["properties"].append({"name": m, "label": t.label, "type": "kettle", "configurable": t.configurable, "description": t.description})
|
||||
|
||||
for method_name, method in cls.__dict__.items():
|
||||
if hasattr(method, "action"):
|
||||
key = method.__getattribute__("key")
|
||||
parameters = method.__getattribute__("parameters")
|
||||
result["actions"].append({"method": method_name, "label": key, "parameters": parameters})
|
||||
pprint(result, width=200)
|
||||
if hasattr(method, "action"):
|
||||
key = method.__getattribute__("key")
|
||||
parameters = method.__getattribute__("parameters")
|
||||
result["actions"].append({"method": method_name, "label": key, "parameters": parameters})
|
||||
pprint(result, width=200)
|
||||
|
|
|
@ -11,12 +11,12 @@ from typing import Iterable, Callable
|
|||
|
||||
class WebSocket:
|
||||
|
||||
def __init__(self, core) -> None:
|
||||
self.core = core
|
||||
def __init__(self, cbpi) -> None:
|
||||
self.cbpi = cbpi
|
||||
self._callbacks = defaultdict(set)
|
||||
self._clients = weakref.WeakSet()
|
||||
self.logger = logging.getLogger(__name__)
|
||||
self.core.app.add_routes([web.get('/ws', self.websocket_handler)])
|
||||
self.cbpi.app.add_routes([web.get('/ws', self.websocket_handler)])
|
||||
|
||||
def add_callback(self, func: Callable, event: str) -> None:
|
||||
self._callbacks[event].add(func)
|
||||
|
@ -51,7 +51,7 @@ class WebSocket:
|
|||
|
||||
|
||||
|
||||
self.core.bus.fire(msg_obj["topic"], id=1, power=22)
|
||||
self.cbpi.bus.fire(msg_obj["topic"], id=1, power=22)
|
||||
#await self.fire(msg_obj["key"], ws, msg)
|
||||
|
||||
#await ws.send_str(msg.data)
|
||||
|
|
BIN
craftbeerpi.db
BIN
craftbeerpi.db
Binary file not shown.
|
@ -1 +1,15 @@
|
|||
2018-11-01 19:49:28,690,1,WOOHO
|
||||
2018-11-01 21:25:19,670,1,WOOHO
|
||||
2018-11-01 21:25:20,673,1,WOOHO
|
||||
2018-11-01 21:25:21,677,1,WOOHO
|
||||
2018-11-01 21:25:22,682,1,WOOHO
|
||||
2018-11-01 21:25:23,686,1,WOOHO
|
||||
2018-11-01 21:25:24,690,1,WOOHO
|
||||
2018-11-01 21:25:25,693,1,WOOHO
|
||||
2018-11-01 21:25:26,698,1,WOOHO
|
||||
2018-11-01 21:25:27,702,1,WOOHO
|
||||
2018-11-01 21:25:28,707,1,WOOHO
|
||||
2018-11-01 21:25:29,710,1,WOOHO
|
||||
2018-11-01 21:25:30,713,1,WOOHO
|
||||
2018-11-01 21:25:31,715,1,WOOHO
|
||||
2018-11-01 21:25:32,719,1,WOOHO
|
||||
2018-11-01 21:25:33,723,1,WOOHO
|
||||
|
|
|
@ -1,4 +0,0 @@
|
|||
2018-11-01 17:20:45,660,1,WOOHO
|
||||
2018-11-01 17:20:46,666,1,WOOHO
|
||||
2018-11-01 17:21:25,509,1,WOOHO
|
||||
2018-11-01 17:21:26,512,1,WOOHO
|
|
@ -1,2 +0,0 @@
|
|||
2018-11-01 17:23:12,685,1,WOOHO
|
||||
2018-11-01 17:23:13,691,1,WOOHO
|
|
@ -1 +0,0 @@
|
|||
2018-11-01 17:24:28,706,1,WOOHO
|
|
@ -1,2 +0,0 @@
|
|||
2018-11-01 17:27:21,293,1,WOOHO
|
||||
2018-11-01 17:27:22,302,1,WOOHO
|
|
@ -1,61 +0,0 @@
|
|||
2018-11-01 17:31:36,985,1,WOOHO
|
||||
2018-11-01 17:31:37,991,1,WOOHO
|
||||
2018-11-01 17:31:38,993,1,WOOHO
|
||||
2018-11-01 17:31:39,994,1,WOOHO
|
||||
2018-11-01 17:31:40,996,1,WOOHO
|
||||
2018-11-01 17:31:42,000,1,WOOHO
|
||||
2018-11-01 17:31:43,001,1,WOOHO
|
||||
2018-11-01 17:31:44,005,1,WOOHO
|
||||
2018-11-01 17:31:45,007,1,WOOHO
|
||||
2018-11-01 17:31:46,013,1,WOOHO
|
||||
2018-11-01 17:31:47,014,1,WOOHO
|
||||
2018-11-01 17:31:48,020,1,WOOHO
|
||||
2018-11-01 17:31:49,024,1,WOOHO
|
||||
2018-11-01 17:31:50,028,1,WOOHO
|
||||
2018-11-01 17:31:51,032,1,WOOHO
|
||||
2018-11-01 17:31:52,040,1,WOOHO
|
||||
2018-11-01 17:31:53,045,1,WOOHO
|
||||
2018-11-01 17:31:54,050,1,WOOHO
|
||||
2018-11-01 17:31:55,054,1,WOOHO
|
||||
2018-11-01 17:31:56,057,1,WOOHO
|
||||
2018-11-01 17:31:57,060,1,WOOHO
|
||||
2018-11-01 17:31:58,061,1,WOOHO
|
||||
2018-11-01 17:31:59,066,1,WOOHO
|
||||
2018-11-01 17:32:00,070,1,WOOHO
|
||||
2018-11-01 17:32:01,075,1,WOOHO
|
||||
2018-11-01 17:32:02,079,1,WOOHO
|
||||
2018-11-01 17:32:03,083,1,WOOHO
|
||||
2018-11-01 17:32:04,087,1,WOOHO
|
||||
2018-11-01 17:32:05,089,1,WOOHO
|
||||
2018-11-01 17:32:06,094,1,WOOHO
|
||||
2018-11-01 17:32:07,098,1,WOOHO
|
||||
2018-11-01 17:32:08,101,1,WOOHO
|
||||
2018-11-01 17:32:09,104,1,WOOHO
|
||||
2018-11-01 17:32:10,106,1,WOOHO
|
||||
2018-11-01 17:32:11,108,1,WOOHO
|
||||
2018-11-01 17:32:12,112,1,WOOHO
|
||||
2018-11-01 17:32:13,115,1,WOOHO
|
||||
2018-11-01 17:32:14,116,1,WOOHO
|
||||
2018-11-01 17:32:15,119,1,WOOHO
|
||||
2018-11-01 17:32:16,121,1,WOOHO
|
||||
2018-11-01 17:32:17,122,1,WOOHO
|
||||
2018-11-01 17:32:18,127,1,WOOHO
|
||||
2018-11-01 17:32:19,130,1,WOOHO
|
||||
2018-11-01 17:32:20,135,1,WOOHO
|
||||
2018-11-01 17:32:21,136,1,WOOHO
|
||||
2018-11-01 17:32:22,142,1,WOOHO
|
||||
2018-11-01 17:32:23,145,1,WOOHO
|
||||
2018-11-01 17:32:24,148,1,WOOHO
|
||||
2018-11-01 17:32:25,153,1,WOOHO
|
||||
2018-11-01 17:32:26,159,1,WOOHO
|
||||
2018-11-01 17:32:27,162,1,WOOHO
|
||||
2018-11-01 17:32:28,166,1,WOOHO
|
||||
2018-11-01 17:32:29,169,1,WOOHO
|
||||
2018-11-01 17:32:32,214,1,WOOHO
|
||||
2018-11-01 17:32:33,215,1,WOOHO
|
||||
2018-11-01 17:32:34,220,1,WOOHO
|
||||
2018-11-01 17:32:35,224,1,WOOHO
|
||||
2018-11-01 17:32:36,229,1,WOOHO
|
||||
2018-11-01 17:32:37,235,1,WOOHO
|
||||
2018-11-01 17:32:38,238,1,WOOHO
|
||||
2018-11-01 17:32:39,242,1,WOOHO
|
60
logs/first_logfile2.log.2018-11-01_21-20
Normal file
60
logs/first_logfile2.log.2018-11-01_21-20
Normal file
|
@ -0,0 +1,60 @@
|
|||
2018-11-01 21:20:19,492,1,WOOHO
|
||||
2018-11-01 21:20:20,498,1,WOOHO
|
||||
2018-11-01 21:20:21,501,1,WOOHO
|
||||
2018-11-01 21:20:22,505,1,WOOHO
|
||||
2018-11-01 21:20:23,507,1,WOOHO
|
||||
2018-11-01 21:20:24,511,1,WOOHO
|
||||
2018-11-01 21:20:25,512,1,WOOHO
|
||||
2018-11-01 21:20:26,514,1,WOOHO
|
||||
2018-11-01 21:20:27,516,1,WOOHO
|
||||
2018-11-01 21:20:28,521,1,WOOHO
|
||||
2018-11-01 21:20:29,526,1,WOOHO
|
||||
2018-11-01 21:20:30,530,1,WOOHO
|
||||
2018-11-01 21:20:31,533,1,WOOHO
|
||||
2018-11-01 21:20:32,534,1,WOOHO
|
||||
2018-11-01 21:20:33,539,1,WOOHO
|
||||
2018-11-01 21:20:34,542,1,WOOHO
|
||||
2018-11-01 21:20:35,547,1,WOOHO
|
||||
2018-11-01 21:20:36,548,1,WOOHO
|
||||
2018-11-01 21:20:37,553,1,WOOHO
|
||||
2018-11-01 21:20:38,556,1,WOOHO
|
||||
2018-11-01 21:20:39,563,1,WOOHO
|
||||
2018-11-01 21:20:40,568,1,WOOHO
|
||||
2018-11-01 21:20:41,572,1,WOOHO
|
||||
2018-11-01 21:20:42,574,1,WOOHO
|
||||
2018-11-01 21:20:43,576,1,WOOHO
|
||||
2018-11-01 21:20:44,581,1,WOOHO
|
||||
2018-11-01 21:20:45,585,1,WOOHO
|
||||
2018-11-01 21:20:46,588,1,WOOHO
|
||||
2018-11-01 21:20:47,593,1,WOOHO
|
||||
2018-11-01 21:20:48,599,1,WOOHO
|
||||
2018-11-01 21:20:49,602,1,WOOHO
|
||||
2018-11-01 21:20:50,603,1,WOOHO
|
||||
2018-11-01 21:20:51,604,1,WOOHO
|
||||
2018-11-01 21:20:52,608,1,WOOHO
|
||||
2018-11-01 21:20:53,612,1,WOOHO
|
||||
2018-11-01 21:20:54,616,1,WOOHO
|
||||
2018-11-01 21:20:55,621,1,WOOHO
|
||||
2018-11-01 21:20:56,625,1,WOOHO
|
||||
2018-11-01 21:20:57,626,1,WOOHO
|
||||
2018-11-01 21:20:58,631,1,WOOHO
|
||||
2018-11-01 21:20:59,635,1,WOOHO
|
||||
2018-11-01 21:21:00,637,1,WOOHO
|
||||
2018-11-01 21:21:01,639,1,WOOHO
|
||||
2018-11-01 21:21:02,643,1,WOOHO
|
||||
2018-11-01 21:21:03,648,1,WOOHO
|
||||
2018-11-01 21:21:04,653,1,WOOHO
|
||||
2018-11-01 21:21:05,657,1,WOOHO
|
||||
2018-11-01 21:21:06,662,1,WOOHO
|
||||
2018-11-01 21:21:07,666,1,WOOHO
|
||||
2018-11-01 21:21:08,671,1,WOOHO
|
||||
2018-11-01 21:21:09,676,1,WOOHO
|
||||
2018-11-01 21:21:10,682,1,WOOHO
|
||||
2018-11-01 21:21:11,684,1,WOOHO
|
||||
2018-11-01 21:21:12,685,1,WOOHO
|
||||
2018-11-01 21:21:13,690,1,WOOHO
|
||||
2018-11-01 21:21:14,695,1,WOOHO
|
||||
2018-11-01 21:21:15,700,1,WOOHO
|
||||
2018-11-01 21:21:16,702,1,WOOHO
|
||||
2018-11-01 21:21:17,707,1,WOOHO
|
||||
2018-11-01 21:21:18,712,1,WOOHO
|
60
logs/first_logfile2.log.2018-11-01_21-21
Normal file
60
logs/first_logfile2.log.2018-11-01_21-21
Normal file
|
@ -0,0 +1,60 @@
|
|||
2018-11-01 21:21:19,716,1,WOOHO
|
||||
2018-11-01 21:21:20,721,1,WOOHO
|
||||
2018-11-01 21:21:21,726,1,WOOHO
|
||||
2018-11-01 21:21:22,731,1,WOOHO
|
||||
2018-11-01 21:21:23,735,1,WOOHO
|
||||
2018-11-01 21:21:24,740,1,WOOHO
|
||||
2018-11-01 21:21:25,744,1,WOOHO
|
||||
2018-11-01 21:21:26,749,1,WOOHO
|
||||
2018-11-01 21:21:27,752,1,WOOHO
|
||||
2018-11-01 21:21:28,757,1,WOOHO
|
||||
2018-11-01 21:21:29,760,1,WOOHO
|
||||
2018-11-01 21:21:30,763,1,WOOHO
|
||||
2018-11-01 21:21:31,768,1,WOOHO
|
||||
2018-11-01 21:21:32,769,1,WOOHO
|
||||
2018-11-01 21:21:33,771,1,WOOHO
|
||||
2018-11-01 21:21:34,777,1,WOOHO
|
||||
2018-11-01 21:21:35,779,1,WOOHO
|
||||
2018-11-01 21:21:36,783,1,WOOHO
|
||||
2018-11-01 21:21:37,786,1,WOOHO
|
||||
2018-11-01 21:21:38,790,1,WOOHO
|
||||
2018-11-01 21:21:39,794,1,WOOHO
|
||||
2018-11-01 21:21:40,799,1,WOOHO
|
||||
2018-11-01 21:21:41,803,1,WOOHO
|
||||
2018-11-01 21:21:42,808,1,WOOHO
|
||||
2018-11-01 21:21:43,809,1,WOOHO
|
||||
2018-11-01 21:21:44,812,1,WOOHO
|
||||
2018-11-01 21:21:45,814,1,WOOHO
|
||||
2018-11-01 21:21:46,818,1,WOOHO
|
||||
2018-11-01 21:21:47,822,1,WOOHO
|
||||
2018-11-01 21:21:48,825,1,WOOHO
|
||||
2018-11-01 21:21:49,831,1,WOOHO
|
||||
2018-11-01 21:21:50,836,1,WOOHO
|
||||
2018-11-01 21:21:51,838,1,WOOHO
|
||||
2018-11-01 21:21:52,843,1,WOOHO
|
||||
2018-11-01 21:21:53,847,1,WOOHO
|
||||
2018-11-01 21:21:54,851,1,WOOHO
|
||||
2018-11-01 21:21:55,855,1,WOOHO
|
||||
2018-11-01 21:21:56,861,1,WOOHO
|
||||
2018-11-01 21:21:57,864,1,WOOHO
|
||||
2018-11-01 21:21:58,867,1,WOOHO
|
||||
2018-11-01 21:21:59,871,1,WOOHO
|
||||
2018-11-01 21:22:00,876,1,WOOHO
|
||||
2018-11-01 21:22:01,881,1,WOOHO
|
||||
2018-11-01 21:22:02,887,1,WOOHO
|
||||
2018-11-01 21:22:03,891,1,WOOHO
|
||||
2018-11-01 21:22:04,895,1,WOOHO
|
||||
2018-11-01 21:22:05,899,1,WOOHO
|
||||
2018-11-01 21:22:06,900,1,WOOHO
|
||||
2018-11-01 21:22:07,904,1,WOOHO
|
||||
2018-11-01 21:22:08,909,1,WOOHO
|
||||
2018-11-01 21:22:09,915,1,WOOHO
|
||||
2018-11-01 21:22:10,916,1,WOOHO
|
||||
2018-11-01 21:22:11,922,1,WOOHO
|
||||
2018-11-01 21:22:12,924,1,WOOHO
|
||||
2018-11-01 21:22:13,927,1,WOOHO
|
||||
2018-11-01 21:22:14,930,1,WOOHO
|
||||
2018-11-01 21:22:15,934,1,WOOHO
|
||||
2018-11-01 21:22:16,936,1,WOOHO
|
||||
2018-11-01 21:22:17,940,1,WOOHO
|
||||
2018-11-01 21:22:18,943,1,WOOHO
|
59
logs/first_logfile2.log.2018-11-01_21-22
Normal file
59
logs/first_logfile2.log.2018-11-01_21-22
Normal file
|
@ -0,0 +1,59 @@
|
|||
2018-11-01 21:22:19,948,1,WOOHO
|
||||
2018-11-01 21:22:20,954,1,WOOHO
|
||||
2018-11-01 21:22:21,960,1,WOOHO
|
||||
2018-11-01 21:22:22,964,1,WOOHO
|
||||
2018-11-01 21:22:23,967,1,WOOHO
|
||||
2018-11-01 21:22:24,971,1,WOOHO
|
||||
2018-11-01 21:22:25,977,1,WOOHO
|
||||
2018-11-01 21:22:26,981,1,WOOHO
|
||||
2018-11-01 21:22:27,986,1,WOOHO
|
||||
2018-11-01 21:22:28,990,1,WOOHO
|
||||
2018-11-01 21:22:29,995,1,WOOHO
|
||||
2018-11-01 21:22:31,000,1,WOOHO
|
||||
2018-11-01 21:22:32,004,1,WOOHO
|
||||
2018-11-01 21:22:33,010,1,WOOHO
|
||||
2018-11-01 21:22:34,014,1,WOOHO
|
||||
2018-11-01 21:22:35,020,1,WOOHO
|
||||
2018-11-01 21:22:36,024,1,WOOHO
|
||||
2018-11-01 21:22:37,028,1,WOOHO
|
||||
2018-11-01 21:22:38,033,1,WOOHO
|
||||
2018-11-01 21:22:39,036,1,WOOHO
|
||||
2018-11-01 21:22:40,041,1,WOOHO
|
||||
2018-11-01 21:22:41,045,1,WOOHO
|
||||
2018-11-01 21:22:42,049,1,WOOHO
|
||||
2018-11-01 21:22:43,053,1,WOOHO
|
||||
2018-11-01 21:22:44,057,1,WOOHO
|
||||
2018-11-01 21:22:45,061,1,WOOHO
|
||||
2018-11-01 21:22:46,065,1,WOOHO
|
||||
2018-11-01 21:22:47,069,1,WOOHO
|
||||
2018-11-01 21:22:48,074,1,WOOHO
|
||||
2018-11-01 21:22:49,078,1,WOOHO
|
||||
2018-11-01 21:22:50,082,1,WOOHO
|
||||
2018-11-01 21:22:51,086,1,WOOHO
|
||||
2018-11-01 21:22:52,090,1,WOOHO
|
||||
2018-11-01 21:22:53,092,1,WOOHO
|
||||
2018-11-01 21:22:54,097,1,WOOHO
|
||||
2018-11-01 21:22:55,100,1,WOOHO
|
||||
2018-11-01 21:22:56,102,1,WOOHO
|
||||
2018-11-01 21:22:57,105,1,WOOHO
|
||||
2018-11-01 21:22:58,109,1,WOOHO
|
||||
2018-11-01 21:22:59,115,1,WOOHO
|
||||
2018-11-01 21:23:00,120,1,WOOHO
|
||||
2018-11-01 21:23:01,121,1,WOOHO
|
||||
2018-11-01 21:23:02,125,1,WOOHO
|
||||
2018-11-01 21:23:03,126,1,WOOHO
|
||||
2018-11-01 21:23:04,131,1,WOOHO
|
||||
2018-11-01 21:23:05,136,1,WOOHO
|
||||
2018-11-01 21:23:06,141,1,WOOHO
|
||||
2018-11-01 21:23:07,146,1,WOOHO
|
||||
2018-11-01 21:23:08,151,1,WOOHO
|
||||
2018-11-01 21:23:09,157,1,WOOHO
|
||||
2018-11-01 21:23:10,164,1,WOOHO
|
||||
2018-11-01 21:23:11,167,1,WOOHO
|
||||
2018-11-01 21:23:12,170,1,WOOHO
|
||||
2018-11-01 21:23:13,175,1,WOOHO
|
||||
2018-11-01 21:23:14,180,1,WOOHO
|
||||
2018-11-01 21:23:15,184,1,WOOHO
|
||||
2018-11-01 21:23:16,188,1,WOOHO
|
||||
2018-11-01 21:23:17,194,1,WOOHO
|
||||
2018-11-01 21:23:18,198,1,WOOHO
|
60
logs/first_logfile2.log.2018-11-01_21-23
Normal file
60
logs/first_logfile2.log.2018-11-01_21-23
Normal file
|
@ -0,0 +1,60 @@
|
|||
2018-11-01 21:23:19,204,1,WOOHO
|
||||
2018-11-01 21:23:20,209,1,WOOHO
|
||||
2018-11-01 21:23:21,210,1,WOOHO
|
||||
2018-11-01 21:23:22,213,1,WOOHO
|
||||
2018-11-01 21:23:23,214,1,WOOHO
|
||||
2018-11-01 21:23:24,218,1,WOOHO
|
||||
2018-11-01 21:23:25,222,1,WOOHO
|
||||
2018-11-01 21:23:26,226,1,WOOHO
|
||||
2018-11-01 21:23:27,226,1,WOOHO
|
||||
2018-11-01 21:23:28,230,1,WOOHO
|
||||
2018-11-01 21:23:29,235,1,WOOHO
|
||||
2018-11-01 21:23:30,240,1,WOOHO
|
||||
2018-11-01 21:23:31,244,1,WOOHO
|
||||
2018-11-01 21:23:32,250,1,WOOHO
|
||||
2018-11-01 21:23:33,251,1,WOOHO
|
||||
2018-11-01 21:23:34,256,1,WOOHO
|
||||
2018-11-01 21:23:35,260,1,WOOHO
|
||||
2018-11-01 21:23:36,264,1,WOOHO
|
||||
2018-11-01 21:23:37,270,1,WOOHO
|
||||
2018-11-01 21:23:38,272,1,WOOHO
|
||||
2018-11-01 21:23:39,276,1,WOOHO
|
||||
2018-11-01 21:23:40,283,1,WOOHO
|
||||
2018-11-01 21:23:41,284,1,WOOHO
|
||||
2018-11-01 21:23:42,289,1,WOOHO
|
||||
2018-11-01 21:23:43,292,1,WOOHO
|
||||
2018-11-01 21:23:44,298,1,WOOHO
|
||||
2018-11-01 21:23:45,301,1,WOOHO
|
||||
2018-11-01 21:23:46,306,1,WOOHO
|
||||
2018-11-01 21:23:47,309,1,WOOHO
|
||||
2018-11-01 21:23:48,314,1,WOOHO
|
||||
2018-11-01 21:23:49,316,1,WOOHO
|
||||
2018-11-01 21:23:50,321,1,WOOHO
|
||||
2018-11-01 21:23:51,324,1,WOOHO
|
||||
2018-11-01 21:23:52,327,1,WOOHO
|
||||
2018-11-01 21:23:53,331,1,WOOHO
|
||||
2018-11-01 21:23:54,333,1,WOOHO
|
||||
2018-11-01 21:23:55,338,1,WOOHO
|
||||
2018-11-01 21:23:56,341,1,WOOHO
|
||||
2018-11-01 21:23:57,344,1,WOOHO
|
||||
2018-11-01 21:23:58,349,1,WOOHO
|
||||
2018-11-01 21:23:59,353,1,WOOHO
|
||||
2018-11-01 21:24:00,357,1,WOOHO
|
||||
2018-11-01 21:24:01,362,1,WOOHO
|
||||
2018-11-01 21:24:02,366,1,WOOHO
|
||||
2018-11-01 21:24:03,371,1,WOOHO
|
||||
2018-11-01 21:24:04,376,1,WOOHO
|
||||
2018-11-01 21:24:05,381,1,WOOHO
|
||||
2018-11-01 21:24:06,382,1,WOOHO
|
||||
2018-11-01 21:24:07,384,1,WOOHO
|
||||
2018-11-01 21:24:08,388,1,WOOHO
|
||||
2018-11-01 21:24:09,391,1,WOOHO
|
||||
2018-11-01 21:24:10,393,1,WOOHO
|
||||
2018-11-01 21:24:11,398,1,WOOHO
|
||||
2018-11-01 21:24:12,401,1,WOOHO
|
||||
2018-11-01 21:24:13,405,1,WOOHO
|
||||
2018-11-01 21:24:14,409,1,WOOHO
|
||||
2018-11-01 21:24:15,413,1,WOOHO
|
||||
2018-11-01 21:24:16,417,1,WOOHO
|
||||
2018-11-01 21:24:17,421,1,WOOHO
|
||||
2018-11-01 21:24:18,422,1,WOOHO
|
60
logs/first_logfile2.log.2018-11-01_21-24
Normal file
60
logs/first_logfile2.log.2018-11-01_21-24
Normal file
|
@ -0,0 +1,60 @@
|
|||
2018-11-01 21:24:19,426,1,WOOHO
|
||||
2018-11-01 21:24:20,431,1,WOOHO
|
||||
2018-11-01 21:24:21,436,1,WOOHO
|
||||
2018-11-01 21:24:22,442,1,WOOHO
|
||||
2018-11-01 21:24:23,445,1,WOOHO
|
||||
2018-11-01 21:24:24,450,1,WOOHO
|
||||
2018-11-01 21:24:25,453,1,WOOHO
|
||||
2018-11-01 21:24:26,457,1,WOOHO
|
||||
2018-11-01 21:24:27,462,1,WOOHO
|
||||
2018-11-01 21:24:28,466,1,WOOHO
|
||||
2018-11-01 21:24:29,471,1,WOOHO
|
||||
2018-11-01 21:24:30,475,1,WOOHO
|
||||
2018-11-01 21:24:31,481,1,WOOHO
|
||||
2018-11-01 21:24:32,484,1,WOOHO
|
||||
2018-11-01 21:24:33,487,1,WOOHO
|
||||
2018-11-01 21:24:34,491,1,WOOHO
|
||||
2018-11-01 21:24:35,495,1,WOOHO
|
||||
2018-11-01 21:24:36,499,1,WOOHO
|
||||
2018-11-01 21:24:37,503,1,WOOHO
|
||||
2018-11-01 21:24:38,506,1,WOOHO
|
||||
2018-11-01 21:24:39,510,1,WOOHO
|
||||
2018-11-01 21:24:40,515,1,WOOHO
|
||||
2018-11-01 21:24:41,519,1,WOOHO
|
||||
2018-11-01 21:24:42,522,1,WOOHO
|
||||
2018-11-01 21:24:43,527,1,WOOHO
|
||||
2018-11-01 21:24:44,532,1,WOOHO
|
||||
2018-11-01 21:24:45,537,1,WOOHO
|
||||
2018-11-01 21:24:46,542,1,WOOHO
|
||||
2018-11-01 21:24:47,548,1,WOOHO
|
||||
2018-11-01 21:24:48,554,1,WOOHO
|
||||
2018-11-01 21:24:49,558,1,WOOHO
|
||||
2018-11-01 21:24:50,563,1,WOOHO
|
||||
2018-11-01 21:24:51,567,1,WOOHO
|
||||
2018-11-01 21:24:52,573,1,WOOHO
|
||||
2018-11-01 21:24:53,575,1,WOOHO
|
||||
2018-11-01 21:24:54,578,1,WOOHO
|
||||
2018-11-01 21:24:55,582,1,WOOHO
|
||||
2018-11-01 21:24:56,583,1,WOOHO
|
||||
2018-11-01 21:24:57,586,1,WOOHO
|
||||
2018-11-01 21:24:58,589,1,WOOHO
|
||||
2018-11-01 21:24:59,593,1,WOOHO
|
||||
2018-11-01 21:25:00,597,1,WOOHO
|
||||
2018-11-01 21:25:01,598,1,WOOHO
|
||||
2018-11-01 21:25:02,600,1,WOOHO
|
||||
2018-11-01 21:25:03,606,1,WOOHO
|
||||
2018-11-01 21:25:04,612,1,WOOHO
|
||||
2018-11-01 21:25:05,614,1,WOOHO
|
||||
2018-11-01 21:25:06,616,1,WOOHO
|
||||
2018-11-01 21:25:07,620,1,WOOHO
|
||||
2018-11-01 21:25:08,624,1,WOOHO
|
||||
2018-11-01 21:25:09,631,1,WOOHO
|
||||
2018-11-01 21:25:10,634,1,WOOHO
|
||||
2018-11-01 21:25:11,636,1,WOOHO
|
||||
2018-11-01 21:25:12,640,1,WOOHO
|
||||
2018-11-01 21:25:13,645,1,WOOHO
|
||||
2018-11-01 21:25:14,649,1,WOOHO
|
||||
2018-11-01 21:25:15,653,1,WOOHO
|
||||
2018-11-01 21:25:16,657,1,WOOHO
|
||||
2018-11-01 21:25:17,661,1,WOOHO
|
||||
2018-11-01 21:25:18,665,1,WOOHO
|
10
run.py
10
run.py
|
@ -1,12 +1,4 @@
|
|||
import importlib
|
||||
|
||||
from aiohttp import web
|
||||
from aiohttp_auth import auth
|
||||
from core.cbpi import CraftBeerPi
|
||||
from core.craftbeerpi import CraftBeerPi
|
||||
|
||||
cbpi = CraftBeerPi()
|
||||
|
||||
|
||||
|
||||
|
||||
cbpi.start()
|
|
@ -6,7 +6,7 @@ import json
|
|||
|
||||
from hbmqtt.broker import Broker
|
||||
|
||||
from core.cbpi import CraftBeerPi
|
||||
from core.craftbeerpi import CraftBeerPi
|
||||
from core.database.model import ActorModel
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue