persidict 0.7.3__tar.gz → 0.7.4__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.

Potentially problematic release.


This version of persidict might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: persidict
3
- Version: 0.7.3
3
+ Version: 0.7.4
4
4
  Summary: Simple persistent key-value store for Python. Values are stored as files on a disk or as S3 objects on AWS cloud.
5
5
  Home-page: https://github.com/vladlpavlov/persidict
6
6
  Author: Vlad (Volodymyr) Pavlov
@@ -214,6 +214,12 @@ class FileDirDict(PersiDict):
214
214
 
215
215
  def __setitem__(self, key:PersiDictKey, value:Any):
216
216
  """Set self[key] to value."""
217
+
218
+ if isinstance(value, PersiDict):
219
+ raise TypeError(
220
+ f"You are not allowed to store a PersiDict "
221
+ + f"inside another PersiDict.")
222
+
217
223
  if self.base_class_for_values is not None:
218
224
  if not isinstance(value, self.base_class_for_values):
219
225
  raise TypeError(
@@ -147,6 +147,11 @@ class S3Dict(PersiDict):
147
147
  def __setitem__(self, key:PersiDictKey, value:Any):
148
148
  """Set self[key] to value. """
149
149
 
150
+ if isinstance(value, PersiDict):
151
+ raise TypeError(
152
+ f"You are not allowed to store a PersiDict "
153
+ + f"inside another PersiDict.")
154
+
150
155
  if self.base_class_for_values is not None:
151
156
  if not isinstance(value, self.base_class_for_values):
152
157
  raise TypeError(
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: persidict
3
- Version: 0.7.3
3
+ Version: 0.7.4
4
4
  Summary: Simple persistent key-value store for Python. Values are stored as files on a disk or as S3 objects on AWS cloud.
5
5
  Home-page: https://github.com/vladlpavlov/persidict
6
6
  Author: Vlad (Volodymyr) Pavlov
@@ -5,7 +5,7 @@ with open("README.md", "r") as f:
5
5
 
6
6
  setuptools.setup(
7
7
  name="persidict"
8
- ,version="0.7.3"
8
+ ,version="0.7.4"
9
9
  ,author="Vlad (Volodymyr) Pavlov"
10
10
  ,author_email="vlpavlov@ieee.org"
11
11
  ,description= "Simple persistent key-value store for Python. "
File without changes
File without changes
File without changes