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

DM-47189: Write default butler factory function for all instruments #125

Merged
merged 5 commits into from
Oct 29, 2024

Conversation

mfisherlevine
Copy link
Contributor

No description provided.

Copy link
Contributor

@isullivan isullivan left a comment

Choose a reason for hiding this comment

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

A couple minor suggestions.

# it is present and blank, or just not set, both these exception
# types can be raised, see tests/test_butlerUtils.py:ButlerInitTestCase
# for details and tests which confirm these have not changed
raise FileNotFoundError # unify exception type
Copy link
Contributor

Choose a reason for hiding this comment

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

Do you want to include the original error message?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This should be incredibly rare tbh. I almost removed this who try really - this was put in in the very very early days before we reliably had the $DAF_BUTLER_REPOSITORY_INDEX set at all our sites, and sometimes it was set but pointed to a file that was missing, etc etc. I suspect this will simply never happen now, so I think this is OK.

-------
butler : `lsst.daf.butler.Butler`
The butler.
"""
Copy link
Contributor

Choose a reason for hiding this comment

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

You could add a raises section for the FileNotFoundError handling.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I will add the raises section for good measure though.

@mfisherlevine mfisherlevine merged commit 9b2bdd9 into main Oct 29, 2024
5 checks passed
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.

2 participants