Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PluginInstance start_date semantics #605

Open
jennydaman opened this issue Jan 22, 2025 · 0 comments
Open

PluginInstance start_date semantics #605

jennydaman opened this issue Jan 22, 2025 · 0 comments

Comments

@jennydaman
Copy link
Contributor

As a hotfix to #408, we now have the code:

# https://github.com/FNNDSC/ChRIS_ultron_backEnd/issues/408
now = timezone.now()
self.c_plugin_inst.start_date = now
self.c_plugin_inst.end_date = now

This solution isn't ideal, because it means start_date and end_date have bogus values up until the status finishedSuccessfully, finishedWithError, or cancelled is achieved.

STATUS_CHOICES = [("created", "Default initial"),
("waiting", "Waiting to be scheduled"),
("scheduled", "Scheduled on worker"),
("started", "Started on compute env"),
("registeringFiles", "Registering output files"),
("finishedSuccessfully", "Finished successfully"),
("finishedWithError", "Finished with error"),
("cancelled", "Cancelled")]

It would be ideal if there was a timestamp recording the time of each of these state changes: created, waiting, scheduled, started, registeringFiles, and "finished" (one of finishedSuccessfully, finishedWithError, or cancelled).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant