Did I find the right examples for you? yes no

All Samples(20)  |  Call(13)  |  Derive(0)  |  Import(7)

src/c/i/ciel-HEAD/src/python/ciel/runtime/util/cat.py   ciel(Download)
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
from optparse import OptionParser
from ciel.runtime.object_cache import retrieve_object_for_ref
from ciel.public.references import SWReferenceJSONEncoder,\
    json_decode_object_hook
 
            if options.json:
                obj = retrieve_object_for_ref(ref, 'json', None)
                simplejson.dump(obj, sys.stdout, cls=SWReferenceJSONEncoder, indent=4)
                print
            else:
                fh = retrieve_object_for_ref(ref, 'handle', None)
        for url in urls:
            if options.json:
                obj = retrieve_object_for_ref(SWURLReference([url]), 'json', None)
                simplejson.dump(obj, sys.stdout, cls=SWReferenceJSONEncoder, indent=4)
                print
            else:
                fh = retrieve_object_for_ref(SWURLReference([url]), 'handle', None)

src/c/i/ciel-HEAD/src/python/ciel/runtime/executors/base.py   ciel(Download)
import ciel
import logging
from ciel.runtime.object_cache import retrieve_object_for_ref,\
    ref_from_object
 
    def prepare_task_descriptor_for_execute(cls, task_descriptor, task_record, block_store):
        # Convert task_private from a reference to an object in here.
        try:
            task_descriptor["task_private"] = retrieve_object_for_ref(task_descriptor["task_private"], BaseExecutor.TASK_PRIVATE_ENCODING, task_record)
        except:

src/c/i/ciel-HEAD/src/python/ciel/runtime/util/start_job.py   ciel(Download)
    SW2_SocketStreamReference, SW2_StreamReference, SW2_ConcreteReference,\
    build_reference_from_tuple
from ciel.runtime.object_cache import retrieve_object_for_ref, decoders
from optparse import OptionParser
from ciel.runtime.block_store import get_fetch_urls_for_ref
        ref = external_get_real_ref(ref, jobid, master_uri)
    if isinstance(ref, SWDataValue):
        return retrieve_object_for_ref(ref, decoder, None)
    elif isinstance(ref, SW2_ConcreteReference):
        urls = get_fetch_urls_for_ref(ref)
 
    try:
        j_return = retrieve_object_for_ref(reflist[0], "json", None)
    except:
        try:
            j_return = retrieve_object_for_ref(reflist[0], "noop", None)

src/c/i/ciel-HEAD/src/python/ciel/runtime/util/run_script.py   ciel(Download)
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
from ciel.runtime.exceptions import ErrorReferenceError
from ciel.runtime.object_cache import retrieve_object_for_ref
import ciel.runtime.util.start_job
import time
 
    try:
        reflist = retrieve_object_for_ref(result, "json", None)
        sw_return = retrieve_object_for_ref(reflist[0], "json", None)
    except ErrorReferenceError, ere:

src/c/i/ciel-HEAD/src/python/ciel/runtime/executors/__init__.py   ciel(Download)
from ciel.runtime.producer import make_local_output
from ciel.runtime.fetcher import fetch_ref_async
from ciel.runtime.object_cache import retrieve_object_for_ref, ref_from_object,\
    cache_object
 
def package_lookup(task_record, block_store, key):
    if task_record.package_ref is None:
        ciel.log.error("Package lookup for %s in task without package" % key, "EXEC", logging.WARNING)
        return None
    package_dict = retrieve_object_for_ref(task_record.package_ref, "pickle", task_record)

src/c/i/ciel-HEAD/src/python/ciel/runtime/executors/simple.py   ciel(Download)
from ciel.runtime.executors import hash_update_with_structure,\
    ContextManager, list_with, add_running_child, remove_running_child
from ciel.runtime.object_cache import ref_from_object,\
    retrieve_object_for_ref
from ciel.runtime.fetcher import retrieve_filenames_for_refs, OngoingFetch
        self.output_refs = [None for _ in range(len(self.output_ids))]
        self.succeeded = False
        self.args = retrieve_object_for_ref(task_private["simple_exec_args"], "pickle", self.task_record)
 
        try:

src/c/i/ciel-HEAD/src/python/ciel/runtime/util/skypy_submit.py   ciel(Download)
 
import ciel.runtime.util.start_job
from ciel.runtime.object_cache import retrieve_object_for_ref
import time
import datetime
    result = ciel.runtime.util.start_job.await_job(new_job["job_id"], master_uri)
 
    reflist = retrieve_object_for_ref(result, "json", None)
 
    return reflist[0]