Skip to content
This repository has been archived by the owner on Jan 2, 2025. It is now read-only.

♻️ Rename RecordMeta to Registry and refactor __repr__(cls) #414

Merged
merged 4 commits into from
Aug 3, 2024

Conversation

falexwolf
Copy link
Member

@falexwolf falexwolf commented Aug 3, 2024

Refactor __repr__(cls) to enable documenting registries consistently:

The class method was previously contributed by @Zethson:

@falexwolf falexwolf changed the title ♻️ Rename RecordMeta to Registry and refactor repr ♻️ Rename RecordMeta to Registry and refactor repr Aug 3, 2024
@@ -16,7 +16,7 @@ def test_registry__repr__param(setup_instance):
param = ln.Param
expected_repr = textwrap.dedent("""\
Param
Basic fields
Simple fields
Copy link
Member Author

Choose a reason for hiding this comment

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

@Zethson @fredericenard for consistency across out "django field modeling" codebase

I fear there might be lot's of duplication across what Lukas did here, and what Fred did before in the hub.

But given we somewhat have a tradition of writing these helper classes for SA & Django ORM already for years (back then also @sunnyosun wrote some of this code), we at least seem consistent in that. :D

@falexwolf falexwolf merged commit 6a4605e into main Aug 3, 2024
1 check passed
@falexwolf falexwolf deleted the refactorrepr branch August 3, 2024 17:31
@falexwolf falexwolf changed the title ♻️ Rename RecordMeta to Registry and refactor repr ♻️ Rename RecordMeta to Registry and refactor __repr__(cls) Aug 3, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant