Did I find the right examples for you? yes no

All Samples(6)  |  Call(2)  |  Derive(0)  |  Import(4)

src/l/a/lacore-0.1.3/lacore/api.py   lacore(Download)
from urlparse import urljoin
from lacore import get_client_info
from lacore.decorators import cached_property, contains
from lacore.async import deferred_property, block
from lacore.exceptions import (ApiAuthException, UploadEmptyError,
            if r.code > 300:
                yield failure.Failure(ApiErrorException(
                    " ".join([str(r.code), str(r.phrase)])))
            r = yield treq.content(r)
            defer.returnValue(json.loads(r))

src/l/o/longaccess-client-HEAD/lacli/login.py   longaccess-client(Download)
from lacli.log import getLogger
from lacli.exceptions import ApiNoSessionError
from lacore.exceptions import (ApiAuthException, ApiErrorException,
                               ApiUnavailableException)
from twisted.internet import defer

src/l/a/lacore-0.1.3/lacore/t/test_api_async.py   lacore(Download)
from mock import patch, Mock
from twisted.internet import defer
from lacore.exceptions import (ApiAuthException, ApiUnavailableException,
                               ApiErrorException)
from lacore.t.test_api import LA_ENDPOINTS_RESPONSE, LA_CAPSULES_RESPONSE

src/l/a/lacore-0.1.3/lacore/t/test_api.py   lacore(Download)
from testtools import TestCase, ExpectedException
from mock import Mock, patch
from itertools import repeat
from . import makeprefs
from lacore.exceptions import (ApiAuthException, ApiErrorException,
                        [LA_ENDPOINTS_RESPONSE, LA_CAPSULES_RESPONSE,
                         LA_UPLOAD_RESPONSE]))
        _gets.append(defer.fail(ApiErrorException()))
        _posts = imap(defer.succeed, repeat(json.loads(LA_UPLOAD_RESPONSE)))
        s = self._mocksessions({'get.side_effect': _gets,