Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(36)  |  Call(8)  |  Derive(0)  |  Import(28)

src/p/y/pyon-HEAD/pyon/datastore/couchdb/base_store.py   pyon(Download)
from pyon.datastore.couchdb.couch_common import AbstractCouchDataStore
from pyon.datastore.couchdb.views import get_couchdb_view_designs
from pyon.core.exception import BadRequest, Conflict, NotFound
from pyon.util.containers import get_safe, DictDiffer
 
        except ResourceConflict:
            if "_rev" in doc:
                raise Conflict("Object with id %s revision conflict" % doc["_id"])
            else:
                raise BadRequest("Object with id %s already exists" % doc["_id"])
            raise NotFound('Object with id %s does not exist.' % doc_id)
        except ResourceConflict:
            raise Conflict("Object with id %s revision conflict" % doc["_id"])
 
    def delete_doc_mult(self, object_ids, datastore_name=None, object_type=None):

src/p/y/pyon-HEAD/pyon/datastore/postgresql/base_store.py   pyon(Download)
from ooi.logging import log
 
from pyon.core.exception import BadRequest, Conflict, NotFound, Inconsistent
from pyon.datastore.datastore_common import DataStore
from pyon.datastore.datastore_query import DQ
            #except NotFound:
            #    raise
            raise Conflict("Object with id %s revision conflict" % doc["_id"])
        return doc["_id"], doc["_rev"]
 
    def _assert_doc_rev(self, doc, datastore_name=None):
        rev = self._read_doc_rev(doc["_id"], datastore_name=datastore_name)
        if rev != doc["_rev"]:
            raise Conflict("Object with id %s revision conflict is=%s, need=%s" % (doc["_id"], rev, doc["_rev"]))
 

src/p/y/pyon-HEAD/pyon/datastore/couchdb/couchdb_standalone.py   pyon(Download)
from couchdb.http import PreconditionFailed, ResourceConflict, ResourceNotFound, ServerError
 
from pyon.core.exception import BadRequest, Conflict, NotFound
from pyon.util.containers import get_safe, DictDiffer
 
        except ResourceConflict:
            if "_rev" in doc:
                raise Conflict("Object with id %s revision conflict" % doc["_id"])
            else:
                raise BadRequest("Object with id %s already exists" % doc["_id"])
            raise NotFound('Object with id %s does not exist.' % doc_id)
        except ResourceConflict:
            raise Conflict("Object with id %s revision conflict" % doc["_id"])
 
    def delete_doc_mult(self, object_ids, datastore_name=None):

src/p/y/pyon-HEAD/pyon/core/config.py   pyon(Download)
def apply_remote_config(bootstrap_cfg, system_cfg):
    from pyon.core.bootstrap import get_sys_name
    from pyon.core.exception import Conflict
    from pyon.ion.directory_standalone import DirectoryStandalone
    directory = DirectoryStandalone(sysname=get_sys_name(), config=bootstrap_cfg)
 
    de = directory.lookup("/Config/CFG")
    if not de:
        raise Conflict("Expected /Config/CFG in directory. Correct Org??")

src/p/y/pyon-HEAD/pyon/agent/agent.py   pyon(Download)
from pyon.core.exception import IonException
from pyon.core.exception import BadRequest
from pyon.core.exception import Conflict
from pyon.core.exception import NotFound
from pyon.core.exception import ServerError
 
        if isinstance(ex, FSMStateError):
            iex = Conflict(*(ex.args))
 
        elif isinstance(ex, FSMCommandUnknownError):

src/p/y/pyon-HEAD/pyon/public.py   pyon(Download)
__all__ += ['PyonThreadError', 'PyonThread', 'PyonThreadManager']
 
from pyon.core.exception import BadRequest, NotFound, Inconsistent, Conflict, IonException, Timeout
__all__ += ['BadRequest', 'NotFound', 'Inconsistent', 'Conflict', 'IonException', 'Timeout']
 

src/p/y/pyon-HEAD/pyon/datastore/couchbase/base_store.py   pyon(Download)
from pyon.datastore.couchdb.couch_common import AbstractCouchDataStore
from pyon.datastore.couchbase.views import get_couch_view_designs
from pyon.core.exception import BadRequest, Conflict, NotFound, ServerError
from pyon.util.containers import get_safe, DictDiffer
 

src/p/y/pyon-HEAD/pyon/datastore/postgresql/datastore.py   pyon(Download)
 
from pyon.core.bootstrap import get_obj_registry, CFG
from pyon.core.exception import BadRequest, Conflict, NotFound, Inconsistent
from pyon.core.object import IonObjectBase, IonObjectSerializer, IonObjectDeserializer
from pyon.datastore.postgresql.base_store import PostgresDataStore

src/p/y/pyon-HEAD/pyon/datastore/couchdb/pyon_store.py   pyon(Download)
import simplejson as json
from pyon.core.bootstrap import get_obj_registry
from pyon.core.exception import BadRequest, Conflict, NotFound
from pyon.core.object import IonObjectBase, IonObjectSerializer, IonObjectDeserializer
from pyon.datastore.couchdb.couch_common import AbstractCouchDataStore

src/p/y/pyon-HEAD/pyon/datastore/couchdb/couch_common.py   pyon(Download)
from uuid import uuid4
 
from pyon.core.exception import BadRequest, Conflict, NotFound
from pyon.util.containers import get_safe, DictDiffer
from pyon.util.stats import StatsCounter

  1 | 2 | 3  Next