Skip to content

Make Config objects immutable#250

Open
nicoonoclaste wants to merge 3 commits into
mainfrom
config/immutable
Open

Make Config objects immutable#250
nicoonoclaste wants to merge 3 commits into
mainfrom
config/immutable

Conversation

@nicoonoclaste

@nicoonoclaste nicoonoclaste commented Apr 27, 2021

Copy link
Copy Markdown
Collaborator

This is a stepping stone towards making Config be a dataclass,
so the new dependency on frozendict might not stay long.

Piggy-backs on #249 (Config.resolved: Major bugfix(es)) so please merge that first

This cleans up a fair bit of the logic in here, and safeguards us against
potential bugs.  It is however a technically-breaking change.
@nicoonoclaste

Copy link
Copy Markdown
Collaborator Author

Why is frozendict not a thing in the standard library anyhow?

@duckinator

duckinator commented Apr 28, 2021

Copy link
Copy Markdown
Owner

@nbraud I merged #249 - not sure what to do with this one since there's so much overlap between the two.

@duckinator

Copy link
Copy Markdown
Owner

Updated this to be based on the current codebase and use latest frozendict. There's some problems with Config.copy() not having kwargs even though your code expects it to accept them.

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