e0f92b6185
Don't log entire exception when forwarding a 412 Precondition Failed.
2016-09-23 09:40:05 +02:00
0f23ee7a08
Added handler for 412 Precondition Failed from SDK.
2016-09-22 18:09:43 +02:00
cd8707207b
Made format_undertitle() Jinja filter None-safe
2016-09-22 10:33:51 +02:00
7f9f89853d
Properly handle embed/non-embed error renders for some SDK exceptions.
2016-09-22 09:25:59 +02:00
78824c9c2a
Allow extensions to define custom project properties
2016-09-20 15:59:39 +02:00
40896fc70b
Better logging when bad extension class is given.
...
This was necessary to debug an issue with different unit tests influencing
each other in Attract.
2016-09-20 15:59:39 +02:00
df8afb8b14
Append license notes to Algolia index
...
So we can keep nodes without description or uploaded by other users (like
textures), with clean names and still be able to search them easily by
their copyright notes.
Reviewers: sybren, fsiddi
Reviewed By: sybren, fsiddi
Differential Revision: https://developer.blender.org/D2225
2016-09-14 09:39:19 +02:00
76b0f5fc46
Moved login-code into a separate function.
...
This makes it easier to log in users by their token from unittests.
2016-09-08 12:03:51 +02:00
68666f0650
Updated unittest code so that we can create 100% valid projects.
...
This means also creating a user and groups so that the references are
valid.
2016-09-08 12:03:17 +02:00
4313284dab
Added 'hide_none' Jinja filter, which replaces None with an empty string
2016-09-07 17:01:56 +02:00
9e6b998c50
Refactored static file handling so that extensions can provide static files
2016-09-07 16:36:25 +02:00
b2e8711ac4
Moved Jinja2 stuff to its own module, and added |undertitle filter.
2016-09-07 16:03:40 +02:00
2730a7a2b2
Added error handlers for some PillarSDK exceptions.
2016-09-07 12:23:48 +02:00
f21b708085
Made it easier for extensions to register multiple blueprints at different URLs
...
The blueprint's own url_prefix='/xxx' setting is now taken into account.
2016-09-07 11:40:24 +02:00
8a6cd96198
Added pi-users icon + documented regeneration of pillar-font.
2016-09-07 11:14:36 +02:00
4ae36a0dc3
Allow custom template dirs for extensions
2016-09-06 18:39:35 +02:00
eac49ab810
Use BLENDER_ID_ENDPOINT to get roles from BlenderID
...
Also refactored some code.
2016-09-06 17:27:14 +02:00
49c08cba10
Custom error handlers: also properly handle non-Werkzeug exceptions.
2016-09-06 17:10:50 +02:00
cf30bb5d62
Use BlenderID-side roles to grant demo role.
2016-09-06 16:42:48 +02:00
ab5a4a6b6c
Custom error pages.
...
These make a distinction between API requests on /api/ (which will return
a JSON response) and other requests (which will return HTML).
Fixes T49212
2016-09-06 14:22:52 +02:00
3bb55fd3db
User admin: properly handle AJAX errors.
...
Added specific handling for clicking on non-existing users. The styling
might need some tweaking (it's pretty ugly), but then again, it's just
for us admins.
2016-09-06 11:27:49 +02:00
486686f1f9
File upload: Removed JS-side file size check.
...
Instead, the size of the entire HTTP request body is checked against the
maximum file size. This allows for slightly smaller files (in the order
of 200-300 bytes), which shouldn't be noticeable given our 32 MiB limit
for non-subscribers. This check is performed before accessing
request.files[], and thus before the file even starts uploading.
This also allows unlimited file uploads to subscribers and demo users.
This was already possible using the API, so now the web interface is
consistent. Limits can be set using config[_local].py.
This closes T49264: Allow large uploads for admins
2016-09-06 10:33:28 +02:00
e58f29a9d0
Fix missing pictures on latest blog posts and node updates
2016-09-05 16:00:45 +02:00
fa050da8e2
Display Blog on the sidebar, if available
2016-09-05 16:00:45 +02:00
3d9b9e40d4
Added PillarExtension.setup_app(app)
...
It's called on each extension after all extensions have been processed,
and after all built-in Pillar modules have had their setup_app() called.
Call order is random.
2016-08-31 16:03:45 +02:00
4cf779e040
Keep reference to loaded extension, and refuse to load twice.
...
The Pillar extensions are now stored, by their name, in a dictionary.
2016-08-31 16:02:55 +02:00
a0cc76259e
Renamed TestPillarServer to PillarTestServer
...
TestXXX classes are seen as unit tests by py.test, so anything that's not
a unit test should not be called TestXXX.
2016-08-31 11:29:16 +02:00
5ebec42e6d
Removed unused, commented-out code
2016-08-30 15:58:58 +02:00
4529d0597b
Gracefully handle nodes of a type for which we don't have a template.
...
Before, it would simply return a 500 Internal Server Error.
2016-08-30 15:52:55 +02:00
3039aef7d3
Removed Attract node types.
...
Those are moved into the new Blender Cloud server's Attract module.
2016-08-30 14:24:14 +02:00
cb84e6f0b7
Allow CLI commands to set the current user to a non-existing admin user.
2016-08-30 14:24:14 +02:00
88b5537df4
Avoid crash when there is no current user
2016-08-30 14:24:14 +02:00
88dd574797
No longer using flask.ext.XXX, more imports have to change too.
2016-08-30 14:24:14 +02:00
8d6df947c8
User our own jQuery
2016-08-30 14:10:04 +02:00
b9b993fe4a
Extension system: allow empty Eve settings.
...
Extensions are now able to return an empty dict from their eve_settings()
method.
2016-08-30 13:55:43 +02:00
32c130ed93
Fall back to application/octet-stream when there is no content-type header
2016-08-26 17:57:52 +02:00
634b233685
mass_copy_between_backends: Also catch unexpected exceptions, and simply move on to the next file.
2016-08-26 17:50:40 +02:00
eb7b875122
Copying files to other backend now works
2016-08-26 15:52:02 +02:00
c4a3601939
Broken file_storage.py up into file_storage/{__init__,moving}.py
2016-08-26 15:36:34 +02:00
225f9ae054
WIP for change file backends
2016-08-26 15:36:34 +02:00
163db3f2b8
Let generated links for 'unittest' backend actually be a valid link.
2016-08-26 15:35:18 +02:00
dd6fc8bde4
generate_link: warn when GCS blob can't be found.
2016-08-26 15:34:58 +02:00
ff692d287c
Added 'check_cdnsun' management command.
...
This command performs a HEAD on each file stored at CDNSun, including its
variations. Logs missing variations and missing main files (but only when
there are no variations).
2016-08-26 14:16:05 +02:00
04c9c010f0
p.view_node(): check node_id for validity, before sending it to the API
...
This prevents a pillarsdk.exceptions.MethodNotAllowed exception, which
would result in a 500 Internal Server Error on the frontend.
2016-08-24 14:49:30 +02:00
b6c623cca8
Don't import every function from pillar.web.utils individually.
...
Instead, just "from pillar.web import utils" and then use utils.X to
get to the util function.
2016-08-24 14:26:47 +02:00
9b2a419d9b
Extra debug logging for file uploads
2016-08-24 11:33:02 +02:00
d5cf3b8246
Moved TLS cert file to post() call instead of session.
...
Another way to make it work is to set it on the session, and explicitly
specify verify=True in the post() call.
2016-08-23 17:45:31 +02:00
0d3ed3af2c
Explicitly use certificate chain.
2016-08-23 17:45:08 +02:00
751a321aa6
Document return type
2016-08-23 17:42:42 +02:00
207d821564
Override image/x-exr mimetype with application/x-exr
...
This prevents us from handling EXR files as images, at least until the
time when we can properly thumbnail those.
2016-08-23 17:41:56 +02:00