horsemeat 2.23.3__tar.gz → 2.24.1__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.
- {horsemeat-2.23.3 → horsemeat-2.24.1}/PKG-INFO +1 -1
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/version.py +1 -1
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/webapp/handler.py +2 -2
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/webapp/request.py +12 -2
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat.egg-info/PKG-INFO +1 -1
- {horsemeat-2.23.3 → horsemeat-2.24.1}/MANIFEST.in +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/README +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/__init__.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/configwrapper.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/model/__init__.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/model/newsmessage.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/model/session.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/model/user.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/pg.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/scripts/make-frippery-project +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/tests/__init__.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/tests/test_configwrapper.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/webapp/__init__.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/webapp/bogusrequest.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/webapp/dispatcher.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/webapp/framework_templates/__init__.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/webapp/frameworkhandlers.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/webapp/response.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat/webapp/scrubber.py +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat.egg-info/SOURCES.txt +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat.egg-info/dependency_links.txt +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat.egg-info/requires.txt +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/horsemeat.egg-info/top_level.txt +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/requirements.txt +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/setup.cfg +0 -0
- {horsemeat-2.23.3 → horsemeat-2.24.1}/setup.py +0 -0
@@ -236,7 +236,7 @@ class Handler(object):
|
|
236
236
|
"""
|
237
237
|
|
238
238
|
if not self.route_patterns:
|
239
|
-
raise Exception("You need some route patterns!")
|
239
|
+
raise Exception(f"You need some route patterns in {self!r}!")
|
240
240
|
|
241
241
|
for rp in self.route_patterns:
|
242
242
|
|
@@ -261,7 +261,7 @@ class Handler(object):
|
|
261
261
|
def check_route_strings(self, req):
|
262
262
|
|
263
263
|
if not self.route_strings:
|
264
|
-
raise Exception("You need to define some route strings!")
|
264
|
+
raise Exception(f"You need to define some route strings in handler {self!r}")
|
265
265
|
|
266
266
|
if req.line_one in self.route_strings:
|
267
267
|
return self.handle
|
@@ -1,6 +1,5 @@
|
|
1
1
|
# vim: set expandtab ts=4 sw=4 filetype=python fileencoding=utf8:
|
2
2
|
|
3
|
-
import cgi
|
4
3
|
import collections.abc
|
5
4
|
import http.cookies
|
6
5
|
import hashlib
|
@@ -519,7 +518,18 @@ class Request(collections.abc.MutableMapping):
|
|
519
518
|
def parsed_content_type(self):
|
520
519
|
|
521
520
|
if self.CONTENT_TYPE:
|
522
|
-
|
521
|
+
|
522
|
+
# cgi module is deprecated.
|
523
|
+
#
|
524
|
+
# return cgi.parse_header(self.CONTENT_TYPE)
|
525
|
+
|
526
|
+
# here is recommended new approach
|
527
|
+
# https://docs.python.org/3.11/library/cgi.html#cgi.parse_header
|
528
|
+
|
529
|
+
from email.message import EmailMessage
|
530
|
+
msg = EmailMessage()
|
531
|
+
msg["content-type"] = self.CONTENT_TYPE
|
532
|
+
return msg.get_params()
|
523
533
|
|
524
534
|
@property
|
525
535
|
def charset(self):
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|