Merge branch 'master' into DAL-modular
* master: (58 commits) changed version number better types by default, given that we're on 2005 at least fix for StorageList and tests added improved coverage, fix bug with IS_LIST_OF and items not being strings fix cache.increment, added tests R-2.9.11 reverted simplejson R-2.9.10 upgraded memcache and markdown2 upgraded pypyodbc.py upgraded simplejson no more split in contains, thanks Niphlod fixed wording and bug on contains(), made smart_query use ilike instead of like ilike, thanks Niphlod CROSS JOIN, thanks jotbe added custom represent to GoogleDatastoreAdapter, thanks Alan postgresql: identifies what adapter auto-loads json values added more tests for json Field fixed typo in driver_auto_json Improve the graphing to show the name of the application. ... Conflicts: gluon/dal.py gluon/globals.py gluon/tests/test_dal.py
This commit is contained in:
+7
-4
@@ -96,7 +96,7 @@ IDENTIFIER = "%s#%s" % (socket.gethostname(),os.getpid())
|
||||
logger = logging.getLogger('web2py.scheduler.%s' % IDENTIFIER)
|
||||
|
||||
from gluon import DAL, Field, IS_NOT_EMPTY, IS_IN_SET, IS_NOT_IN_DB
|
||||
from gluon import IS_INT_IN_RANGE, IS_DATETIME
|
||||
from gluon import IS_INT_IN_RANGE, IS_DATETIME, IS_IN_DB
|
||||
from gluon.utils import web2py_uuid
|
||||
from gluon.storage import Storage
|
||||
|
||||
@@ -671,7 +671,10 @@ class Scheduler(MetaScheduler):
|
||||
db.define_table(
|
||||
'scheduler_task_deps',
|
||||
Field('job_name', default='job_0'),
|
||||
Field('task_parent', 'reference scheduler_task'),
|
||||
Field('task_parent', 'integer',
|
||||
requires=IS_IN_DB(db, 'scheduler_task.id',
|
||||
'%(task_name)s')
|
||||
),
|
||||
Field('task_child', 'reference scheduler_task'),
|
||||
Field('can_visit', 'boolean', default=False),
|
||||
migrate=self.__get_migrate('scheduler_task_deps', migrate)
|
||||
@@ -1311,7 +1314,7 @@ class Scheduler(MetaScheduler):
|
||||
"""
|
||||
from gluon.dal import Query
|
||||
sr, st = self.db.scheduler_run, self.db.scheduler_task
|
||||
if isinstance(ref, int):
|
||||
if isinstance(ref, (int, long)):
|
||||
q = st.id == ref
|
||||
elif isinstance(ref, str):
|
||||
q = st.uuid == ref
|
||||
@@ -1362,7 +1365,7 @@ class Scheduler(MetaScheduler):
|
||||
Experimental
|
||||
"""
|
||||
st, sw = self.db.scheduler_task, self.db.scheduler_worker
|
||||
if isinstance(ref, int):
|
||||
if isinstance(ref, (int, long)):
|
||||
q = st.id == ref
|
||||
elif isinstance(ref, str):
|
||||
q = st.uuid == ref
|
||||
|
||||
Reference in New Issue
Block a user