scruby 0.1.3__py3-none-any.whl → 0.3.0__py3-none-any.whl
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.
Potentially problematic release.
This version of scruby might be problematic. Click here for more details.
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: scruby
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.3.0
|
|
4
4
|
Summary: A fast key-value storage library.
|
|
5
5
|
Project-URL: Homepage, https://github.com/kebasyaty/scruby
|
|
6
6
|
Project-URL: Repository, https://github.com/kebasyaty/scruby
|
|
@@ -11,7 +11,7 @@ Author-email: kebasyaty <kebasyaty@gmail.com>
|
|
|
11
11
|
License-Expression: MIT
|
|
12
12
|
License-File: LICENSE
|
|
13
13
|
Keywords: database,db,scruby,store
|
|
14
|
-
Classifier: Development Status ::
|
|
14
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
15
15
|
Classifier: Intended Audience :: Developers
|
|
16
16
|
Classifier: License :: OSI Approved :: MIT License
|
|
17
17
|
Classifier: Operating System :: MacOS :: MacOS X
|
|
@@ -102,12 +102,27 @@ async def main() -> None:
|
|
|
102
102
|
|
|
103
103
|
db = Scruby()
|
|
104
104
|
await db.set_key("key name", "Some text")
|
|
105
|
+
# Update key
|
|
106
|
+
await db.set_key("key name", "Some new text")
|
|
107
|
+
|
|
108
|
+
user_details = {
|
|
109
|
+
"first name": "John",
|
|
110
|
+
"last name": "Smith",
|
|
111
|
+
"email": "John_Smith@gmail.com",
|
|
112
|
+
"phone": "+447986123456",
|
|
113
|
+
}
|
|
114
|
+
await db.set_key("+447986123456", user_details)
|
|
115
|
+
|
|
105
116
|
await db.get_key("key name") # => "Some text"
|
|
106
117
|
await db.get_key("key missing") # => KeyError
|
|
118
|
+
|
|
107
119
|
await db.has_key("key name") # => True
|
|
108
120
|
await db.has_key("key missing") # => False
|
|
121
|
+
|
|
109
122
|
await db.delete_key("key name")
|
|
123
|
+
await db.delete_key("key name") # => KeyError
|
|
110
124
|
await db.delete_key("key missing") # => KeyError
|
|
125
|
+
|
|
111
126
|
# Full database deletion.
|
|
112
127
|
await db.napalm()
|
|
113
128
|
await db.napalm() # => FileNotFoundError
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
scruby/__init__.py,sha256=TCxUjBI5A0KZcwvfmgaBVl8ScuzzOVvALl_T4iqSR9c,603
|
|
2
2
|
scruby/db.py,sha256=otENL-t7ie_8Fgzcteh2WsXFPu9pM4DBUdO_2GB1vwk,6565
|
|
3
3
|
scruby/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
4
|
-
scruby-0.
|
|
5
|
-
scruby-0.
|
|
6
|
-
scruby-0.
|
|
7
|
-
scruby-0.
|
|
4
|
+
scruby-0.3.0.dist-info/METADATA,sha256=Dkz32lF7SmIWBEdXNhuhHQkYunAas6A84cEaVu08bYM,6256
|
|
5
|
+
scruby-0.3.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
6
|
+
scruby-0.3.0.dist-info/licenses/LICENSE,sha256=2zZINd6m_jNYlowdQImlEizyhSui5cBAJZRhWQURcEc,1095
|
|
7
|
+
scruby-0.3.0.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|