horsemeat 2.25.0__tar.gz → 2.25.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.25.1/PKG-INFO +20 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/version.py +1 -1
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/webapp/handler.py +6 -29
- horsemeat-2.25.1/horsemeat.egg-info/PKG-INFO +20 -0
- horsemeat-2.25.0/PKG-INFO +0 -8
- horsemeat-2.25.0/horsemeat.egg-info/PKG-INFO +0 -8
- {horsemeat-2.25.0 → horsemeat-2.25.1}/MANIFEST.in +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/README +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/__init__.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/configwrapper.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/model/__init__.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/model/newsmessage.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/model/session.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/model/user.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/pg.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/scripts/make-frippery-project +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/tests/__init__.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/tests/test_configwrapper.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/webapp/__init__.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/webapp/bogusrequest.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/webapp/dispatcher.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/webapp/framework_templates/__init__.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/webapp/frameworkhandlers.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/webapp/request.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/webapp/response.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat/webapp/scrubber.py +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat.egg-info/SOURCES.txt +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat.egg-info/dependency_links.txt +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat.egg-info/requires.txt +1 -1
- {horsemeat-2.25.0 → horsemeat-2.25.1}/horsemeat.egg-info/top_level.txt +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/requirements.txt +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/setup.cfg +0 -0
- {horsemeat-2.25.0 → horsemeat-2.25.1}/setup.py +0 -0
@@ -0,0 +1,20 @@
|
|
1
|
+
Metadata-Version: 2.2
|
2
|
+
Name: horsemeat
|
3
|
+
Version: 2.25.1
|
4
|
+
Summary: Web framework for the damned. The mad.
|
5
|
+
Home-page: https://github.com/216software/horsemeat
|
6
|
+
Author: 216 Software, LLC
|
7
|
+
Author-email: info@216software.com
|
8
|
+
Classifier: Programming Language :: Python :: 3
|
9
|
+
Requires-Dist: Jinja2>=2.6
|
10
|
+
Requires-Dist: PyYAML>=3.10
|
11
|
+
Requires-Dist: Werkzeug>=0.10.1
|
12
|
+
Requires-Dist: decorator>=3.4.0
|
13
|
+
Requires-Dist: psycopg2>=2.7
|
14
|
+
Requires-Dist: gunicorn
|
15
|
+
Dynamic: author
|
16
|
+
Dynamic: author-email
|
17
|
+
Dynamic: classifier
|
18
|
+
Dynamic: home-page
|
19
|
+
Dynamic: requires-dist
|
20
|
+
Dynamic: summary
|
@@ -285,34 +285,6 @@ class Handler(object):
|
|
285
285
|
|
286
286
|
pass
|
287
287
|
|
288
|
-
@staticmethod
|
289
|
-
@decorator.decorator
|
290
|
-
def only_allow_superusers(handle_method, self, req):
|
291
|
-
|
292
|
-
"""
|
293
|
-
Add this to a handle method like this::
|
294
|
-
|
295
|
-
@Handler.only_allow_superusers
|
296
|
-
def handle(self, req):
|
297
|
-
...
|
298
|
-
|
299
|
-
And then, if the request isn't from a signed-in superuser,
|
300
|
-
they'll get a JSON reply below.
|
301
|
-
|
302
|
-
If the request is from a signed-in superuser, then your handle
|
303
|
-
method is normal.
|
304
|
-
"""
|
305
|
-
|
306
|
-
if not req.user or not req.user.is_superuser:
|
307
|
-
|
308
|
-
return Response.json(dict(
|
309
|
-
message="Sorry, superusers only!",
|
310
|
-
success=False,
|
311
|
-
reply_timestamp=datetime.datetime.now()))
|
312
|
-
|
313
|
-
else:
|
314
|
-
return handle_method(self, req)
|
315
|
-
|
316
288
|
@property
|
317
289
|
def four_zero_four_template(self):
|
318
290
|
return 'framework_templates/404.html'
|
@@ -335,7 +307,7 @@ class Handler(object):
|
|
335
307
|
they'll get a JSON reply that says nope.
|
336
308
|
|
337
309
|
If the request is from a signed-in user, then your handle
|
338
|
-
method
|
310
|
+
method runs like normal.
|
339
311
|
"""
|
340
312
|
|
341
313
|
if not req.user:
|
@@ -348,6 +320,8 @@ class Handler(object):
|
|
348
320
|
|
349
321
|
resp.status = '401 UNAUTHORIZED'
|
350
322
|
|
323
|
+
return resp
|
324
|
+
|
351
325
|
elif not req.user.is_superuser:
|
352
326
|
|
353
327
|
resp = self.Response.json(dict(
|
@@ -361,6 +335,9 @@ class Handler(object):
|
|
361
335
|
return resp
|
362
336
|
|
363
337
|
else:
|
338
|
+
|
339
|
+
log.debug("Returning...")
|
340
|
+
|
364
341
|
return handler_method(self, req)
|
365
342
|
|
366
343
|
@staticmethod
|
@@ -0,0 +1,20 @@
|
|
1
|
+
Metadata-Version: 2.2
|
2
|
+
Name: horsemeat
|
3
|
+
Version: 2.25.1
|
4
|
+
Summary: Web framework for the damned. The mad.
|
5
|
+
Home-page: https://github.com/216software/horsemeat
|
6
|
+
Author: 216 Software, LLC
|
7
|
+
Author-email: info@216software.com
|
8
|
+
Classifier: Programming Language :: Python :: 3
|
9
|
+
Requires-Dist: Jinja2>=2.6
|
10
|
+
Requires-Dist: PyYAML>=3.10
|
11
|
+
Requires-Dist: Werkzeug>=0.10.1
|
12
|
+
Requires-Dist: decorator>=3.4.0
|
13
|
+
Requires-Dist: psycopg2>=2.7
|
14
|
+
Requires-Dist: gunicorn
|
15
|
+
Dynamic: author
|
16
|
+
Dynamic: author-email
|
17
|
+
Dynamic: classifier
|
18
|
+
Dynamic: home-page
|
19
|
+
Dynamic: requires-dist
|
20
|
+
Dynamic: summary
|
horsemeat-2.25.0/PKG-INFO
DELETED
@@ -1,8 +0,0 @@
|
|
1
|
-
Metadata-Version: 2.1
|
2
|
-
Name: horsemeat
|
3
|
-
Version: 2.25.0
|
4
|
-
Summary: Web framework for the damned. The mad.
|
5
|
-
Home-page: https://github.com/216software/horsemeat
|
6
|
-
Author: 216 Software, LLC
|
7
|
-
Author-email: info@216software.com
|
8
|
-
Classifier: Programming Language :: Python :: 3
|
@@ -1,8 +0,0 @@
|
|
1
|
-
Metadata-Version: 2.1
|
2
|
-
Name: horsemeat
|
3
|
-
Version: 2.25.0
|
4
|
-
Summary: Web framework for the damned. The mad.
|
5
|
-
Home-page: https://github.com/216software/horsemeat
|
6
|
-
Author: 216 Software, LLC
|
7
|
-
Author-email: info@216software.com
|
8
|
-
Classifier: Programming Language :: Python :: 3
|
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
|