hivemind-sqlite-database 0.0.1__tar.gz → 0.0.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {hivemind-sqlite-database-0.0.1 → hivemind-sqlite-database-0.0.3}/PKG-INFO +1 -1
- {hivemind-sqlite-database-0.0.1 → hivemind-sqlite-database-0.0.3}/hivemind_sqlite_database/__init__.py +7 -2
- {hivemind-sqlite-database-0.0.1 → hivemind-sqlite-database-0.0.3}/hivemind_sqlite_database/version.py +1 -1
- {hivemind-sqlite-database-0.0.1 → hivemind-sqlite-database-0.0.3}/hivemind_sqlite_database.egg-info/PKG-INFO +1 -1
- {hivemind-sqlite-database-0.0.1 → hivemind-sqlite-database-0.0.3}/hivemind_sqlite_database.egg-info/SOURCES.txt +2 -0
- hivemind-sqlite-database-0.0.3/hivemind_sqlite_database.egg-info/entry_points.txt +3 -0
- hivemind-sqlite-database-0.0.3/hivemind_sqlite_database.egg-info/requires.txt +1 -0
- {hivemind-sqlite-database-0.0.1 → hivemind-sqlite-database-0.0.3}/setup.py +3 -1
- {hivemind-sqlite-database-0.0.1 → hivemind-sqlite-database-0.0.3}/LICENSE.md +0 -0
- {hivemind-sqlite-database-0.0.1 → hivemind-sqlite-database-0.0.3}/README.md +0 -0
- {hivemind-sqlite-database-0.0.1 → hivemind-sqlite-database-0.0.3}/hivemind_sqlite_database.egg-info/dependency_links.txt +0 -0
- {hivemind-sqlite-database-0.0.1 → hivemind-sqlite-database-0.0.3}/hivemind_sqlite_database.egg-info/top_level.txt +0 -0
- {hivemind-sqlite-database-0.0.1 → hivemind-sqlite-database-0.0.3}/setup.cfg +0 -0
|
@@ -8,15 +8,20 @@ from ovos_utils.xdg_utils import xdg_data_home
|
|
|
8
8
|
|
|
9
9
|
from hivemind_plugin_manager.database import Client, AbstractDB
|
|
10
10
|
|
|
11
|
+
from dataclasses import dataclass
|
|
11
12
|
|
|
13
|
+
|
|
14
|
+
@dataclass
|
|
12
15
|
class SQLiteDB(AbstractDB):
|
|
13
16
|
"""Database implementation using SQLite."""
|
|
17
|
+
name: str = "clients"
|
|
18
|
+
subfolder: str = "hivemind-core"
|
|
14
19
|
|
|
15
|
-
def
|
|
20
|
+
def __post_init__(self):
|
|
16
21
|
"""
|
|
17
22
|
Initialize the SQLiteDB connection.
|
|
18
23
|
"""
|
|
19
|
-
db_path = os.path.join(xdg_data_home(), subfolder, name + ".db")
|
|
24
|
+
db_path = os.path.join(xdg_data_home(), self.subfolder, self.name + ".db")
|
|
20
25
|
LOG.debug(f"sqlite database path: {db_path}")
|
|
21
26
|
os.makedirs(os.path.dirname(db_path), exist_ok=True)
|
|
22
27
|
|
|
@@ -6,4 +6,6 @@ hivemind_sqlite_database/version.py
|
|
|
6
6
|
hivemind_sqlite_database.egg-info/PKG-INFO
|
|
7
7
|
hivemind_sqlite_database.egg-info/SOURCES.txt
|
|
8
8
|
hivemind_sqlite_database.egg-info/dependency_links.txt
|
|
9
|
+
hivemind_sqlite_database.egg-info/entry_points.txt
|
|
10
|
+
hivemind_sqlite_database.egg-info/requires.txt
|
|
9
11
|
hivemind_sqlite_database.egg-info/top_level.txt
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
hivemind-plugin-manager<1.0.0,>=0.1.0
|
|
@@ -39,6 +39,7 @@ def required(requirements_file):
|
|
|
39
39
|
if pkg.strip() and not pkg.startswith("#")]
|
|
40
40
|
|
|
41
41
|
|
|
42
|
+
PLUGIN_ENTRY_POINT = 'hivemind-sqlite-db-plugin=hivemind_sqlite_database:SQLiteDB'
|
|
42
43
|
|
|
43
44
|
setup(
|
|
44
45
|
name='hivemind-sqlite-database',
|
|
@@ -47,7 +48,8 @@ setup(
|
|
|
47
48
|
url='https://github.com/JarbasHiveMind/hivemind-sqlite-database',
|
|
48
49
|
license='Apache-2.0',
|
|
49
50
|
author='jarbasAi',
|
|
50
|
-
|
|
51
|
+
install_requires=required("requirements.txt"),
|
|
52
|
+
entry_points={'hivemind.database': PLUGIN_ENTRY_POINT},
|
|
51
53
|
author_email='jarbasai@mailfence.com',
|
|
52
54
|
description='sqlite database plugin for hivemind-core'
|
|
53
55
|
)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|