Sorry but it failed again:
Traceback with variables (most recent call last):
File “apps/frappe/frappe/core/doctype/scheduled_job_type/scheduled_job_type.py”, line 141, in execute
frappe.get_doc(“Server Script”, script_name).execute_scheduled_method()
self = <ScheduledJobType: sync_daily>
script_name = ‘Sync’
File “apps/frappe/frappe/core/doctype/server_script/server_script.py”, line 185, in execute_scheduled_method
safe_exec(self.script, script_filename=self.name)
self = <ServerScript: Sync>
File “apps/frappe/frappe/utils/safe_exec.py”, line 111, in safe_exec
exec(
script = “import frappe\r\nfrom frappe.utils import add_to_date, today\r\n\r\ndef update_last_sync_checkin():\r\n s = frappe.get_doc(‘Shift Type’, ‘Normal shift’)\r\n last_sync_date = add_to_date(today(), days=-1, as_string=True) + ’ 15:45:00’\r\n s.last_sync_of_checkin = last_sync_date\r\n s.save()\r\n\r\nfrappe.enqueue(update_last_sync_checkin, schedule_time=‘15:40:00’)”
_globals = None
_locals = None
restrict_commit_rollback = False
script_filename = ‘Sync’
exec_globals = {‘json’: {‘loads’: <function loads at 0x7f2d00be6520>, ‘dumps’: <function dumps at 0x7f2d00be5da0>}, ‘as_json’: <function as_json at 0x7f2cffc1cb80>, ‘dict’: <class ‘dict’>, ‘log’: <function log at 0x7f2cffd44b80>, ‘_dict’: <class ‘frappe._dict’>, ‘args’: {}, ‘frappe’: {‘call’: <function call_whitelisted_function at 0x7f2cfc2a2ac0>, ‘flags’: {}, ‘format’: <function format_value at 0x7f2cffc1cd60>, ‘format_value’: <function format_value at 0x7f2cffc1cd60>, ‘date_format’: ‘dd-mm-yyyy’, ‘time_format’: ‘HH:mm:ss’, ‘format_date’: <function global_date_format at 0x7f2cffcf5b20>, ‘form_dict’: {}, ‘bold’: <function bold at 0x7f2cffc1d580>, ‘copy_doc’: <function copy_doc at 0x7f2cffc1c680>, ‘errprint’: <function errprint at 0x7f2cffd44a40>, ‘qb’: <class ‘frappe.query_builder.builder.MariaDB’>, ‘get_meta’: <function get_meta at 0x7f2cffd46700>, ‘new_doc’: <function new_doc at 0x7f2cffd45c60>, ‘get_doc’: <function get_doc at 0x7f2cffd46520>, ‘get_mapped_doc’: <function get_mapped_doc at 0x7f2cfc2…
filename = ‘: sync’
File “: sync”, line 1, in
json = {‘loads’: <function loads at 0x7f2d00be6520>, ‘dumps’: <function dumps at 0x7f2d00be5da0>}
as_json = <function as_json at 0x7f2cffc1cb80>
dict = <class ‘dict’>
log = <function log at 0x7f2cffd44b80>
_dict = <class ‘frappe._dict’>
args = {}
frappe = {‘call’: <function call_whitelisted_function at 0x7f2cfc2a2ac0>, ‘flags’: {}, ‘format’: <function format_value at 0x7f2cffc1cd60>, ‘format_value’: <function format_value at 0x7f2cffc1cd60>, ‘date_format’: ‘dd-mm-yyyy’, ‘time_format’: ‘HH:mm:ss’, ‘format_date’: <function global_date_format at 0x7f2cffcf5b20>, ‘form_dict’: {}, ‘bold’: <function bold at 0x7f2cffc1d580>, ‘copy_doc’: <function copy_doc at 0x7f2cffc1c680>, ‘errprint’: <function errprint at 0x7f2cffd44a40>, ‘qb’: <class ‘frappe.query_builder.builder.MariaDB’>, ‘get_meta’: <function get_meta at 0x7f2cffd46700>, ‘new_doc’: <function new_doc at 0x7f2cffd45c60>, ‘get_doc’: <function get_doc at 0x7f2cffd46520>, ‘get_mapped_doc’: <function get_mapped_doc at 0x7f2cfc28a160>, ‘get_last_doc’: <function get_last_doc at 0x7f2cffd465c0>, ‘get_cached_doc’: <function get_cached_doc at 0x7f2cffd45da0>, ‘get_list’: <function get_list at 0x7f2cffc1c9a0>, ‘get_all’: <function get_all at 0x7f2cffc1ca40>, ‘get_system_settings’: <function get_sys…
FrappeClient = <class ‘frappe.frappeclient.FrappeClient’>
style = {‘border_color’: ‘#d1d8dd’}
get_toc = <function get_toc at 0x7f2cfc61a020>
get_next_link = <function get_next_link at 0x7f2cfc61a0c0>
_ = <function _ at 0x7f2d00c956c0>
scrub = <function scrub at 0x7f2cffbc76a0>
guess_mimetype = <function guess_type at 0x7f2d0070c5e0>
html2text = <function html2text at 0x7f2cfc708900>
dev_server = 0
run_script = <function run_script at 0x7f2cfc2a2b60>
is_job_queued = <function is_job_queued at 0x7f2cfc2a2980>
get_visible_columns = <function get_visible_columns at 0x7f2cfc2a20c0>
builtins = {‘build_class’: , ‘None’: None, ‘False’: False, ‘True’: True, ‘abs’: , ‘bool’: <class ‘bool’>, ‘bytes’: <class ‘bytes’>, ‘callable’: , ‘chr’: , ‘complex’: <class ‘complex’>, ‘divmod’: , ‘float’: <class ‘float’>, ‘hash’: , ‘hex’: , ‘id’: , ‘int’: <class ‘int’>, ‘isinstance’: , ‘issubclass’: , ‘len’: , ‘oct’: , ‘ord’: , ‘pow’: , ‘range’: <class ‘range’>, ‘repr’: , ‘round’: , ‘slice’: <class ‘slice’>, ‘sorted’: , ‘str’: <class ‘str’>, ‘tuple’: <class ‘tuple’>, ‘zip’: <class ‘zip’>, ‘ArithmeticError’: <class ‘ArithmeticError’>, ‘AssertionError’: <class 'Assertion…
write = <function _write at 0x7f2cfc2a3420>
getitem = <function _getitem at 0x7f2cfc2a31a0>
getattr = <function _getattr_for_safe_exec at 0x7f2cfc2a3240>
print = <class ‘frappe.utils.safe_exec.FrappePrintCollector’>
getiter =
iter_unpack_sequence = <function guarded_iter_unpack_sequence at 0x7f2cfc3605e0>
abs =
all =
any =
bool = <class ‘bool’>
enumerate = <class ‘enumerate’>
isinstance =
issubclass =
list = <class ‘list’>
max =
min =
range = <class ‘range’>
set = <class ‘set’>
sorted =
sum =
tuple = <class ‘tuple’>
builtins.ImportError: import not found