Skip to content

refactor CommonKeys#1825

Merged
wyli merged 1 commit into
Project-MONAI:masterfrom
rijobro:CommonKeys_refactor
Mar 22, 2021
Merged

refactor CommonKeys#1825
wyli merged 1 commit into
Project-MONAI:masterfrom
rijobro:CommonKeys_refactor

Conversation

@rijobro

@rijobro rijobro commented Mar 22, 2021

Copy link
Copy Markdown
Contributor

Move CommonKeys to enums.py so that it can be used by the whole MONAI codebase. Addresses problem in this PR: #1794 (comment).

Signed-off-by: Richard Brown <33289025+rijobro@users.noreply.github.com>

@wyli wyli left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

thanks, this is a breaking change moves CommonKeys from monai.engines.utils to monai.utils.enums this is non-breaking

@wyli wyli merged commit a8f83e1 into Project-MONAI:master Mar 22, 2021
@rijobro rijobro deleted the CommonKeys_refactor branch March 22, 2021 20:14
@rijobro

rijobro commented Mar 22, 2021

Copy link
Copy Markdown
Contributor Author

How is this a breaking change? Do you think many people would be importing CommonKeys in their own code?

@wyli

wyli commented Mar 22, 2021

Copy link
Copy Markdown
Contributor

@rijobro

rijobro commented Mar 22, 2021

Copy link
Copy Markdown
Contributor Author

I see. Well at least the old import still works: from monai.engines.utils import CommonKeys (because it still gets imported into monai/engines/utils.py).

@wyli

wyli commented Mar 22, 2021

Copy link
Copy Markdown
Contributor

you're right, this is non-breaking, and we have access to CommonKeys even with the min. system setup (previously we can't have that)

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