plain 0.3.0__py3-none-any.whl → 0.3.1__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.
@@ -1,4 +1,3 @@
1
- from plain.assets.urls import get_asset_url
2
1
  from plain.paginator import Paginator
3
2
  from plain.utils import timezone
4
3
 
@@ -10,8 +9,16 @@ def url(viewname, *args, **kwargs):
10
9
  return reverse(viewname, args=args, kwargs=kwargs)
11
10
 
12
11
 
12
+ def asset(url_path):
13
+ # An explicit callable we can control, but also delay the import of asset.urls->views->templates
14
+ # for circular import reasons
15
+ from plain.assets.urls import get_asset_url
16
+
17
+ return get_asset_url(url_path)
18
+
19
+
13
20
  default_globals = {
14
- "asset": get_asset_url,
21
+ "asset": asset,
15
22
  "url": url,
16
23
  "Paginator": Paginator,
17
24
  "now": timezone.now,
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: plain
3
- Version: 0.3.0
3
+ Version: 0.3.1
4
4
  Summary: A web framework for building products with Python.
5
5
  Author: Dave Gaeddert
6
6
  Author-email: dave.gaeddert@dropseed.dev
@@ -98,7 +98,7 @@ plain/templates/jinja/__init__.py,sha256=1VAyXRHf2hDPniZfnKhiMWsOp4Gkg0Ss1xmAbuv
98
98
  plain/templates/jinja/defaults.py,sha256=AhGxp8X4UNC6CRD0XygQDV3ZeIs4KH2NaCjPtlgFeL0,3770
99
99
  plain/templates/jinja/extensions.py,sha256=AEmmmHDbdRW8fhjYDzq9eSSNbp9WHsXenD8tPthjc0s,1351
100
100
  plain/templates/jinja/filters.py,sha256=3KJKKbxcv9dLzUDWPcaa88k3NU2m1GG3iMIgFhzXrBA,860
101
- plain/templates/jinja/globals.py,sha256=MRhkTVVH2iKWc_GPX5E2uoafBV-tDVxyY58d_S4Zgwo,479
101
+ plain/templates/jinja/globals.py,sha256=qhvQuikkRkOTpHSW5FwdsvoViJNlRgHq3-O7ZyeajsE,669
102
102
  plain/test/README.md,sha256=Zso3Ir7a8vQerzKB6egjROQWkpveLAbscn7VTROPAiU,37
103
103
  plain/test/__init__.py,sha256=rXe88Y602NP8DBnReSyXb7dUzKoWweLuT43j-qwOUl4,138
104
104
  plain/test/client.py,sha256=cu43S-NL606VERUYi7NjvzIrVchlNLHqcKro7pnYmS4,31385
@@ -152,8 +152,8 @@ plain/views/objects.py,sha256=9QBYyb8PgkRirXCQ8-Pms4_yMzP37dfeL30hWRYmtZg,7909
152
152
  plain/views/redirect.py,sha256=KLnlktzK6ZNMTlaEiZpMKQMEP5zeTgGLJ9BIkIJfwBo,1733
153
153
  plain/views/templates.py,sha256=nF9CcdhhjAyp3LB0RrSYnBaHpHzMfPSw719RCdcXk7o,2007
154
154
  plain/wsgi.py,sha256=R6k5FiAElvGDApEbMPTT0MPqSD7n2e2Az5chQqJZU0I,236
155
- plain-0.3.0.dist-info/LICENSE,sha256=m0D5O7QoH9l5Vz_rrX_9r-C8d9UNr_ciK6Qwac7o6yo,3175
156
- plain-0.3.0.dist-info/METADATA,sha256=Z7t7-Jdot0U9cymStFyaaItjoTsk8Ls8lSEu4pkzJ7Y,2716
157
- plain-0.3.0.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
158
- plain-0.3.0.dist-info/entry_points.txt,sha256=7O1RZTmMasKYB73bfqQcTwIhsXo7RjEIKv2WbtTtOIM,39
159
- plain-0.3.0.dist-info/RECORD,,
155
+ plain-0.3.1.dist-info/LICENSE,sha256=m0D5O7QoH9l5Vz_rrX_9r-C8d9UNr_ciK6Qwac7o6yo,3175
156
+ plain-0.3.1.dist-info/METADATA,sha256=jqe-VkpbsAVz8oO9xeOuDmZPkvszIdUfXzgTyxr0yJU,2716
157
+ plain-0.3.1.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
158
+ plain-0.3.1.dist-info/entry_points.txt,sha256=7O1RZTmMasKYB73bfqQcTwIhsXo7RjEIKv2WbtTtOIM,39
159
+ plain-0.3.1.dist-info/RECORD,,
File without changes
File without changes