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

Review for DM-3651, pipe_tasks - bookkeeping improvements to makeDiscreteSkyMap #17

Merged
merged 5 commits into from Sep 8, 2015

Conversation

TallJimbo
Copy link
Member

No description provided.

@param args Arguments for Task.run()

@return:
- None if doReturnResults false
Copy link
Member Author

Choose a reason for hiding this comment

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

Maybe say "self.doReturnResults"; took me a moment to remember where that setting comes from.

Copy link
Contributor

Choose a reason for hiding this comment

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

OK. I don't think "self" helps as much as talking about the constructor argument, but self is easy, short and precise (whereas one could override the constructor...)

MakeDiscreteSkyMapRunner.__call__ had a similar error
that TaskRunner had: it could crash if doReturnResults
was True and the task failed. I fixed that, improved
the documentation for __call__ and changed it to
return a Struct like TaskRunner.
The code that MakeDiscreteSkyMapTask used to save metadata
was incorrect. This was in MakeDiscreteSkyMapRunner.__call__.
Fixed by calling task.writeMetadata(dataRef) for each dataRef
instead of task.writeMetadata(butler).
The metadata is not interesting, so don't save it.
I disabled it using the standard technique of having
MakeDiscreteSkyMap._getMetadataName() return None.
I left the code in the task runner that saves it,
because that task runner is more generally useful
and might be wanted for tasks that do save metadata.
MakeDiscreteSkyMapTask was disabling saving of config by overriding
a method in its task runner, making the task runner less generally
useful and obscuring the fact that the task did not save its config.
I removed the override in the task runner and replaced it with
the standard means of disabling config saving: by having
the task's _getConfigName method return None.
@r-owen r-owen merged commit e1c0bf2 into master Sep 8, 2015
@ktlim ktlim deleted the tickets/DM-3651 branch August 25, 2018 06:45
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 this pull request may close these issues.

None yet

2 participants