plain.models 0.34.2__py3-none-any.whl → 0.34.3__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.
plain/models/CHANGELOG.md CHANGED
@@ -1,5 +1,15 @@
1
1
  # plain-models changelog
2
2
 
3
+ ## [0.34.3](https://github.com/dropseed/plain/releases/plain-models@0.34.3) (2025-06-29)
4
+
5
+ ### What's changed
6
+
7
+ - Simplified log output when creating or destroying test databases during test setup. The messages now display the test database name directly and no longer reference the deprecated "alias" terminology ([a543706](https://github.com/dropseed/plain/commit/a543706)).
8
+
9
+ ### Upgrade instructions
10
+
11
+ - No changes required
12
+
3
13
  ## [0.34.2](https://github.com/dropseed/plain/releases/plain-models@0.34.2) (2025-06-27)
4
14
 
5
15
  ### What's changed
@@ -36,9 +36,7 @@ class BaseDatabaseCreation:
36
36
  test_database_name = self._get_test_db_name(prefix)
37
37
 
38
38
  if verbosity >= 1:
39
- self.log(
40
- f"Creating test database for alias {self._get_database_display_str(verbosity, test_database_name)}..."
41
- )
39
+ self.log(f"Creating test database '{test_database_name}'...")
42
40
 
43
41
  self._create_test_db(
44
42
  test_database_name=test_database_name, verbosity=verbosity, autoclobber=True
@@ -127,15 +125,6 @@ class BaseDatabaseCreation:
127
125
  # # because constraint checks were disabled.
128
126
  # self.connection.check_constraints(table_names=table_names)
129
127
 
130
- def _get_database_display_str(self, verbosity, database_name):
131
- """
132
- Return display string for a database for use in various actions.
133
- """
134
- return "'{}'{}".format(
135
- self.connection.alias,
136
- (f" ('{database_name}')") if verbosity >= 2 else "",
137
- )
138
-
139
128
  def _get_test_db_name(self, prefix=""):
140
129
  """
141
130
  Internal implementation - return the name of the test DB that will be
@@ -182,11 +171,7 @@ class BaseDatabaseCreation:
182
171
  try:
183
172
  if verbosity >= 1:
184
173
  self.log(
185
- "Destroying old test database for alias {}...".format(
186
- self._get_database_display_str(
187
- verbosity, test_database_name
188
- ),
189
- )
174
+ f"Destroying old test database '{test_database_name}'..."
190
175
  )
191
176
  cursor.execute(
192
177
  "DROP DATABASE {dbname}".format(**test_db_params)
@@ -211,9 +196,7 @@ class BaseDatabaseCreation:
211
196
  test_database_name = self.connection.settings_dict["NAME"]
212
197
 
213
198
  if verbosity >= 1:
214
- self.log(
215
- f"Destroying test database for alias {self._get_database_display_str(verbosity, test_database_name)}..."
216
- )
199
+ self.log(f"Destroying test database '{test_database_name}'...")
217
200
  self._destroy_test_db(test_database_name, verbosity)
218
201
 
219
202
  # Restore the original database name
@@ -32,9 +32,7 @@ class DatabaseCreation(BaseDatabaseCreation):
32
32
  if not self.is_in_memory_db(test_database_name):
33
33
  # Erase the old test database file.
34
34
  if verbosity >= 1:
35
- self.log(
36
- f"Destroying old test database for alias {self._get_database_display_str(verbosity, test_database_name)}..."
37
- )
35
+ self.log(f"Destroying old test database '{test_database_name}'...")
38
36
  if os.access(test_database_name, os.F_OK):
39
37
  if not autoclobber:
40
38
  confirm = input(
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: plain.models
3
- Version: 0.34.2
3
+ Version: 0.34.3
4
4
  Summary: Database models for Plain.
5
5
  Author-email: Dave Gaeddert <dave.gaeddert@dropseed.dev>
6
6
  License-File: LICENSE
@@ -1,4 +1,4 @@
1
- plain/models/CHANGELOG.md,sha256=r04vS3MHdGDOKyt4OTk9EUw0BFysg9Ci8_hd6KbeDD4,2196
1
+ plain/models/CHANGELOG.md,sha256=pqRLcrM3g7kol5Zkxrxjd9xjtgTL3bGlFUnNJ4ersTU,2621
2
2
  plain/models/README.md,sha256=vsZPev3Fna-Irdcs3-wrOcAoII5LOhXdcWLBMT87CS0,1626
3
3
  plain/models/__init__.py,sha256=dnU6MOXs3lGoK31nLWjCqbf7zigkaUccomchz9lNDJ8,2950
4
4
  plain/models/aggregates.py,sha256=P0mhsMl1VZt2CVHMuCHnNI8SxZ9citjDLEgioN6NOpo,7240
@@ -33,7 +33,7 @@ plain/models/backends/utils.py,sha256=QFmpqe1FATF7KcLc00OhZbQzM_L9dPvtqptXe4hU4F
33
33
  plain/models/backends/base/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
34
34
  plain/models/backends/base/base.py,sha256=I5040pUAe7-yNTb9wfMNOYjeiFQLZ5dcRI4rtmVKJ04,26457
35
35
  plain/models/backends/base/client.py,sha256=90Ffs6zZYCli3tJjwsPH8TItZ8tz1Pp-zhQa-EpsNqc,937
36
- plain/models/backends/base/creation.py,sha256=idyE4g7uhqPWmTf9oMlovpoIqQaZFv5fvQ-DGnqKAYM,10029
36
+ plain/models/backends/base/creation.py,sha256=T8JaQ67KOtp6YIPksrmOa8BF9oTaTPXgKB5ct6bxh9E,9352
37
37
  plain/models/backends/base/features.py,sha256=nHUkFjKSx_w9QwD4l-jXP_zotvspy9o6ayn-AHzzrHI,7959
38
38
  plain/models/backends/base/introspection.py,sha256=8icKf9h8y4kobmyrbo8JWTDcpQIAt4oS_4FtCnY7FqQ,6815
39
39
  plain/models/backends/base/operations.py,sha256=Y08cS7IZwYXMKVUoEpBCjyOTh1PW2OShoRU9TZdipss,25740
@@ -61,7 +61,7 @@ plain/models/backends/sqlite3/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5N
61
61
  plain/models/backends/sqlite3/_functions.py,sha256=XsohPZN-xFEEmC28stQzAiSMvE0nHJ1cMHfL2Ze72vI,14317
62
62
  plain/models/backends/sqlite3/base.py,sha256=h0nFOR89IqFRnBLgjKLPf9eutHOQPmpiatjt4ZjlU34,13265
63
63
  plain/models/backends/sqlite3/client.py,sha256=dvxY10LFJHKY6ykOuCE6e45Wo4fAH4IPDtNCH3Wvd34,324
64
- plain/models/backends/sqlite3/creation.py,sha256=zNAJRkr--ZKJv8QeJWEaYAh8pLPPBK-dclHgelAMn6M,2877
64
+ plain/models/backends/sqlite3/creation.py,sha256=dH4rqZj79TCMHmaBash4I_io15QCxnam92fuWrRK_R8,2788
65
65
  plain/models/backends/sqlite3/features.py,sha256=xbGiBom7Kh0xNTLZrFmTQ32C7M8q8UEmyi6hoBd25kE,2326
66
66
  plain/models/backends/sqlite3/introspection.py,sha256=RMzb8RUfNUvrcbcmgIKjxwp5D2uoth4-eJF-bduBo2o,17286
67
67
  plain/models/backends/sqlite3/operations.py,sha256=K2PFCsvzGhBrPEzz1AXFenge2B4Ap8lsQAABsC4e_UI,15302
@@ -113,8 +113,8 @@ plain/models/sql/where.py,sha256=ezE9Clt2BmKo-I7ARsgqZ_aVA-1UdayCwr6ULSWZL6c,126
113
113
  plain/models/test/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
114
114
  plain/models/test/pytest.py,sha256=5mxY1MHqfCFJ7G39W1DuE0vCHfsfehQQmOyE6vI6caw,3323
115
115
  plain/models/test/utils.py,sha256=MxBNWoGMtwAtka7LbxWgilgzv7T5qqJL8ystF2SDJrs,345
116
- plain_models-0.34.2.dist-info/METADATA,sha256=wsRt3LgaqNF--XdOjUktCcbRG2BauaToDhki6TLukl4,1921
117
- plain_models-0.34.2.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
118
- plain_models-0.34.2.dist-info/entry_points.txt,sha256=IYJAW9MpL3PXyXFWmKmALagAGXC_5rzBn2eEGJlcV04,112
119
- plain_models-0.34.2.dist-info/licenses/LICENSE,sha256=m0D5O7QoH9l5Vz_rrX_9r-C8d9UNr_ciK6Qwac7o6yo,3175
120
- plain_models-0.34.2.dist-info/RECORD,,
116
+ plain_models-0.34.3.dist-info/METADATA,sha256=mb93D4h-Sx5BSsRwbeCB6IEBAflmr_hINCHIiS9VqXA,1921
117
+ plain_models-0.34.3.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
118
+ plain_models-0.34.3.dist-info/entry_points.txt,sha256=IYJAW9MpL3PXyXFWmKmALagAGXC_5rzBn2eEGJlcV04,112
119
+ plain_models-0.34.3.dist-info/licenses/LICENSE,sha256=m0D5O7QoH9l5Vz_rrX_9r-C8d9UNr_ciK6Qwac7o6yo,3175
120
+ plain_models-0.34.3.dist-info/RECORD,,