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

All Samples(18)  |  Call(11)  |  Derive(2)  |  Import(5)

src/x/t/xtas-HEAD/xtas/worker.py   xtas(Download)
import os
 
from celery.bin.worker import worker
 
from . import __version__
 
    # XXX app.worker_main is prettier but doesn't seem to reply to --loglevel.
    w = worker(app=app)
    w.run(loglevel=args.loglevel)
 

src/c/e/celery-3.1.11/celery/bin/celery.py   celery(Download)
from celery.bin.events import events
from celery.bin.graph import graph
from celery.bin.worker import worker
 
__all__ = ['CeleryCommand', 'main']

src/c/e/celery-HEAD/celery/bin/celery.py   celery(Download)
from celery.bin.events import events
from celery.bin.graph import graph
from celery.bin.worker import worker
 
__all__ = ['CeleryCommand', 'main']

src/c/e/celery-3.1.11/celery/tests/bin/test_worker.py   celery(Download)
from celery.app import trace
from celery.apps import worker as cd
from celery.bin.worker import worker, main as worker_main
from celery.exceptions import (
    ImproperlyConfigured, WorkerShutdown, WorkerTerminate,
    def test_setup_concurrency_very_early(self):
        x = worker()
        x.run = Mock()
        with self.assertRaises(ImportError):
            x.execute_from_commandline(['worker', '-P', 'xyzybox'])
 
    def test_run_from_argv_basic(self):
        x = worker(app=self.app)
    def test_maybe_detach(self):
        x = worker(app=self.app)
        with patch('celery.bin.worker.detached_celeryd') as detached:
            x.maybe_detach([])
            self.assertFalse(detached.called)
    def test_invalid_loglevel_gives_error(self):
        x = worker(app=self.app)
        with self.assertRaises(SystemExit):
            x.run(loglevel='GRIM_REAPER')
 

src/c/e/celery-HEAD/celery/tests/bin/test_worker.py   celery(Download)
from celery.app import trace
from celery.apps import worker as cd
from celery.bin.worker import worker, main as worker_main
from celery.exceptions import (
    ImproperlyConfigured, WorkerShutdown, WorkerTerminate,
    def test_setup_concurrency_very_early(self):
        x = worker()
        x.run = Mock()
        with self.assertRaises(ImportError):
            x.execute_from_commandline(['worker', '-P', 'xyzybox'])
 
    def test_run_from_argv_basic(self):
        x = worker(app=self.app)
    def test_maybe_detach(self):
        x = worker(app=self.app)
        with patch('celery.bin.worker.detached_celeryd') as detached:
            x.maybe_detach([])
            self.assertFalse(detached.called)
    def test_invalid_loglevel_gives_error(self):
        x = worker(app=self.app)
        with self.assertRaises(SystemExit):
            x.run(loglevel='GRIM_REAPER')
 

src/c/e/celery-HEAD/celery/tests/app/test_app.py   celery(Download)
        class worker(worker_bin.worker):
 
            def execute_from_commandline(self, argv):
                return argv
 

src/c/e/celery-3.1.11/celery/tests/app/test_app.py   celery(Download)
        class worker(worker_bin.worker):
 
            def execute_from_commandline(self, argv):
                return argv