Merged in feature/PYPE-439_project_task_timer_crashes (pull request #216)

Feature/PYPE-439 project task timer crashes

Approved-by: Milan Kolar <milan@orbi.tools>
This commit is contained in:
Jakub Trllo 2019-07-24 08:05:26 +00:00 committed by Milan Kolar
commit 34df8bae3f
2 changed files with 11 additions and 0 deletions

View file

@ -94,6 +94,9 @@ class AppAction(BaseHandler):
):
return False
if entities[0]['parent'].entity_type.lower() == 'project':
return False
ft_project = entities[0]['project']
database = pypelib.get_avalon_database()

View file

@ -78,7 +78,15 @@ class TimersManager(metaclass=Singleton):
'task_name': 'Lookdev BG'
}
'''
if len(data['hierarchy']) < 1:
self.log.error((
'Not allowed action in Pype!!'
' Timer has been launched on task which is child of Project.'
))
return
self.last_task = data
for module in self.modules:
module.start_timer_manager(data)
self.is_running = True