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

Making JobOperation Private #313

Closed
b-butler opened this issue Jun 30, 2020 · 4 comments · Fixed by #325
Closed

Making JobOperation Private #313

b-butler opened this issue Jun 30, 2020 · 4 comments · Fixed by #325
Assignees

Comments

@b-butler
Copy link
Member

The JobOperation class is currently exposed to users for the primary purpose of using with submit_operations and run_operations #310. The only way to obtain JobOperation objects through the user interface is through the FlowProject.next_operations. The use case for this class is small, so I purpose making JobOperation a private class. The current public methods of JobOperation involve the id, command string, and querying the status. None of these, I believe, to be a compelling use case for keeping the class public.

Making JobOperation private would also more easily allow future refactoring.

@b-butler b-butler changed the title Refactoring JobOperation Making JobOperation Private Jun 30, 2020
@b-butler b-butler assigned kidrahahjo and unassigned kidrahahjo Jun 30, 2020
@kidrahahjo
Copy link
Collaborator

@b-butler should I work on making JobOperation, SubmissionJobOperation, and next_operations private?

@vyasr
Copy link
Contributor

vyasr commented Jun 30, 2020

@kidrahahjo I would hold off on this task for now. I'd like to hear feedback from some more of @glotzerlab/signac-committers before pushing forward too quickly.

@csadorf
Copy link
Contributor

csadorf commented Jul 1, 2020

The original intention to expose some of this to the public API was to enable users to more easily develop their own execution and submission workflows, completely independent of the flow supported by the command line interface. I have so far not seen any real-world use cases for this. So with the goal to simplify things, I think it is totally fine to make this class (and all functions that directly use it) private.

@kidrahahjo
Copy link
Collaborator

kidrahahjo commented Jul 18, 2020

@csadorf @vyasr @b-butler
Deprecation of these methods along with JobOperation and SubmissionJobOperation class is scheduled for this issue to get resolved.

  1. next_operations
  2. run_operations
  3. submit_operations
  4. script (This is because it takes in list of JobOperation instances and we are deprecating it now so this should also be deprecated)
  5. completed_operations (This is just lying in the API without any internal use, I'm not sure why is this so)

I also feel like there's a need for deprecation get_job_status because of change in the way we fetch status for aggregation. After that implementation, we won't be using it for status update.

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

Successfully merging a pull request may close this issue.

4 participants