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-39605: Use butler.dimensions rather than butler.registry.dimensions #850

Merged
merged 28 commits into from
Jun 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
daa5a6b
Use butler.dimensions rather than butler.registry.dimensions
timj Jun 8, 2023
3e892e6
Declare that the serialized type must be a pydantic model
timj Jun 12, 2023
eb921e0
Use modern type annotations
timj Jun 12, 2023
2867a08
Use modern set syntax
timj Jun 12, 2023
b115f04
Use f-strings rather than str.format
timj Jun 12, 2023
d3d69dd
Remove unnecessary parentheses
timj Jun 12, 2023
b3efd76
Drop explicit use of a value that matches default
timj Jun 12, 2023
8b0f35f
Use modern set syntax in tests
timj Jun 12, 2023
b5b4afa
Use modern type annotations in tests
timj Jun 12, 2023
0e126f0
Use f-string rather than format
timj Jun 12, 2023
787e61c
Remove unneeded parens
timj Jun 12, 2023
8038f3e
Remove explicit defaults from open calls
timj Jun 12, 2023
7bcfe68
Fix problems reported by pydocstyle
timj Jun 12, 2023
b8a30c7
Prefer collections.abc.Set over typing.AbstractSet
timj Jun 12, 2023
35eac70
Add docstring for ColumnCategorization
timj Jun 12, 2023
b3100f1
Fix docstring references to collections.abc classes
timj Jun 12, 2023
027117f
DatasetRef no longer raises for no ID and run is required
timj Jun 12, 2023
f75b6e7
Remove mention of incrementing integer in docs for dataset ID
timj Jun 12, 2023
6e9a2a2
Replace a Union for a compound type
timj Jun 13, 2023
2041e8e
Fix incorrect type in docstring
timj Jun 13, 2023
a2401aa
Some minor fixes to annotations
timj Jun 13, 2023
98a613c
Update doc string to match type annotation
timj Jun 13, 2023
25c1ecf
Fix some ResourcePathExpression problems from earlier commit
timj Jun 13, 2023
4353b59
Use Iterable rather than list for annotation
timj Jun 13, 2023
821034a
Add news fragment
timj Jun 13, 2023
af75926
Add RepoExportContext to public API
timj Jun 13, 2023
7a04c33
Replace IOError with OSError (they are aliases)
timj Jun 13, 2023
dc06cb3
.format to f-string
timj Jun 13, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 4 additions & 0 deletions doc/changes/DM-39605.misc.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
* Replace usage of ``Butler.registry.dimensions`` with ``Butler.dimensions``.
* Modernize type annotations.
* Fix some documentation problems.
* Minor modernizations to use set notation and f-strings.
1 change: 0 additions & 1 deletion doc/lsst.daf.butler/organizing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ We call a `DatasetRef` whose `~DatasetRef.id` attribute is not `None` a *resolve

In most data repositories, dataset IDs are 128-bit UUIDs that are guaranteed to be unique across all data repositories, not just within one; if two datasets share the same UUID in different data repositories, they must be identical (this is possible because of the extraordinarily low probability of a collision between two random 128-bit numbers, and our reservation of deterministic UUIDs for very special datasets).
As a result, we also frequently refer to the dataset ID as the UUID, especially in contexts where UUIDs are actually needed or can be safely assumed.
But 64-bit autoincrement integers are also supported (albeit mostly for legacy reasons), and we continue to use "dataset ID" in most code and documentation to refer to either form.

Most of the time, however, users identify a dataset using a combination of three other attributes:

Expand Down
2 changes: 1 addition & 1 deletion python/lsst/daf/butler/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,5 @@

# Import the registry subpackage directly for other symbols.
from .registry import CollectionSearch, CollectionType, Registry, RegistryConfig
from .transfers import YamlRepoExportBackend, YamlRepoImportBackend
from .transfers import RepoExportContext, YamlRepoExportBackend, YamlRepoImportBackend
from .version import *