Skip to content
This repository has been archived by the owner on Sep 20, 2024. It is now read-only.

TimersManager: Start timer post launch hook #2418

Merged
merged 16 commits into from
Dec 20, 2021

Conversation

iLLiCiTiT
Copy link
Member

@iLLiCiTiT iLLiCiTiT commented Dec 16, 2021

Brief description

Currently only post launch hook starting timer is in Ftrack but it can be triggered using TimersManager.

Changes

  • added new post launch hook using webserver to start timer for passed context
  • ftrack post launch hook does not start timer
  • removed need of "hierarchy" in rest api call to start timer
  • replaced not used change_timer_from_host with static method start_timer_with_webserver

Resolves #1656

@mkolar
Copy link
Member

mkolar commented Dec 16, 2021

Task linked: OP-1172 Start timer post launch hook

@iLLiCiTiT iLLiCiTiT self-assigned this Dec 16, 2021
@iLLiCiTiT iLLiCiTiT added the type: enhancement Enhancements to existing functionality label Dec 16, 2021
Copy link
Member

@kalisp kalisp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Its working.

I am just wondering if check for context (project_name, asset_name, task_name) shouldn't be part of the calling function. Is there any use case where context could be empty or would I add validation for context whenever I would like to use the start_timer_with_webserver ?

@iLLiCiTiT
Copy link
Member Author

Is there any use case where context could be empty or would I add validation for context whenever I would like to use the start_timer_with_webserver ?

I don't think that there is a use case when client side could handle that in any way. I mean if you find out that context you want to use is invalid what will you do with that? But it does make sense to return "success" in response. And add validate context method but I would not call it automatically in start_timer_with_webserver.

@iLLiCiTiT iLLiCiTiT merged commit 9c39f8f into develop Dec 20, 2021
@iLLiCiTiT iLLiCiTiT deleted the feature/OP-1172_Start-timer-post-launch-hook branch January 5, 2022 15:07
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type: enhancement Enhancements to existing functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Start timer post launch hook
4 participants