Skip to content

Commit

Permalink
Merge 6759be3 into 9fe002b
Browse files Browse the repository at this point in the history
  • Loading branch information
vangheem committed Mar 19, 2018
2 parents 9fe002b + 6759be3 commit b1cc1d9
Show file tree
Hide file tree
Showing 14 changed files with 629 additions and 373 deletions.
5 changes: 3 additions & 2 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
2.4.8 (unreleased)
2.5.0 (unreleased)
------------------

- Nothing changed yet.
- normalize file manager api so we can have more simple integrations with s3/gcloud
[vangheem]


2.4.7 (2018-03-17)
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.4.8.dev0
2.5.0.dev0
5 changes: 4 additions & 1 deletion guillotina/api/service.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,10 @@ async def publish_traverse(self, traverse):
if field is None:
raise KeyError('No valid name')

self.field = field.bind(self.behavior)
if self.behavior is not None:
self.field = field.bind(self.behavior)
else:
self.field = field.bind(self.context)
else:
self.field = None

Expand Down
5 changes: 5 additions & 0 deletions guillotina/exceptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,3 +210,8 @@ def __init__(self, field, value, msg):
class QueryParsingError(Exception):
"""An error happened while parsing a search query.
"""


class FileNotFoundException(Exception):
'''
'''
7 changes: 5 additions & 2 deletions guillotina/files/__init__.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
from .adapter import DBFileManagerAdapter # noqa
from .adapter import DBFileStorageManagerAdapter # noqa
from .const import CHUNK_SIZE # noqa
from .const import MAX_REQUEST_CACHE_SIZE # noqa
from .const import MAX_RETRIES # noqa
from .field import BaseCloudFile # noqa
from .field import CloudFileField # noqa
from .manager import CloudFileManager # noqa
from .manager import FileManager # noqa
from .utils import convert_base64_to_binary # noqa
from .utils import get_contenttype # noqa
from .utils import read_request_data # noqa
from guillotina.exceptions import UnRetryableRequestError # noqa


CloudFileManager = FileManager # b/w compat

0 comments on commit b1cc1d9

Please sign in to comment.