plain 0.72.0__py3-none-any.whl → 0.72.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.
plain/CHANGELOG.md CHANGED
@@ -1,5 +1,15 @@
1
1
  # plain changelog
2
2
 
3
+ ## [0.72.1](https://github.com/dropseed/plain/releases/plain@0.72.1) (2025-10-02)
4
+
5
+ ### What's changed
6
+
7
+ - Fixed documentation examples to use the correct view attribute names (`self.user` instead of `self.request.user`) ([f6278d9](https://github.com/dropseed/plain/commit/f6278d9bb4))
8
+
9
+ ### Upgrade instructions
10
+
11
+ - No changes required
12
+
3
13
  ## [0.72.0](https://github.com/dropseed/plain/releases/plain@0.72.0) (2025-10-02)
4
14
 
5
15
  ### What's changed
plain/views/README.md CHANGED
@@ -181,7 +181,7 @@ class ExampleDetailView(DetailView):
181
181
  def get_object(self):
182
182
  return MyObjectClass.query.get(
183
183
  id=self.url_kwargs["id"],
184
- user=self.request.user, # Limit access
184
+ user=self.user, # Limit access
185
185
  )
186
186
 
187
187
 
@@ -199,7 +199,7 @@ class ExampleUpdateView(UpdateView):
199
199
  def get_object(self):
200
200
  return MyObjectClass.query.get(
201
201
  id=self.url_kwargs["id"],
202
- user=self.request.user, # Limit access
202
+ user=self.user, # Limit access
203
203
  )
204
204
 
205
205
 
@@ -213,7 +213,7 @@ class ExampleDeleteView(DeleteView):
213
213
  def get_object(self):
214
214
  return MyObjectClass.query.get(
215
215
  id=self.url_kwargs["id"],
216
- user=self.request.user, # Limit access
216
+ user=self.user, # Limit access
217
217
  )
218
218
 
219
219
 
@@ -222,7 +222,7 @@ class ExampleListView(ListView):
222
222
 
223
223
  def get_objects(self):
224
224
  return MyObjectClass.query.filter(
225
- user=self.request.user, # Limit access
225
+ user=self.user, # Limit access
226
226
  )
227
227
  ```
228
228
 
@@ -241,7 +241,7 @@ from plain.http import Response
241
241
 
242
242
  class ExampleView(DetailView):
243
243
  def get_object(self):
244
- if self.request.user.exceeds_rate_limit:
244
+ if self.user and self.user.exceeds_rate_limit:
245
245
  raise ResponseException(
246
246
  Response("Rate limit exceeded", status_code=429)
247
247
  )
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: plain
3
- Version: 0.72.0
3
+ Version: 0.72.1
4
4
  Summary: A web framework for building products with Python.
5
5
  Author-email: Dave Gaeddert <dave.gaeddert@dropseed.dev>
6
6
  License-File: LICENSE
@@ -1,5 +1,5 @@
1
1
  plain/AGENTS.md,sha256=As6EFSWWHJ9lYIxb2LMRqNRteH45SRs7a_VFslzF53M,1046
2
- plain/CHANGELOG.md,sha256=BtIi33MSvdQGi1d2UVzC0WSBA1fxMVAGHXaDkTSYLiY,22042
2
+ plain/CHANGELOG.md,sha256=pD1_OEbmCUj4xU7Q1Vnq_k5bWp1Y7TdPyz7am9_2OmQ,22376
3
3
  plain/README.md,sha256=5BJyKhf0TDanWVbOQyZ3zsi5Lov9xk-LlJYCDWofM6Y,4078
4
4
  plain/__main__.py,sha256=GK39854Lc_LO_JP8DzY9Y2MIQ4cQEl7SXFJy244-lC8,110
5
5
  plain/debug.py,sha256=C2OnFHtRGMrpCiHSt-P2r58JypgQZ62qzDBpV4mhtFM,855
@@ -153,7 +153,7 @@ plain/utils/text.py,sha256=teav7elbqEtGnhKG3ajf-V9Hb-Gsg8uqDrogqWizqjI,10094
153
153
  plain/utils/timesince.py,sha256=a_-ZoPK_s3Pt998CW4rWp0clZ1XyK2x04hCqak2giII,5928
154
154
  plain/utils/timezone.py,sha256=M_I5yvs9NsHbtNBPJgHErvWw9vatzx4M96tRQs5gS3g,6823
155
155
  plain/utils/tree.py,sha256=rj_JpZ2kVD3UExWoKnsRdVCoRjvzkuVOONcHzREjSyw,4766
156
- plain/views/README.md,sha256=caUSKUhCSs5hdxHC5wIVzKkumPXiuNoOFRnIs3CUHfo,7215
156
+ plain/views/README.md,sha256=6mcoSQp60n8qgoIMNDQr29WThpi-NCj8EMqxPNwWpiE,7189
157
157
  plain/views/__init__.py,sha256=a-N1nkklVohJTtz0yD1MMaS0g66HviEjsKydNVVjvVc,392
158
158
  plain/views/base.py,sha256=fk9zAY5BMVBeM45dWL7A9BMTdUi6eTFMeVDd5kBVdv8,4478
159
159
  plain/views/errors.py,sha256=tHD7MNnZcMyiQ46RMAnX1Ne3Zbbkr1zAiVfJyaaLtSQ,1447
@@ -162,8 +162,8 @@ plain/views/forms.py,sha256=ESZOXuo6IeYixp1RZvPb94KplkowRiwO2eGJCM6zJI0,2400
162
162
  plain/views/objects.py,sha256=5y0PoPPo07dQTTcJ_9kZcx0iI1O7regsooAIK4VqXQ0,5579
163
163
  plain/views/redirect.py,sha256=mIpSAFcaEyeLDyv4Fr6g_ektduG4Wfa6s6L-rkdazmM,2154
164
164
  plain/views/templates.py,sha256=9LgDMCv4C7JzLiyw8jHF-i4350ukwgixC_9y4faEGu0,1885
165
- plain-0.72.0.dist-info/METADATA,sha256=Do-bYyzKeMCcIh-WWtf1dN2OapU5J03g9bZkgonB2Q4,4488
166
- plain-0.72.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
167
- plain-0.72.0.dist-info/entry_points.txt,sha256=wvMzY-iREvfqRgyLm77htPp4j_8CQslLoZA15_AnNo8,171
168
- plain-0.72.0.dist-info/licenses/LICENSE,sha256=m0D5O7QoH9l5Vz_rrX_9r-C8d9UNr_ciK6Qwac7o6yo,3175
169
- plain-0.72.0.dist-info/RECORD,,
165
+ plain-0.72.1.dist-info/METADATA,sha256=votvdTzOMDYAD0cjpQAsTMGVd3PXX3QSJx76mTxlQ9o,4488
166
+ plain-0.72.1.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
167
+ plain-0.72.1.dist-info/entry_points.txt,sha256=wvMzY-iREvfqRgyLm77htPp4j_8CQslLoZA15_AnNo8,171
168
+ plain-0.72.1.dist-info/licenses/LICENSE,sha256=m0D5O7QoH9l5Vz_rrX_9r-C8d9UNr_ciK6Qwac7o6yo,3175
169
+ plain-0.72.1.dist-info/RECORD,,
File without changes