-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
v2.0.0: Deprecate waffle namespace classes
We now expose the old namespace classes as LegacyWaffle*. This causes a breaking change of import path.
- Loading branch information
Showing
7 changed files
with
67 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,15 @@ | ||
""" | ||
Expose new-style waffle classes. In the future, these imports will be moved to edx_toggles.toggles. Applications that | ||
want to migrate to the new-style API can do so right now by importing from this module. | ||
This module had been created to expose new-style waffle classes. These are now available from edx_toggles.toggles. | ||
""" | ||
# pylint: disable=unused-import | ||
from .internal.setting_toggle import SettingDictToggle, SettingToggle | ||
from .internal.waffle.flag import NonNamespacedWaffleFlag, WaffleFlag | ||
from .internal.waffle.switch import NonNamespacedWaffleSwitch, WaffleSwitch | ||
import warnings | ||
|
||
from . import * # pylint: disable=unused-import,wildcard-import | ||
|
||
warnings.warn( | ||
( | ||
"Importing from edx_toggles.toggles.__future__ is now deprecated." | ||
" You should import from edx_toggles.toggles instead." | ||
), | ||
DeprecationWarning, | ||
stacklevel=2, | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters