plain.admin 0.31.7__py3-none-any.whl → 0.31.8__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.
@@ -3,7 +3,7 @@ import logging
3
3
  import re
4
4
 
5
5
  from plain.json import PlainJSONEncoder
6
- from plain.models import connection
6
+ from plain.models import DEFAULT_DB_ALIAS, connections
7
7
  from plain.runtime import settings
8
8
 
9
9
  from .core import QueryStats
@@ -60,11 +60,11 @@ class QueryStatsMiddleware:
60
60
 
61
61
  querystats = QueryStats(include_tracebacks=is_tracking())
62
62
 
63
- with connection.execute_wrapper(querystats):
63
+ with connections[DEFAULT_DB_ALIAS].execute_wrapper(querystats):
64
64
  is_admin = self.is_admin_request(request)
65
65
 
66
66
  if settings.DEBUG or is_admin:
67
- with connection.execute_wrapper(querystats):
67
+ with connections[DEFAULT_DB_ALIAS].execute_wrapper(querystats):
68
68
  response = self.get_response(request)
69
69
 
70
70
  if settings.DEBUG:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: plain.admin
3
- Version: 0.31.7
3
+ Version: 0.31.8
4
4
  Summary: Admin dashboard and tools for Plain.
5
5
  Author-email: Dave Gaeddert <dave.gaeddert@dropseed.dev>
6
6
  License-Expression: BSD-3-Clause
@@ -30,7 +30,7 @@ plain/admin/impersonate/views.py,sha256=PzVmzhlS0LmbHgxdLhc2G27ltvk3zgmO-3QWNAcD
30
30
  plain/admin/querystats/README.md,sha256=ONscu4dQOVe20CPHFyI8vR8iL2kvo3cOM8iwVO-lDyM,4821
31
31
  plain/admin/querystats/__init__.py,sha256=VmP1aQ5Pviq4Z3izCB8G9g0Weq-2SYR88UFNtwqAPpo,81
32
32
  plain/admin/querystats/core.py,sha256=myHdmpUoJyvVHZ4knuJrrtF2TcTdHjqhLXq2Whyi4Qs,4456
33
- plain/admin/querystats/middleware.py,sha256=isMjV5X-8SP-8IQEaJMfXWarZQaQBQsI5uXV0JHKXnY,3347
33
+ plain/admin/querystats/middleware.py,sha256=jGPuQ7YXXys80Px4eBrqHgkBwMBgZr2X0HfFfwvYsOg,3404
34
34
  plain/admin/querystats/urls.py,sha256=H8wMpqKBnXqA8ZsdwdxTKQguNYJ0JsMRqqMunccBm2I,198
35
35
  plain/admin/querystats/views.py,sha256=cXmHZtEgRwXNN5d9HsKBe5G_VnDgSNwpwoRaEvuJ7vo,2375
36
36
  plain/admin/templates/admin/base.html,sha256=urUvdcgcZZWjevZSvkagXdcrUe5LYUeaWme7S2gckMU,8509
@@ -79,7 +79,7 @@ plain/admin/views/objects.py,sha256=eKL8A2B1ZMgTrCbTXnh6vCeju_HObxwetn_xc1vYlfY,
79
79
  plain/admin/views/registry.py,sha256=Lxib4YSQCMHb_zACnLKymJakV8jCZPWYll7J8-aV9Xw,3712
80
80
  plain/admin/views/types.py,sha256=ONMMdUoapgMoUVYgSIe-4YCdfvaVMQ4jgPWYiMo0pDk,178
81
81
  plain/admin/views/viewsets.py,sha256=dqMlQ6kLn9iqd9BwBWAZT1S271wH1FdfM5HXbOgBMEw,1655
82
- plain_admin-0.31.7.dist-info/METADATA,sha256=FJMWF2MswYBCn3WpEDp4SAOXZ3uFL6DyhYe2UKiEKvw,5051
83
- plain_admin-0.31.7.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
84
- plain_admin-0.31.7.dist-info/licenses/LICENSE,sha256=cvKM3OlqHx3ijD6e34zsSUkPvzl-ya3Dd63A6EHL94U,1500
85
- plain_admin-0.31.7.dist-info/RECORD,,
82
+ plain_admin-0.31.8.dist-info/METADATA,sha256=uibT4F7MeLcXAk8gOhX78TayBHv5YI2RavTJzt0LK40,5051
83
+ plain_admin-0.31.8.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
84
+ plain_admin-0.31.8.dist-info/licenses/LICENSE,sha256=cvKM3OlqHx3ijD6e34zsSUkPvzl-ya3Dd63A6EHL94U,1500
85
+ plain_admin-0.31.8.dist-info/RECORD,,