-
Notifications
You must be signed in to change notification settings - Fork 406
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(parameters): deprecate the config parameter in favor of boto…
…_config (#4893) * Replacing config with boto_config * Replacing config with boto_config
- Loading branch information
1 parent
26cfe7f
commit 08f2b53
Showing
9 changed files
with
196 additions
and
71 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
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 |
---|---|---|
@@ -0,0 +1,45 @@ | ||
"""Shared warnings that don't belong to a single utility""" | ||
|
||
|
||
class PowertoolsUserWarning(UserWarning): | ||
""" | ||
This class provides a custom Warning tailored for better clarity when certain situations occur. | ||
Examples: | ||
- Using development-only features in production environment. | ||
- Potential performance or security issues due to misconfiguration. | ||
Parameters | ||
---------- | ||
message: str | ||
The warning message to be displayed. | ||
""" | ||
|
||
def __init__(self, message): | ||
self.message = message | ||
super().__init__(message) | ||
|
||
def __str__(self): | ||
return self.message | ||
|
||
|
||
class PowertoolsDeprecationWarning(DeprecationWarning): | ||
""" | ||
This class provides a DeprecationWarning custom Warning for utilities/parameters deprecated in v3. | ||
Examples: | ||
- Using development-only features in production environment. | ||
- Potential performance or security issues due to misconfiguration. | ||
Parameters | ||
---------- | ||
message: str | ||
The warning message to be displayed. | ||
""" | ||
|
||
def __init__(self, message): | ||
self.message = message | ||
super().__init__(message) | ||
|
||
def __str__(self): | ||
return self.message |
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
Oops, something went wrong.